Wolfram Sang w.s...@pengutronix.de wrote on 2012/09/14 16:02:34:
On Thu, Aug 30, 2012 at 12:40:04PM +0200, Joakim Tjernlund wrote:
mpc_i2c_stop() only initiates STOP but does not wait for it to
hit the I2C bus. This is a problem when using I2C devices which
uses fairly long clock
On Thu, Aug 30, 2012 at 12:40:04PM +0200, Joakim Tjernlund wrote:
mpc_i2c_stop() only initiates STOP but does not wait for it to
hit the I2C bus. This is a problem when using I2C devices which
uses fairly long clock stretching just before STOP if you also
have an i2c-mux which may switch to
Joakim Tjernlund/Transmode wrote on 2012/09/02 16:22:00:
Tabi Timur-B04825 b04...@freescale.com wrote on 2012/09/02 04:48:01:
On Thu, Aug 30, 2012 at 5:40 AM, Joakim Tjernlund
joakim.tjernl...@transmode.se wrote:
- mpc_i2c_stop(i2c);
+ mpc_i2c_stop(i2c); /* Initiate STOP
Tabi Timur-B04825 b04...@freescale.com wrote on 2012/09/02 04:48:01:
On Thu, Aug 30, 2012 at 5:40 AM, Joakim Tjernlund
joakim.tjernl...@transmode.se wrote:
- mpc_i2c_stop(i2c);
+ mpc_i2c_stop(i2c); /* Initiate STOP */
+ orig_jiffies = jiffies;
+ /* Wait until
On Thu, Aug 30, 2012 at 5:40 AM, Joakim Tjernlund
joakim.tjernl...@transmode.se wrote:
- mpc_i2c_stop(i2c);
+ mpc_i2c_stop(i2c); /* Initiate STOP */
+ orig_jiffies = jiffies;
+ /* Wait until STOP is seen, allow up to 1 s */
+ while (readb(i2c-base + MPC_I2C_SR)
mpc_i2c_stop() only initiates STOP but does not wait for it to
hit the I2C bus. This is a problem when using I2C devices which
uses fairly long clock stretching just before STOP if you also
have an i2c-mux which may switch to another bus before STOP has
been processed.
Signed-off-by: Joakim