Commit 4f734a3a authored by Alexander Kochetkov's avatar Alexander Kochetkov Committed by Wolfram Sang

i2c: omap: add notes related to i2c multimaster mode

No functional changes.
Signed-off-by: default avatarAlexander Kochetkov <al.kochet@gmail.com>
Reviewed-by: default avatarFelipe Balbi <balbi@ti.com>
Signed-off-by: default avatarWolfram Sang <wsa@the-dreams.de>
parent b76911d2
...@@ -299,6 +299,12 @@ static void __omap_i2c_init(struct omap_i2c_dev *dev) ...@@ -299,6 +299,12 @@ static void __omap_i2c_init(struct omap_i2c_dev *dev)
/* Take the I2C module out of reset: */ /* Take the I2C module out of reset: */
omap_i2c_write_reg(dev, OMAP_I2C_CON_REG, OMAP_I2C_CON_EN); omap_i2c_write_reg(dev, OMAP_I2C_CON_REG, OMAP_I2C_CON_EN);
/*
* NOTE: right after setting CON_EN, STAT_BB could be 0 while the
* bus is busy. It will be changed to 1 on the next IP FCLK clock.
* udelay(1) will be enough to fix that.
*/
/* /*
* Don't write to this register if the IE state is 0 as it can * Don't write to this register if the IE state is 0 as it can
* cause deadlock. * cause deadlock.
...@@ -660,7 +666,11 @@ static int omap_i2c_xfer_msg(struct i2c_adapter *adap, ...@@ -660,7 +666,11 @@ static int omap_i2c_xfer_msg(struct i2c_adapter *adap,
if (!dev->b_hw && stop) if (!dev->b_hw && stop)
w |= OMAP_I2C_CON_STP; w |= OMAP_I2C_CON_STP;
/*
* NOTE: STAT_BB bit could became 1 here if another master occupy
* the bus. IP successfully complete transfer when the bus will be
* free again (BB reset to 0).
*/
omap_i2c_write_reg(dev, OMAP_I2C_CON_REG, w); omap_i2c_write_reg(dev, OMAP_I2C_CON_REG, w);
/* /*
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment