From e18e1f9af536ce6b4d0ad06dd69a9b196afba74c Mon Sep 17 00:00:00 2001 From: Dtrain Hsu Date: Tue, 31 May 2022 11:51:46 +0800 Subject: mb/google/brya/var/kinox: Set memory SMBus addresses based on board rev Starting with id 2, boards switched the memory SMBus slave address, and use 0x50, 0x52. BUG=b:233975373 TEST=Build and boot to Chrome OS Signed-off-by: Dtrain Hsu Change-Id: I5e683ffdbc0727259ee796610cd97a6e378bf335 Reviewed-on: https://review.coreboot.org/c/coreboot/+/64810 Tested-by: build bot (Jenkins) Reviewed-by: Ricky Chang Reviewed-by: Tim Wawrzynczak --- src/mainboard/google/brya/variants/kinox/memory.c | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) (limited to 'src') diff --git a/src/mainboard/google/brya/variants/kinox/memory.c b/src/mainboard/google/brya/variants/kinox/memory.c index f979035833..01a997e78f 100644 --- a/src/mainboard/google/brya/variants/kinox/memory.c +++ b/src/mainboard/google/brya/variants/kinox/memory.c @@ -2,6 +2,7 @@ #include #include +#include #include #include @@ -32,7 +33,14 @@ const struct mb_cfg *variant_memory_params(void) void variant_get_spd_info(struct mem_spd *spd_info) { + const uint32_t id = board_id(); spd_info->topo = MEM_TOPO_DIMM_MODULE; - spd_info->smbus[0].addr_dimm[0] = 0x52; - spd_info->smbus[1].addr_dimm[0] = 0x50; + + if (id >= 2) { + spd_info->smbus[0].addr_dimm[0] = 0x50; + spd_info->smbus[1].addr_dimm[0] = 0x52; + } else { + spd_info->smbus[0].addr_dimm[0] = 0x52; + spd_info->smbus[1].addr_dimm[0] = 0x50; + } } -- cgit v1.2.3