freebsd-dev/sys/dev/iicbus/twsi
Emmanuel Vadot b74b94d2a1 twsi: Rework how we handle the i2c messages
We use to handle each message separately in i2c_transfer but that cannot
work with message with NOSTOP as it confuses the controller that we disable
the interrupts and start a new message.
Handle every message in the interrupt handler and fire a new start condition
if the previous message have NOSTOP, the controller understand this as a
repeated start.
This fixes booting on Allwinner A10/A20 platform where before the i2c controller
used to write 0 to the PMIC register that control the regulators as it though that
this was the continuation of the write message.

Tested on:   A20 BananaPi, Cubieboard 1 (kevans)
Reported by:	kevans
MFC after:	1 month
2020-01-10 18:52:14 +00:00
..
a10_twsi.c Add pnpinfo. 2019-05-23 18:19:56 +00:00
mv_twsi.c Add pnpinfo. 2019-05-23 18:19:56 +00:00
twsi.c twsi: Rework how we handle the i2c messages 2020-01-10 18:52:14 +00:00
twsi.h twsi: Rework how we handle the i2c messages 2020-01-10 18:52:14 +00:00