From: Jean Delvare Date: Sun, 18 Jul 2010 19:48:47 +0000 (-0300) Subject: V4L/DVB: cx23885: Return -ENXIO on slave nack X-Git-Tag: v2.6.36-rc1~39^2~85 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=f4acb3c4ccca74f5448354308f917e87ce83505a;p=profile%2Fivi%2Fkernel-x86-ivi.git 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 Signed-off-by: Andy Walls Signed-off-by: Mauro Carvalho Chehab --- diff --git a/drivers/media/video/cx23885/cx23885-i2c.c b/drivers/media/video/cx23885/cx23885-i2c.c index d4746e0..154c914 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, if (!i2c_wait_done(i2c_adap)) return -EIO; if (!i2c_slave_did_ack(i2c_adap)) - return -EIO; + return -ENXIO; dprintk(1, "%s() returns 0\n", __func__); return 0; @@ -185,7 +185,7 @@ static int i2c_readbytes(struct i2c_adapter *i2c_adap, if (!i2c_wait_done(i2c_adap)) return -EIO; if (!i2c_slave_did_ack(i2c_adap)) - return -EIO; + return -ENXIO; dprintk(1, "%s() returns 0\n", __func__);