[1/3] i2c: exynos5: change internal transmission timeout to 100ms

Message ID 20171130143007.30258-2-a.hajda@samsung.com
State Accepted
Headers show
Series
  • i2c: exynos5: bus recovery implementation
Related show

Commit Message

Andrzej Hajda Nov. 30, 2017, 2:30 p.m.
Exynos-I2C uses default timeout of 1 second for the whole transaction,
including re-transmissions due to arbitration lost errors (-EAGAIN).
To allow re-transmissions driver's internal timeout should be significantly
lower, 100ms seems to be good candidate.

Signed-off-by: Andrzej Hajda <a.hajda@samsung.com>
---
 drivers/i2c/busses/i2c-exynos5.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Wolfram Sang Jan. 15, 2018, 8:54 p.m. | #1
On Thu, Nov 30, 2017 at 03:30:05PM +0100, Andrzej Hajda wrote:
> Exynos-I2C uses default timeout of 1 second for the whole transaction,
> including re-transmissions due to arbitration lost errors (-EAGAIN).
> To allow re-transmissions driver's internal timeout should be significantly
> lower, 100ms seems to be good candidate.
> 
> Signed-off-by: Andrzej Hajda <a.hajda@samsung.com>

Applied to for-next, thanks!

Patch

diff --git a/drivers/i2c/busses/i2c-exynos5.c b/drivers/i2c/busses/i2c-exynos5.c
index 3855e0b11877..b02428498f6d 100644
--- a/drivers/i2c/busses/i2c-exynos5.c
+++ b/drivers/i2c/busses/i2c-exynos5.c
@@ -170,7 +170,7 @@ 
 #define HSI2C_HS_TX_CLOCK	1000000
 #define HSI2C_FS_TX_CLOCK	100000
 
-#define EXYNOS5_I2C_TIMEOUT (msecs_to_jiffies(1000))
+#define EXYNOS5_I2C_TIMEOUT (msecs_to_jiffies(100))
 
 #define HSI2C_EXYNOS7	BIT(0)