diff options
author | Lukasz Czerwinski <l.czerwinski@samsung.com> | 2013-06-13 15:42:22 +0200 |
---|---|---|
committer | Chanho Park <chanho61.park@samsung.com> | 2014-11-18 11:43:12 +0900 |
commit | 7b2270ed28f21331084b4602d30a714c800bc5c3 (patch) | |
tree | e69636b3ab49f4ddd1b168ff756883ea288746e8 /drivers/nfc | |
parent | b591f828fbab7a7d55a2ef61d1627a6db8115dd0 (diff) | |
download | linux-3.10-7b2270ed28f21331084b4602d30a714c800bc5c3.tar.gz linux-3.10-7b2270ed28f21331084b4602d30a714c800bc5c3.tar.bz2 linux-3.10-7b2270ed28f21331084b4602d30a714c800bc5c3.zip |
nfc: pn544-i2c: Fix pn544_hci_i2c_write() resend cmd
Driver should always try resend cmd after failed i2c_master_send.
Signed-off-by: Lukasz Czerwinski <l.czerwinski@samsung.com>
Diffstat (limited to 'drivers/nfc')
-rw-r--r-- | drivers/nfc/pn544/i2c.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/nfc/pn544/i2c.c b/drivers/nfc/pn544/i2c.c index 8a848c2021e..854562344cb 100644 --- a/drivers/nfc/pn544/i2c.c +++ b/drivers/nfc/pn544/i2c.c @@ -206,7 +206,7 @@ static int pn544_hci_i2c_write(void *phy_id, struct sk_buff *skb) r = i2c_master_send(client, skb->data, skb->len); - if (r == -EREMOTEIO) { /* Retry, chip was in standby */ + if (r < 0) { /* Retry, chip was in standby */ usleep_range(6000, 10000); r = i2c_master_send(client, skb->data, skb->len); } |