Skip to content

Commit fe5ea84

Browse files
committed
i2c-bcm2708: fix stupid mistake
This makes it actually work. Signed-off-by: Chris Boot <bootc@bootc.net>
1 parent 8002705 commit fe5ea84

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

drivers/i2c/busses/i2c-bcm2708.c

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -166,6 +166,12 @@ static irqreturn_t bcm2708_i2c_interrupt(int irq, void *dev_id)
166166
} else if (s & BSC_S_DONE) {
167167
bi->nmsgs--;
168168

169+
/* drain the RX FIFO */
170+
while (s & BSC_S_RXD) {
171+
msg->buf[bi->pos++] = bcm2708_rd(bi, BSC_FIFO);
172+
s = bcm2708_rd(bi, BSC_S);
173+
};
174+
169175
bcm2708_bsc_reset(bi);
170176

171177
if (bi->nmsgs) {

0 commit comments

Comments
 (0)