Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 138208
b: refs/heads/master
c: dc8685b
h: refs/heads/master
v: v3
  • Loading branch information
Devin Heitmueller authored and Mauro Carvalho Chehab committed Mar 30, 2009
1 parent b484c1c commit faa9b67
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 1 deletion.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 5a5a4e16fa19fa3789398e8c707168b7da718b64
refs/heads/master: dc8685b565d6526aca6aaefb80059d115c124821
18 changes: 18 additions & 0 deletions trunk/drivers/media/video/au0828/au0828-i2c.c
Original file line number Diff line number Diff line change
Expand Up @@ -156,6 +156,24 @@ static int i2c_sendbytes(struct i2c_adapter *i2c_adap,

dprintk(4, "SEND: %02x\n", msg->addr);

/* Deal with i2c_scan */
if (msg->len == 0) {
/* The analog tuner detection code makes use of the SMBUS_QUICK
message (which involves a zero length i2c write). To avoid
checking the status register when we didn't strobe out any
actual bytes to the bus, just do a read check. This is
consistent with how I saw i2c device checking done in the
USB trace of the Windows driver */
au0828_write(dev, REG_200, 0x20);
if (!i2c_wait_done(i2c_adap))
return -EIO;

if (i2c_wait_read_ack(i2c_adap))
return -EIO;

return 0;
}

for (i = 0; i < msg->len;) {

dprintk(4, " %02x\n", msg->buf[i]);
Expand Down

0 comments on commit faa9b67

Please sign in to comment.