]> git.kernelconcepts.de Git - karo-tx-linux.git/commitdiff
NFC: st21nfca: st21nfca_hci_i2c_probe returns st21nfca_hci_probe result.
authorChristophe Ricard <christophe.ricard@gmail.com>
Mon, 31 Mar 2014 22:34:05 +0000 (00:34 +0200)
committerSamuel Ortiz <sameo@linux.intel.com>
Mon, 21 Apr 2014 22:37:30 +0000 (00:37 +0200)
st21nfca_hci_probe return 0 in case of successful call and a different
value in any other cases.

There is no need to check for st21nfca_hci_probe return as this will be
checked after st21nfca_hci_i2c_probe is completed.

Signed-off-by: Christophe Ricard <christophe-h.ricard@st.com>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
drivers/nfc/st21nfca/i2c.c

index 71becd9cb99d57b4785bd8b171c68417e064addd..aafe70e9abeae1e66907350e64022462a6bca24e 100644 (file)
@@ -555,14 +555,9 @@ static int st21nfca_hci_i2c_probe(struct i2c_client *client,
                return r;
        }
 
-       r = st21nfca_hci_probe(phy, &i2c_phy_ops, LLC_SHDLC_NAME,
+       return st21nfca_hci_probe(phy, &i2c_phy_ops, LLC_SHDLC_NAME,
                               ST21NFCA_FRAME_HEADROOM, ST21NFCA_FRAME_TAILROOM,
                               ST21NFCA_HCI_LLC_MAX_PAYLOAD, &phy->hdev);
-
-       if (r < 0)
-               return r;
-
-       return 0;
 }
 
 static int st21nfca_hci_i2c_remove(struct i2c_client *client)