i2c-eg20t: Rework pch_i2c_wait_for_bus_idle to reduce wait time
authorAlexander Stein <alexander.stein@systec-electronic.com>
Mon, 20 Feb 2012 08:14:16 +0000 (09:14 +0100)
committerWolfram Sang <w.sang@pengutronix.de>
Wed, 7 Mar 2012 18:07:04 +0000 (19:07 +0100)
If you insert several i2c transfers, the driver might start the next one
while the STOP bit of the previous transfer is still on the bus, marking
the bus as busy.
pch_i2c_wait_for_bus_idle does an msleep(20) delaying the next transfer
by >=20ms. Reduce wait time by actively waiting 5 us once, then using
usleep_range.

Signed-off-by: Alexander Stein <alexander.stein@systec-electronic.com>
Acked-by: Tomoya MORINAGA <tomoya.rohm@gmail.com>
Signed-off-by: Wolfram Sang <w.sang@pengutronix.de>

No differences found