i2c: nomadik: fetch i2c-transfer-timeout-us property from devicetree
authorThéo Lebrun <theo.lebrun@bootlin.com>
Wed, 6 Mar 2024 17:59:27 +0000 (18:59 +0100)
committerAndi Shyti <andi.shyti@kernel.org>
Tue, 12 Mar 2024 10:50:44 +0000 (11:50 +0100)
commitec189b9fb83cd1c869d45bfe3c9cb27b71093a16
tree117552002fc518b8386e08e6f4c5c0961eff4371
parentc763072ab4533f0669b19c60d8a18b31f2877164
i2c: nomadik: fetch i2c-transfer-timeout-us property from devicetree

Allow overriding the default timeout value (200ms) from devicetree,
using the generic i2c-transfer-timeout-us property.

The i2c_adapter->timeout field is an unaccurate jiffies amount;
i2c-nomadik uses hrtimers for timeouts below one jiffy.

Reviewed-by: Linus Walleij <linus.walleij@linaro.org>
Reviewed-by: Wolfram Sang <wsa+renesas@sang-engineering.com>
Reviewed-by: Andi Shyti <andi.shyti@kernel.org>
Signed-off-by: Théo Lebrun <theo.lebrun@bootlin.com>
Signed-off-by: Andi Shyti <andi.shyti@kernel.org>
drivers/i2c/busses/i2c-nomadik.c