summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorYu-Ping Wu <yupingso@chromium.org>2019-10-01 14:16:51 +0800
committerPatrick Georgi <pgeorgi@google.com>2019-10-02 11:17:25 +0000
commitcf9588040d91148c2c83b5f6200687448f4f2193 (patch)
tree5106ec0cea46133030b5a4eb7016b0399be9f011 /src
parent4c80425f3037d43cc45d56801e0717471cea0489 (diff)
mediatek/mt8183: Rename fields of struct sdram_params
Two fields of struct sdram_params are renamed for future CL of DRAM full calibration. Field 'impedance' is also removed. BUG=none BRANCH=none TEST=emerge-kukui coreboot Change-Id: I2f9673fd5ea2e62ee971f0d81bdd12aaf565e31c Signed-off-by: Yu-Ping Wu <yupingso@chromium.org> Reviewed-on: https://review.coreboot.org/c/coreboot/+/35738 Reviewed-by: Hung-Te Lin <hungte@chromium.org> Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Diffstat (limited to 'src')
-rw-r--r--src/mainboard/google/kukui/sdram_params/sdram-lpddr4x-H9HCNNNCPMALHR-4GB.c8
-rw-r--r--src/mainboard/google/kukui/sdram_params/sdram-lpddr4x-K4UBE3D4AA-MGCL-4GB.c8
-rw-r--r--src/mainboard/google/kukui/sdram_params/sdram-lpddr4x-KMDH6001DA-B422-4GB.c8
-rw-r--r--src/mainboard/google/kukui/sdram_params/sdram-lpddr4x-KMDP6001DA-B425-4GB.c8
-rw-r--r--src/mainboard/google/kukui/sdram_params/sdram-lpddr4x-KMDV6001DA-B620-4GB.c8
-rw-r--r--src/mainboard/google/kukui/sdram_params/sdram-lpddr4x-MT29VZZZAD8DQKSL-4GB.c8
-rw-r--r--src/mainboard/google/kukui/sdram_params/sdram-lpddr4x-MT53E1G32D4NQ-4GB.c8
-rw-r--r--src/mainboard/google/kukui/sdram_params/sdram-lpddr4x-SDADA4CR-128G-4GB.c8
-rw-r--r--src/soc/mediatek/mt8183/dramc_pi_calibration_api.c4
-rw-r--r--src/soc/mediatek/mt8183/include/soc/emi.h5
10 files changed, 20 insertions, 53 deletions
diff --git a/src/mainboard/google/kukui/sdram_params/sdram-lpddr4x-H9HCNNNCPMALHR-4GB.c b/src/mainboard/google/kukui/sdram_params/sdram-lpddr4x-H9HCNNNCPMALHR-4GB.c
index da6c7d255e..fab124038f 100644
--- a/src/mainboard/google/kukui/sdram_params/sdram-lpddr4x-H9HCNNNCPMALHR-4GB.c
+++ b/src/mainboard/google/kukui/sdram_params/sdram-lpddr4x-H9HCNNNCPMALHR-4GB.c
@@ -16,19 +16,15 @@
#include <soc/emi.h>
struct sdram_params params = {
- .impedance = {
- [ODT_OFF] = {0x7, 0x6, 0x0, 0xF},
- [ODT_ON] = {0x9, 0x9, 0x0, 0xF}
- },
.wr_level = {
[CHANNEL_A] = { {0x22, 0x1b}, {0x22, 0x19} },
[CHANNEL_B] = { {0x24, 0x20}, {0x25, 0x20} }
},
- .cbt_cs = {
+ .cbt_cs_dly = {
[CHANNEL_A] = {0x0, 0x0},
[CHANNEL_B] = {0x0, 0x0}
},
- .cbt_mr12 = {
+ .cbt_final_vref = {
[CHANNEL_A] = {0x52, 0x52},
[CHANNEL_B] = {0x52, 0x52}
},
diff --git a/src/mainboard/google/kukui/sdram_params/sdram-lpddr4x-K4UBE3D4AA-MGCL-4GB.c b/src/mainboard/google/kukui/sdram_params/sdram-lpddr4x-K4UBE3D4AA-MGCL-4GB.c
index 8d855ff1ba..d3c1496a6c 100644
--- a/src/mainboard/google/kukui/sdram_params/sdram-lpddr4x-K4UBE3D4AA-MGCL-4GB.c
+++ b/src/mainboard/google/kukui/sdram_params/sdram-lpddr4x-K4UBE3D4AA-MGCL-4GB.c
@@ -16,19 +16,15 @@
#include <soc/emi.h>
struct sdram_params params = {
- .impedance = {
- [ODT_OFF] = {0x9, 0x7, 0x0, 0xF},
- [ODT_ON] = {0xB, 0x9, 0x0, 0xE}
- },
.wr_level = {
[CHANNEL_A] = { {0x22, 0x1C}, {0x23, 0x1D} },
[CHANNEL_B] = { {0x26, 0x23}, {0x26, 0x23} }
},
- .cbt_cs = {
+ .cbt_cs_dly = {
[CHANNEL_A] = {0x6, 0x5},
[CHANNEL_B] = {0x6, 0x6}
},
- .cbt_mr12 = {
+ .cbt_final_vref = {
[CHANNEL_A] = {0x56, 0x58},
[CHANNEL_B] = {0x58, 0x56}
},
diff --git a/src/mainboard/google/kukui/sdram_params/sdram-lpddr4x-KMDH6001DA-B422-4GB.c b/src/mainboard/google/kukui/sdram_params/sdram-lpddr4x-KMDH6001DA-B422-4GB.c
index 1e0c3628fd..c21cd12315 100644
--- a/src/mainboard/google/kukui/sdram_params/sdram-lpddr4x-KMDH6001DA-B422-4GB.c
+++ b/src/mainboard/google/kukui/sdram_params/sdram-lpddr4x-KMDH6001DA-B422-4GB.c
@@ -16,19 +16,15 @@
#include <soc/emi.h>
struct sdram_params params = {
- .impedance = {
- [ODT_OFF] = {0x9, 0x7, 0x0, 0xF},
- [ODT_ON] = {0xA, 0x9, 0x0, 0xE}
- },
.wr_level = {
[CHANNEL_A] = { {0x21, 0x21}, {0x20, 0x20} },
[CHANNEL_B] = { {0x1E, 0x1F}, {0x1D, 0x1E} }
},
- .cbt_cs = {
+ .cbt_cs_dly = {
[CHANNEL_A] = {0x1, 0x1},
[CHANNEL_B] = {0x2, 0x2}
},
- .cbt_mr12 = {
+ .cbt_final_vref = {
[CHANNEL_A] = {0x56, 0x56},
[CHANNEL_B] = {0x58, 0x5C}
},
diff --git a/src/mainboard/google/kukui/sdram_params/sdram-lpddr4x-KMDP6001DA-B425-4GB.c b/src/mainboard/google/kukui/sdram_params/sdram-lpddr4x-KMDP6001DA-B425-4GB.c
index 12acc61b3e..434984541c 100644
--- a/src/mainboard/google/kukui/sdram_params/sdram-lpddr4x-KMDP6001DA-B425-4GB.c
+++ b/src/mainboard/google/kukui/sdram_params/sdram-lpddr4x-KMDP6001DA-B425-4GB.c
@@ -16,19 +16,15 @@
#include <soc/emi.h>
struct sdram_params params = {
- .impedance = {
- [ODT_OFF] = {0x7, 0x6, 0x0, 0xF},
- [ODT_ON] = {0x8, 0x9, 0x0, 0xD}
- },
.wr_level = {
[CHANNEL_A] = { {0x22, 0x21}, {0x20, 0x21} },
[CHANNEL_B] = { {0x23, 0x27}, {0x23, 0x27} }
},
- .cbt_cs = {
+ .cbt_cs_dly = {
[CHANNEL_A] = {0x0, 0x0},
[CHANNEL_B] = {0x6, 0x6}
},
- .cbt_mr12 = {
+ .cbt_final_vref = {
[CHANNEL_A] = {0x56, 0x5A},
[CHANNEL_B] = {0x58, 0x58}
},
diff --git a/src/mainboard/google/kukui/sdram_params/sdram-lpddr4x-KMDV6001DA-B620-4GB.c b/src/mainboard/google/kukui/sdram_params/sdram-lpddr4x-KMDV6001DA-B620-4GB.c
index 8cc0d3d693..cab57ce853 100644
--- a/src/mainboard/google/kukui/sdram_params/sdram-lpddr4x-KMDV6001DA-B620-4GB.c
+++ b/src/mainboard/google/kukui/sdram_params/sdram-lpddr4x-KMDV6001DA-B620-4GB.c
@@ -16,19 +16,15 @@
#include <soc/emi.h>
struct sdram_params params = {
- .impedance = {
- [ODT_OFF] = {0x8, 0x7, 0x0, 0xF},
- [ODT_ON] = {0x9, 0x9, 0x0, 0xD}
- },
.wr_level = {
[CHANNEL_A] = { {0x21, 0x24}, {0x22, 0x24} },
[CHANNEL_B] = { {0x24, 0x28}, {0x22, 0x27} }
},
- .cbt_cs = {
+ .cbt_cs_dly = {
[CHANNEL_A] = {0xC, 0xC},
[CHANNEL_B] = {0xB, 0xB}
},
- .cbt_mr12 = {
+ .cbt_final_vref = {
[CHANNEL_A] = {0x58, 0x58},
[CHANNEL_B] = {0x56, 0x56}
},
diff --git a/src/mainboard/google/kukui/sdram_params/sdram-lpddr4x-MT29VZZZAD8DQKSL-4GB.c b/src/mainboard/google/kukui/sdram_params/sdram-lpddr4x-MT29VZZZAD8DQKSL-4GB.c
index 512023b35e..2810ef50f7 100644
--- a/src/mainboard/google/kukui/sdram_params/sdram-lpddr4x-MT29VZZZAD8DQKSL-4GB.c
+++ b/src/mainboard/google/kukui/sdram_params/sdram-lpddr4x-MT29VZZZAD8DQKSL-4GB.c
@@ -16,19 +16,15 @@
#include <soc/emi.h>
struct sdram_params params = {
- .impedance = {
- [ODT_OFF] = {0x9, 0x7, 0x0, 0xF},
- [ODT_ON] = {0xA, 0x9, 0x0, 0xE}
- },
.wr_level = {
[CHANNEL_A] = { {0x21, 0x21}, {0x20, 0x20} },
[CHANNEL_B] = { {0x21, 0x28}, {0x21, 0x29} }
},
- .cbt_cs = {
+ .cbt_cs_dly = {
[CHANNEL_A] = {0x2, 0x2},
[CHANNEL_B] = {0x2, 0x2}
},
- .cbt_mr12 = {
+ .cbt_final_vref = {
[CHANNEL_A] = {0x5E, 0x5E},
[CHANNEL_B] = {0x5E, 0x5C}
},
diff --git a/src/mainboard/google/kukui/sdram_params/sdram-lpddr4x-MT53E1G32D4NQ-4GB.c b/src/mainboard/google/kukui/sdram_params/sdram-lpddr4x-MT53E1G32D4NQ-4GB.c
index 0fb5abacba..329cc76afe 100644
--- a/src/mainboard/google/kukui/sdram_params/sdram-lpddr4x-MT53E1G32D4NQ-4GB.c
+++ b/src/mainboard/google/kukui/sdram_params/sdram-lpddr4x-MT53E1G32D4NQ-4GB.c
@@ -16,19 +16,15 @@
#include <soc/emi.h>
struct sdram_params params = {
- .impedance = {
- [ODT_OFF] = {0x5, 0x7, 0x0, 0xF},
- [ODT_ON] = {0x6, 0x9, 0x0, 0xF}
- },
.wr_level = {
[CHANNEL_A] = { {0x1F, 0x19}, {0x20, 0x1A} },
[CHANNEL_B] = { {0x22, 0x1E}, {0x22, 0x1E} }
},
- .cbt_cs = {
+ .cbt_cs_dly = {
[CHANNEL_A] = {0x5, 0x4},
[CHANNEL_B] = {0x8, 0x8}
},
- .cbt_mr12 = {
+ .cbt_final_vref = {
[CHANNEL_A] = {0x56, 0x56},
[CHANNEL_B] = {0x56, 0x56}
},
diff --git a/src/mainboard/google/kukui/sdram_params/sdram-lpddr4x-SDADA4CR-128G-4GB.c b/src/mainboard/google/kukui/sdram_params/sdram-lpddr4x-SDADA4CR-128G-4GB.c
index 61060d6fdc..ccb591e06a 100644
--- a/src/mainboard/google/kukui/sdram_params/sdram-lpddr4x-SDADA4CR-128G-4GB.c
+++ b/src/mainboard/google/kukui/sdram_params/sdram-lpddr4x-SDADA4CR-128G-4GB.c
@@ -16,19 +16,15 @@
#include <soc/emi.h>
struct sdram_params params = {
- .impedance = {
- [ODT_OFF] = {0x8, 0x7, 0x0, 0xF},
- [ODT_ON] = {0x9, 0x9, 0x0, 0xE}
- },
.wr_level = {
[CHANNEL_A] = { {0x1F, 0x1C}, {0x1C, 0x1B} },
[CHANNEL_B] = { {0x27, 0x28}, {0x23, 0x28} }
},
- .cbt_cs = {
+ .cbt_cs_dly = {
[CHANNEL_A] = {0x3, 0x3},
[CHANNEL_B] = {0x4, 0x6}
},
- .cbt_mr12 = {
+ .cbt_final_vref = {
[CHANNEL_A] = {0x5C, 0x5A},
[CHANNEL_B] = {0x5C, 0x5A}
},
diff --git a/src/soc/mediatek/mt8183/dramc_pi_calibration_api.c b/src/soc/mediatek/mt8183/dramc_pi_calibration_api.c
index fcc3b14a1e..f8b1f091ed 100644
--- a/src/soc/mediatek/mt8183/dramc_pi_calibration_api.c
+++ b/src/soc/mediatek/mt8183/dramc_pi_calibration_api.c
@@ -252,8 +252,8 @@ static void dramc_cmd_bus_training(u8 chn, u8 rank, u8 freq_group,
{
u32 cbt_cs, mr12_value;
- cbt_cs = params->cbt_cs[chn][rank];
- mr12_value = params->cbt_mr12[chn][rank];
+ cbt_cs = params->cbt_cs_dly[chn][rank];
+ mr12_value = params->cbt_final_vref[chn][rank];
/* CBT adjust cs */
clrsetbits_le32(&ch[chn].phy.shu[0].rk[rank].ca_cmd[9],
diff --git a/src/soc/mediatek/mt8183/include/soc/emi.h b/src/soc/mediatek/mt8183/include/soc/emi.h
index 264d91869a..15889eeca4 100644
--- a/src/soc/mediatek/mt8183/include/soc/emi.h
+++ b/src/soc/mediatek/mt8183/include/soc/emi.h
@@ -21,10 +21,9 @@
#include <soc/dramc_common_mt8183.h>
struct sdram_params {
- u32 impedance[2][4];
u8 wr_level[CHANNEL_MAX][RANK_MAX][DQS_NUMBER];
- u8 cbt_cs[CHANNEL_MAX][RANK_MAX];
- u8 cbt_mr12[CHANNEL_MAX][RANK_MAX];
+ u8 cbt_cs_dly[CHANNEL_MAX][RANK_MAX];
+ u8 cbt_final_vref[CHANNEL_MAX][RANK_MAX];
u32 emi_cona_val;
u32 emi_conh_val;
u32 emi_conf_val;