diff options
author | Jean Delvare <khali@linux-fr.org> | 2010-07-18 15:48:47 -0400 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@redhat.com> | 2010-08-08 22:42:53 -0400 |
commit | f4acb3c4ccca74f5448354308f917e87ce83505a (patch) | |
tree | f2eac5ff364f99d8eded4873ce3f1b2fb1232f48 /drivers/media/video | |
parent | 3d217c8656842c77d6f33329a034102157363c8d (diff) |
V4L/DVB: cx23885: Return -ENXIO on slave nack
Documentation/i2c/fault-codes says that i2c adapter drivers should
return -ENXIO when no slave acks an address byte.
Signed-off-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Andy Walls <awalls@md.metrocast.net>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media/video')
-rw-r--r-- | drivers/media/video/cx23885/cx23885-i2c.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/media/video/cx23885/cx23885-i2c.c b/drivers/media/video/cx23885/cx23885-i2c.c index d4746e064516..154c914ae16f 100644 --- a/drivers/media/video/cx23885/cx23885-i2c.c +++ b/drivers/media/video/cx23885/cx23885-i2c.c | |||
@@ -99,7 +99,7 @@ static int i2c_sendbytes(struct i2c_adapter *i2c_adap, | |||
99 | if (!i2c_wait_done(i2c_adap)) | 99 | if (!i2c_wait_done(i2c_adap)) |
100 | return -EIO; | 100 | return -EIO; |
101 | if (!i2c_slave_did_ack(i2c_adap)) | 101 | if (!i2c_slave_did_ack(i2c_adap)) |
102 | return -EIO; | 102 | return -ENXIO; |
103 | 103 | ||
104 | dprintk(1, "%s() returns 0\n", __func__); | 104 | dprintk(1, "%s() returns 0\n", __func__); |
105 | return 0; | 105 | return 0; |
@@ -185,7 +185,7 @@ static int i2c_readbytes(struct i2c_adapter *i2c_adap, | |||
185 | if (!i2c_wait_done(i2c_adap)) | 185 | if (!i2c_wait_done(i2c_adap)) |
186 | return -EIO; | 186 | return -EIO; |
187 | if (!i2c_slave_did_ack(i2c_adap)) | 187 | if (!i2c_slave_did_ack(i2c_adap)) |
188 | return -EIO; | 188 | return -ENXIO; |
189 | 189 | ||
190 | 190 | ||
191 | dprintk(1, "%s() returns 0\n", __func__); | 191 | dprintk(1, "%s() returns 0\n", __func__); |