aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/media/video/em28xx/em28xx-i2c.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/media/video/em28xx/em28xx-i2c.c')
-rw-r--r--drivers/media/video/em28xx/em28xx-i2c.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/drivers/media/video/em28xx/em28xx-i2c.c b/drivers/media/video/em28xx/em28xx-i2c.c
index 97853384c943..2989a65f6917 100644
--- a/drivers/media/video/em28xx/em28xx-i2c.c
+++ b/drivers/media/video/em28xx/em28xx-i2c.c
@@ -143,10 +143,11 @@ static int em2800_i2c_check_for_device(struct em28xx *dev, unsigned char addr)
143 } 143 }
144 for (write_timeout = EM2800_I2C_WRITE_TIMEOUT; write_timeout > 0; 144 for (write_timeout = EM2800_I2C_WRITE_TIMEOUT; write_timeout > 0;
145 write_timeout -= 5) { 145 write_timeout -= 5) {
146 unsigned msg = dev->em28xx_read_reg(dev, 0x5); 146 unsigned reg = dev->em28xx_read_reg(dev, 0x5);
147 if (msg == 0x94) 147
148 if (reg == 0x94)
148 return -ENODEV; 149 return -ENODEV;
149 else if (msg == 0x84) 150 else if (reg == 0x84)
150 return 0; 151 return 0;
151 msleep(5); 152 msleep(5);
152 } 153 }