summaryrefslogtreecommitdiff
path: root/board/freescale
diff options
context:
space:
mode:
authorTom Rini <trini@konsulko.com>2018-01-31 18:44:31 -0500
committerTom Rini <trini@konsulko.com>2018-01-31 18:44:31 -0500
commit48f58a59737739b0f96ceba9f7873178c6d917bf (patch)
treeedbd91290eefd0cd53a1b6af65cd255e57ff5c2e /board/freescale
parent2e87980580d0bf4781ad0d63efd456aa1a73d03f (diff)
parent58932ec68cdcd574c85620e285a7b95a49551603 (diff)
Merge git://git.denx.de/u-boot-fsl-qoriq
Diffstat (limited to 'board/freescale')
-rw-r--r--board/freescale/ls1046ardb/ddr.c9
-rw-r--r--board/freescale/ls1046ardb/ddr.h19
-rw-r--r--board/freescale/ls2080ardb/ddr.c2
-rw-r--r--board/freescale/ls2080ardb/ddr.h23
4 files changed, 30 insertions, 23 deletions
diff --git a/board/freescale/ls1046ardb/ddr.c b/board/freescale/ls1046ardb/ddr.c
index fb4f6abe0b..46ed7bd0cf 100644
--- a/board/freescale/ls1046ardb/ddr.c
+++ b/board/freescale/ls1046ardb/ddr.c
@@ -29,7 +29,10 @@ void fsl_ddr_board_options(memctl_options_t *popts,
if (!pdimm->n_ranks)
return;
- pbsp = udimms[0];
+ if (popts->registered_dimm_en)
+ pbsp = rdimms[0];
+ else
+ pbsp = udimms[0];
/* Get clk_adjust, wrlvl_start, wrlvl_ctl, according to the board ddr
* freqency and n_banks specified in board_specific_parameters table.
@@ -66,8 +69,6 @@ found:
pbsp->n_ranks, pbsp->datarate_mhz_high, pbsp->rank_gb);
popts->data_bus_width = 0; /* 64-bit data bus */
- popts->otf_burst_chop_en = 0;
- popts->burst_length = DDR_BL8;
popts->bstopre = 0; /* enable auto precharge */
/*
@@ -94,7 +95,7 @@ found:
DDR_CDR2_VREF_TRAIN_EN | DDR_CDR2_VREF_RANGE_2;
/* optimize cpo for erratum A-009942 */
- popts->cpo_sample = 0x70;
+ popts->cpo_sample = 0x61;
}
int fsl_initdram(void)
diff --git a/board/freescale/ls1046ardb/ddr.h b/board/freescale/ls1046ardb/ddr.h
index 9e440f67b4..04328f2555 100644
--- a/board/freescale/ls1046ardb/ddr.h
+++ b/board/freescale/ls1046ardb/ddr.h
@@ -41,4 +41,23 @@ static const struct board_specific_parameters *udimms[] = {
udimm0,
};
+static const struct board_specific_parameters rdimm0[] = {
+ /*
+ * memory controller 0
+ * num| hi| rank| clk| wrlvl | wrlvl | wrlvl
+ * ranks| mhz| GB |adjst| start | ctl2 | ctl3
+ */
+ {2, 1666, 0, 0x8, 0x0D, 0x0C0B0A08, 0x0A0B0C08,},
+ {2, 1900, 0, 0x8, 0x0E, 0x0D0C0B09, 0x0B0C0D09,},
+ {2, 2300, 0, 0xa, 0x12, 0x100F0D0C, 0x0E0F100C,},
+ {1, 1666, 0, 0x8, 0x0D, 0x0C0B0A08, 0x0A0B0C08,},
+ {1, 1900, 0, 0x8, 0x0E, 0x0D0C0B09, 0x0B0C0D09,},
+ {1, 2300, 0, 0xa, 0x12, 0x100F0D0C, 0x0E0F100C,},
+ {}
+};
+
+static const struct board_specific_parameters *rdimms[] = {
+ rdimm0,
+};
+
#endif
diff --git a/board/freescale/ls2080ardb/ddr.c b/board/freescale/ls2080ardb/ddr.c
index 01f7d82fb6..b13a974b6e 100644
--- a/board/freescale/ls2080ardb/ddr.c
+++ b/board/freescale/ls2080ardb/ddr.c
@@ -85,6 +85,8 @@ found:
pbsp->wrlvl_ctl_3);
#ifdef CONFIG_SYS_FSL_HAS_DP_DDR
if (ctrl_num == CONFIG_DP_DDR_CTRL) {
+ if (popts->registered_dimm_en)
+ printf("WARN: RDIMM not supported.\n");
/* force DDR bus width to 32 bits */
popts->data_bus_width = 1;
popts->otf_burst_chop_en = 0;
diff --git a/board/freescale/ls2080ardb/ddr.h b/board/freescale/ls2080ardb/ddr.h
index 8d5a49061c..53c16f54f7 100644
--- a/board/freescale/ls2080ardb/ddr.h
+++ b/board/freescale/ls2080ardb/ddr.h
@@ -55,24 +55,9 @@ static const struct board_specific_parameters rdimm0[] = {
* num| hi| rank| clk| wrlvl | wrlvl | wrlvl
* ranks| mhz| GB |adjst| start | ctl2 | ctl3
*/
- {2, 1350, 0, 8, 6, 0x0708090B, 0x0C0D0E09,},
- {2, 1666, 0, 8, 7, 0x08090A0C, 0x0D0F100B,},
- {2, 1900, 0, 8, 7, 0x09090B0D, 0x0E10120B,},
- {2, 2200, 0, 8, 8, 0x090A0C0F, 0x1012130C,},
- {}
-};
-
-/* DP-DDR DIMM */
-static const struct board_specific_parameters rdimm2[] = {
- /*
- * memory controller 2
- * num| hi| rank| clk| wrlvl | wrlvl | wrlvl
- * ranks| mhz| GB |adjst| start | ctl2 | ctl3
- */
- {2, 1350, 0, 8, 6, 0x0708090B, 0x0C0D0E09,},
- {2, 1666, 0, 8, 7, 0x0B0A090C, 0x0D0F100B,},
- {2, 1900, 0, 8, 7, 0x09090B0D, 0x0E10120B,},
- {2, 2200, 0, 8, 8, 0x090A0C0F, 0x1012130C,},
+ {2, 1666, 0, 8, 0x0F, 0x0D0C0A09, 0x0B0C0E08,},
+ {2, 1900, 0, 8, 0x10, 0x0F0D0B0A, 0x0B0E0F09,},
+ {2, 2200, 0, 8, 0x13, 0x120F0E0B, 0x0D10110B,},
{}
};
@@ -85,7 +70,7 @@ static const struct board_specific_parameters *udimms[] = {
static const struct board_specific_parameters *rdimms[] = {
rdimm0,
rdimm0,
- rdimm2,
+ udimm2, /* DP-DDR doesn't support RDIMM */
};