ratp: implement i2c read/write support
Introduce two new RATP commands that allow running i2c read/write
operations, very similar in format to the already existing md/mw
RATP commands.

The messages are defined with a fixed 16-bit long register field, but
it will only be treated as a 16-bit address if I2C_FLAG_WIDE_ADDRESS
is set in the message flags field. If this flag is unset, the start
register address is assumed 8-bit long.

If the message includes the I2C_FLAG_MASTER_MODE flag, the start
register field is ignored and a i2c master send/receive operation is
performed.

Signed-off-by: Aleksander Morgado <aleksander@aleksander.es>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
1 parent 742ba2b commit 2d2daa3c65a08c201cbbbad772a93b1855709eb3
@Aleksander Morgado Aleksander Morgado authored on 12 Sep 2018
Sascha Hauer committed on 17 Sep 2018
Showing 4 changed files
View
common/ratp/Kconfig
View
common/ratp/Makefile
View
common/ratp/i2c.c 0 → 100644
View
include/ratp_bb.h