From 46694d8a46a8ecb109e9d10ad681615245041957 Mon Sep 17 00:00:00 2001 From: Reka Norman Date: Fri, 8 Apr 2022 15:14:35 +1000 Subject: mb/google/brya/baseboard/nissa: Configure I2C lcnt and hcnt Configure lcnt and hcnt directly to give the required frequency, tHIGH and tLOW, instead of using rise and fall times. Aim for a frequency of 390 kHz to make sure it doesn't exceed 400 kHz on different boards. BUG=b:227517802 TEST=Probe the clock line and check that it meets the requirements for frequency, tHIGH and tLOW. Change-Id: I4d4f877c1f0cd9aacd3fa152890b7ef82e059f78 Signed-off-by: Reka Norman Reviewed-on: https://review.coreboot.org/c/coreboot/+/63562 Tested-by: build bot (Jenkins) Reviewed-by: Kangheui Won Reviewed-by: Eric Lai --- .../brya/variants/baseboard/nissa/devicetree.cb | 30 ++++++++++++++-------- 1 file changed, 20 insertions(+), 10 deletions(-) (limited to 'src/mainboard/google/brya/variants/baseboard') diff --git a/src/mainboard/google/brya/variants/baseboard/nissa/devicetree.cb b/src/mainboard/google/brya/variants/baseboard/nissa/devicetree.cb index c4c4fb3c58..dfc0a85b41 100644 --- a/src/mainboard/google/brya/variants/baseboard/nissa/devicetree.cb +++ b/src/mainboard/google/brya/variants/baseboard/nissa/devicetree.cb @@ -74,33 +74,43 @@ chip soc/intel/alderlake .i2c[0] = { .early_init = 1, .speed = I2C_SPEED_FAST, - .rise_time_ns = 650, - .fall_time_ns = 400, .data_hold_time_ns = 50, + .speed_config[0] = { + .scl_lcnt = 157, + .scl_hcnt = 78, + } }, .i2c[1] = { .speed = I2C_SPEED_FAST, - .rise_time_ns = 650, - .fall_time_ns = 400, .data_hold_time_ns = 50, + .speed_config[0] = { + .scl_lcnt = 157, + .scl_hcnt = 78, + } }, .i2c[2] = { .speed = I2C_SPEED_FAST, - .rise_time_ns = 650, - .fall_time_ns = 400, .data_hold_time_ns = 50, + .speed_config[0] = { + .scl_lcnt = 157, + .scl_hcnt = 78, + } }, .i2c[3] = { .speed = I2C_SPEED_FAST, - .rise_time_ns = 650, - .fall_time_ns = 400, .data_hold_time_ns = 50, + .speed_config[0] = { + .scl_lcnt = 157, + .scl_hcnt = 78, + } }, .i2c[5] = { .speed = I2C_SPEED_FAST, - .rise_time_ns = 650, - .fall_time_ns = 400, .data_hold_time_ns = 50, + .speed_config[0] = { + .scl_lcnt = 157, + .scl_hcnt = 78, + } }, }" -- cgit v1.2.3