aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/i2c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/i2c')
-rw-r--r--drivers/i2c/busses/i2c-designware.c11
1 files changed, 8 insertions, 3 deletions
diff --git a/drivers/i2c/busses/i2c-designware.c b/drivers/i2c/busses/i2c-designware.c
index f184d822d3d4..6acbe846e9c6 100644
--- a/drivers/i2c/busses/i2c-designware.c
+++ b/drivers/i2c/busses/i2c-designware.c
@@ -415,12 +415,17 @@ i2c_dw_xfer_msg(struct dw_i2c_dev *dev)
415 /* more bytes to be written */ 415 /* more bytes to be written */
416 dev->status |= STATUS_WRITE_IN_PROGRESS; 416 dev->status |= STATUS_WRITE_IN_PROGRESS;
417 break; 417 break;
418 } else { 418 } else
419 dev->status &= ~STATUS_WRITE_IN_PROGRESS; 419 dev->status &= ~STATUS_WRITE_IN_PROGRESS;
420 intr_mask &= ~DW_IC_INTR_TX_EMPTY;
421 }
422 } 420 }
423 421
422 /*
423 * If i2c_msg index search is completed, we don't need TX_EMPTY
424 * interrupt any more.
425 */
426 if (dev->msg_write_idx == dev->msgs_num)
427 intr_mask &= ~DW_IC_INTR_TX_EMPTY;
428
424 writel(intr_mask, dev->base + DW_IC_INTR_MASK); 429 writel(intr_mask, dev->base + DW_IC_INTR_MASK);
425} 430}
426 431