From e1aceef9550fa2b857c7f1a38f0c9f81975d42ea Mon Sep 17 00:00:00 2001 From: Brandon Breitenstein Date: Mon, 2 Nov 2015 16:58:22 -0800 Subject: [PATCH] intel/kunimitsu: FAB 4 update for Rcomp Target table Changed index 3 to be an exception of the default Rcomp Value BUG=None BRANCH=None TEST=Tested on FAB 4 SKU 1 Change-Id: I154c254835c4f6995183840cc241feeb9a448cdb Signed-off-by: Patrick Georgi Original-Commit-Id: f08eba3cf623b5869a7bb03fb3b6ba084cdd1622 Original-Change-Id: I0fbcff2c3526c4ed7cf90088ca23b43774cb9f8f Original-Signed-off-by: Brandon Breitenstein Original-Reviewed-on: https://chromium-review.googlesource.com/312715 Original-Reviewed-by: Aaron Durbin Original-Reviewed-by: Freddy Paul Reviewed-on: https://review.coreboot.org/12591 Tested-by: build bot (Jenkins) Reviewed-by: Stefan Reinauer --- src/mainboard/intel/kunimitsu/pei_data.c | 22 ++++++++++++++-------- 1 file changed, 14 insertions(+), 8 deletions(-) diff --git a/src/mainboard/intel/kunimitsu/pei_data.c b/src/mainboard/intel/kunimitsu/pei_data.c index deb488ef4c..3b0237e373 100644 --- a/src/mainboard/intel/kunimitsu/pei_data.c +++ b/src/mainboard/intel/kunimitsu/pei_data.c @@ -23,6 +23,7 @@ /* PCH_MEM_CFG[3:0] */ #define MAX_MEMORY_CONFIG 0x10 #define RCOMP_TARGET_PARAMS 0x5 +#define K4E6E304EE_MEM_ID 0x3 void mainboard_fill_pei_data(struct pei_data *pei_data) { @@ -41,19 +42,24 @@ void mainboard_fill_pei_data(struct pei_data *pei_data) const u16 RcompResistor[3] = { 200, 81, 162 }; /* Rcomp target */ - static const u16 RcompTarget[MAX_MEMORY_CONFIG][RCOMP_TARGET_PARAMS] = { - { 100, 40, 40, 23, 40 }, - { 100, 40, 40, 23, 40 }, - { 100, 40, 40, 23, 40 }, - /*Strengthen the Rcomp Target Ctrl for 8GB K4E6E304EE -EGCF*/ - { 100, 40, 40, 21, 40 }, }; + static const u16 RcompTarget[RCOMP_TARGET_PARAMS] = { + 100, 40, 40, 23, 40 }; + + /*Strengthen the Rcomp Target Ctrl for 8GB K4E6E304EE -EGCF*/ + static const u16 StrengthendRcompTarget[RCOMP_TARGET_PARAMS] = { + 100, 40, 40, 21, 40 }; memcpy(pei_data->dq_map, dq_map, sizeof(dq_map)); memcpy(pei_data->dqs_map, dqs_map, sizeof(dqs_map)); memcpy(pei_data->RcompResistor, RcompResistor, sizeof(RcompResistor)); - memcpy(pei_data->RcompTarget, &RcompTarget[pei_data->mem_cfg_id][0], - sizeof(RcompTarget[pei_data->mem_cfg_id])); + if (pei_data->mem_cfg_id == K4E6E304EE_MEM_ID) { + memcpy(pei_data->RcompTarget, StrengthendRcompTarget, + sizeof(StrengthendRcompTarget)); + } else { + memcpy(pei_data->RcompTarget, RcompTarget, + sizeof(RcompTarget)); + } }