soc/mediatek/mt8192: add i2c driver support
commitcd83bf8874b13639bbd0b9e3b1270a5771d5e5bc
authorQii Wang <qii.wang@mediatek.com>
Fri, 20 Nov 2020 09:36:07 +0000 (20 17:36 +0800)
committerHung-Te Lin <hungte@chromium.org>
Mon, 14 Dec 2020 03:55:13 +0000 (14 03:55 +0000)
tree6a620a74dd402e61530de3aeb2876e656af9bb50
parent9ef72ca7db807a7ae2e7d78144773940dd688a78
soc/mediatek/mt8192: add i2c driver support

Add I2C controller for MT8192, and revise the common I2C driver
to support I2C controller running in APDMA async mode. In that
case we have to initiate a different handshake protocol and reset
I2C differently.

BUG=b:155715435
TEST=Asurada boots up to shell

Signed-off-by: Qii Wang <qii.wang@mediatek.com>
Change-Id: I13835e00eb674a93aa5496a9870d1e601e263368
Reviewed-on: https://review.coreboot.org/c/coreboot/+/47800
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Hung-Te Lin <hungte@chromium.org>
src/soc/mediatek/common/i2c.c
src/soc/mediatek/common/include/soc/i2c_common.h
src/soc/mediatek/mt8192/Makefile.inc
src/soc/mediatek/mt8192/i2c.c [new file with mode: 0644]
src/soc/mediatek/mt8192/include/soc/addressmap.h
src/soc/mediatek/mt8192/include/soc/i2c.h [new file with mode: 0644]