regulator/rpi-panel-attiny: Use two transactions for I2C read
authorDave Stevenson <dave.stevenson@raspberrypi.com>
Mon, 24 Jan 2022 22:01:29 +0000 (17:01 -0500)
committerMark Brown <broonie@kernel.org>
Fri, 28 Jan 2022 20:55:53 +0000 (20:55 +0000)
commite4a7e3f741f797d93d97a153b0f6a862d19a1304
treecf8037a32f1684d24e8d18625f74223f6c565bd4
parent5fa4e8ea649009566a1b080f836ce23d4ce0c416
regulator/rpi-panel-attiny: Use two transactions for I2C read

The I2C to the Atmel is very fussy, and locks up easily on
Pi0-3 particularly on reads.
If running at 100kHz on Pi3, reading the ID register generally
locks up the Atmel, but splitting the register select write and
read into two transactions is reliable.

Signed-off-by: Dave Stevenson <dave.stevenson@raspberrypi.com>
Signed-off-by: Detlev Casanova <detlev.casanova@collabora.com>
Link: https://lore.kernel.org/r/20220124220129.158891-10-detlev.casanova@collabora.com
Signed-off-by: Mark Brown <broonie@kernel.org>
drivers/regulator/rpi-panel-attiny-regulator.c