From: Dmitry Belimov Date: Wed, 23 Apr 2008 17:07:09 +0000 (-0300) Subject: V4L/DVB (7676): saa7134: fix: Properly handle busy states on i2c bus X-Git-Tag: v2.6.26-rc1~1084^2~53 X-Git-Url: http://pilppa.com/gitweb/?a=commitdiff_plain;h=8fb737b7dc94e495be02c775afe1e7de0e06f3f5;p=linux-2.6-omap-h63xx.git V4L/DVB (7676): saa7134: fix: Properly handle busy states on i2c bus There are two conditions, reported by saa7134 that indicates that the I2C bus is busy: TO_SCL and TO_ARB. On both states, it needs to wait for I2C release, before using the bus. Signed-off-by: Beholder Intl. Ltd. Dmitry Belimov Signed-off-by: Mauro Carvalho Chehab --- diff --git a/drivers/media/video/saa7134/saa7134-i2c.c b/drivers/media/video/saa7134/saa7134-i2c.c index ba71dd0040b..2ccfaba0c49 100644 --- a/drivers/media/video/saa7134/saa7134-i2c.c +++ b/drivers/media/video/saa7134/saa7134-i2c.c @@ -140,6 +140,8 @@ static inline int i2c_is_busy(enum i2c_status status) { switch (status) { case BUSY: + case TO_SCL: + case TO_ARB: return true; default: return false;