servod: Serialize all I2C bus object wr_rd() method calls.
This is done by introducing a common base class which provides a wr_rd()
method that simply wraps a _raw_wr_rd() method while holding a mutex.
Subclasses implement _raw_wr_rd().
The common base class also provides a multi_wr_rd() method for performing
multiple I2C write/read/write+read transactions while holding the mutex.
It does NOT combine the transactions into one transaction on the bus
TEST=dut-control dut_i2c_mux uses I2C and continues to work. Tested with a
servo_micro connected to an octopus_ite.
Signed-off-by: Matthew Blecker <email@example.com>
Commit-Ready: ChromeOS CL Exonerator Bot <firstname.lastname@example.org>
5 files changed