]> git.ipfire.org Git - thirdparty/linux.git/commit
iio: adc: ltc2309: add read delay for ltc2305
authorCarlos Jones Jr <carlosjr.jones@analog.com>
Tue, 31 Mar 2026 01:24:56 +0000 (09:24 +0800)
committerJonathan Cameron <jic23@kernel.org>
Mon, 27 Apr 2026 08:58:17 +0000 (09:58 +0100)
commit671b8541c7d62818e0fb8ac7fe8a4086fc7c842e
tree0e0aa1279c995ddcb25f10adf6a48d3d0c693815
parentcd4e1141bff8b86c75c425acb84eca453e936a9d
iio: adc: ltc2309: add read delay for ltc2305

The LTC2305 requires a minimum 1.6μs delay between the I2C write
operation (channel selection) and the subsequent read operation to
allow the chip to process the command and prepare the result. While
not explicitly documented in the datasheet, this timing requirement
was identified by the hardware designer as necessary for reliable
operation.

Add a read_delay_us field to both the ltc2309_chip_info and ltc2309
device structures to support chip-specific timing requirements. Use
fsleep() to implement the delay when non-zero, with LTC2305 set to
2μs (1.6μs requirement rounded up). LTC2309 does not require
additional delay beyond inherent I2C bus timing.

This extends the existing LTC2305 support added in
(commit 8625d418d24b ("iio: adc: ltc2309: add support for ltc2305"))
with the missing inter-transaction delay.

Signed-off-by: Carlos Jones Jr <carlosjr.jones@analog.com>
Reviewed-by: Nuno Sá <nuno.sa@analog.com>
Reviewed-by: Andy Shevchenko <andy@kernel.org>
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
drivers/iio/adc/ltc2309.c