Attention is currently required from: Hung-Te Lin, Xi Chen. Rex-BC Chen has uploaded this change for review. ( https://review.coreboot.org/c/coreboot/+/58074 )
Change subject: soc/mediatek: add debug dump for ltiming and clock_div ......................................................................
soc/mediatek: add debug dump for ltiming and clock_div
ltiming and clock_div are not support for MT8173, so we separate them to weak function: mtk_i2c_dump_more_info()
Signed-off-by: Rex-BC Chen rex-bc.chen@mediatek.com Change-Id: I3228c6953be5fac18a76029702b878a34c7563f7 --- M src/soc/mediatek/mt8183/i2c.c M src/soc/mediatek/mt8192/i2c.c M src/soc/mediatek/mt8195/i2c.c 3 files changed, 18 insertions(+), 0 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/74/58074/1
diff --git a/src/soc/mediatek/mt8183/i2c.c b/src/soc/mediatek/mt8183/i2c.c index ec9b797..94e5fcd 100644 --- a/src/soc/mediatek/mt8183/i2c.c +++ b/src/soc/mediatek/mt8183/i2c.c @@ -135,3 +135,9 @@ mtk_i2c_speed_init(bus); mtk_i2c_set_gpio_pinmux(bus); } + +void mtk_i2c_dump_more_info(struct mt_i2c_regs *regs) { + printk(BIOS_ERR, "LTIMING %x\nCLK_DIV %x\n", + read32(®s->ltiming), + read32(®s->clock_div)); +} diff --git a/src/soc/mediatek/mt8192/i2c.c b/src/soc/mediatek/mt8192/i2c.c index 572c280..bd629ce 100644 --- a/src/soc/mediatek/mt8192/i2c.c +++ b/src/soc/mediatek/mt8192/i2c.c @@ -181,3 +181,9 @@ mtk_i2c_speed_init(bus); mtk_i2c_set_gpio_pinmux(bus); } + +void mtk_i2c_dump_more_info(struct mt_i2c_regs *regs) { + printk(BIOS_ERR, "LTIMING %x\nCLK_DIV %x\n", + read32(®s->ltiming), + read32(®s->clock_div)); +} diff --git a/src/soc/mediatek/mt8195/i2c.c b/src/soc/mediatek/mt8195/i2c.c index a0d36b3..2de3c4d 100644 --- a/src/soc/mediatek/mt8195/i2c.c +++ b/src/soc/mediatek/mt8195/i2c.c @@ -356,3 +356,9 @@ mtk_i2c_speed_init(bus, speed); mtk_i2c_set_gpio_pinmux(bus); } + +void mtk_i2c_dump_more_info(struct mt_i2c_regs *regs) { + printk(BIOS_ERR, "LTIMING %x\nCLK_DIV %x\n", + read32(®s->ltiming), + read32(®s->clock_div)); +}