]> Git Repo - J-u-boot.git/blame - doc/README.fsl-ddr
powerpc/mpc8xxx: Fix picos_to_mclk() and get_memory_clk_period_ps()
[J-u-boot.git] / doc / README.fsl-ddr
CommitLineData
c9ffd839
HW
1
2Table of interleaving modes supported in cpu/8xxx/ddr/
3======================================================
4 +-------------+---------------------------------------------------------+
d1a24f06
WD
5 | | Rank Interleaving |
6 | +--------+-----------+-----------+------------+-----------+
7 |Memory | | | | 2x2 | 4x1 |
8 |Controller | None | 2x1 lower | 2x1 upper | {CS0+CS1}, | {CS0+CS1+ |
9 |Interleaving | | {CS0+CS1} | {CS2+CS3} | {CS2+CS3} | CS2+CS3} |
c9ffd839 10 +-------------+--------+-----------+-----------+------------+-----------+
d1a24f06 11 |None | Yes | Yes | Yes | Yes | Yes |
c9ffd839 12 +-------------+--------+-----------+-----------+------------+-----------+
d1a24f06
WD
13 |Cacheline | Yes | Yes | No | No, Only(*)| Yes |
14 | |CS0 Only| | | {CS0+CS1} | |
c9ffd839 15 +-------------+--------+-----------+-----------+------------+-----------+
d1a24f06
WD
16 |Page | Yes | Yes | No | No, Only(*)| Yes |
17 | |CS0 Only| | | {CS0+CS1} | |
c9ffd839 18 +-------------+--------+-----------+-----------+------------+-----------+
d1a24f06
WD
19 |Bank | Yes | Yes | No | No, Only(*)| Yes |
20 | |CS0 Only| | | {CS0+CS1} | |
c9ffd839 21 +-------------+--------+-----------+-----------+------------+-----------+
d1a24f06
WD
22 |Superbank | No | Yes | No | No, Only(*)| Yes |
23 | | | | | {CS0+CS1} | |
c9ffd839
HW
24 +-------------+--------+-----------+-----------+------------+-----------+
25 (*) Although the hardware can be configured with memory controller
26 interleaving using "2x2" rank interleaving, it only interleaves {CS0+CS1}
27 from each controller. {CS2+CS3} on each controller are only rank
28 interleaved on that controller.
29
076bff8f
YS
30 For memory controller interleaving, identical DIMMs are suggested. Software
31 doesn't check the size or organization of interleaved DIMMs.
32
c9ffd839
HW
33The ways to configure the ddr interleaving mode
34==============================================
351. In board header file(e.g.MPC8572DS.h), add default interleaving setting
36 under "CONFIG_EXTRA_ENV_SETTINGS", like:
37 #define CONFIG_EXTRA_ENV_SETTINGS \
79e4e648 38 "hwconfig=fsl_ddr:ctlr_intlv=bank" \
c9ffd839
HW
39 ......
40
412. Run u-boot "setenv" command to configure the memory interleaving mode.
42 Either numerical or string value is accepted.
43
44 # disable memory controller interleaving
79e4e648 45 setenv hwconfig "fsl_ddr:ctlr_intlv=null"
c9ffd839
HW
46
47 # cacheline interleaving
79e4e648 48 setenv hwconfig "fsl_ddr:ctlr_intlv=cacheline"
c9ffd839
HW
49
50 # page interleaving
79e4e648 51 setenv hwconfig "fsl_ddr:ctlr_intlv=page"
c9ffd839
HW
52
53 # bank interleaving
79e4e648 54 setenv hwconfig "fsl_ddr:ctlr_intlv=bank"
c9ffd839
HW
55
56 # superbank
79e4e648 57 setenv hwconfig "fsl_ddr:ctlr_intlv=superbank"
c9ffd839
HW
58
59 # disable bank (chip-select) interleaving
79e4e648 60 setenv hwconfig "fsl_ddr:bank_intlv=null"
c9ffd839
HW
61
62 # bank(chip-select) interleaving cs0+cs1
79e4e648 63 setenv hwconfig "fsl_ddr:bank_intlv=cs0_cs1"
c9ffd839
HW
64
65 # bank(chip-select) interleaving cs2+cs3
79e4e648 66 setenv hwconfig "fsl_ddr:bank_intlv=cs2_cs3"
c9ffd839
HW
67
68 # bank(chip-select) interleaving (cs0+cs1) and (cs2+cs3) (2x2)
79e4e648 69 setenv hwconfig "fsl_ddr:bank_intlv=cs0_cs1_and_cs2_cs3"
c9ffd839
HW
70
71 # bank(chip-select) interleaving (cs0+cs1+cs2+cs3) (4x1)
79e4e648
KG
72 setenv hwconfig "fsl_ddr:bank_intlv=cs0_cs1_cs2_cs3"
73
7fd101c9
YS
74Memory controller address hashing
75==================================
76If the DDR controller supports address hashing, it can be enabled by hwconfig.
77
78Syntax is:
79hwconfig=fsl_ddr:addr_hash=true
80
47df8f03
YS
81Memory controller ECC on/off
82============================
83If ECC is enabled in board configuratoin file, i.e. #define CONFIG_DDR_ECC,
84ECC can be turned on/off by hwconfig.
85
86Syntax is
87hwconfig=fsl_ddr:ecc=off
ebbe11dd
YS
88
89Memory testing options for mpc85xx
90==================================
911. Memory test can be done once U-boot prompt comes up using mtest, or
922. Memory test can be done with Power-On-Self-Test function, activated at
93 compile time.
94
95 In order to enable the POST memory test, CONFIG_POST needs to be
96 defined in board configuraiton header file. By default, POST memory test
97 performs a fast test. A slow test can be enabled by changing the flag at
98 compiling time. To test memory bigger than 2GB, 36BIT support is needed.
99 Memory is tested within a 2GB window. TLBs are used to map the virtual 2GB
100 window to physical address so that all physical memory can be tested.
101
7fd101c9
YS
102Combination of hwconfig
103=======================
104Hwconfig can be combined with multiple parameters, for example, on a supported
105platform
106
e1fd16b6
YS
107hwconfig=fsl_ddr:addr_hash=true,ctlr_intlv=cacheline,bank_intlv=cs0_cs1_cs2_cs3,ecc=on
108
109Table for dynamic ODT for DDR3
110==============================
111For single-slot system with quad-rank DIMM and dual-slot system, dynamic ODT may
112be needed, depending on the configuration. The numbers in the following tables are
113in Ohms.
114
115* denotes dynamic ODT
116
117Two slots system
118+-----------------------+----------+---------------+-----------------------------+-----------------------------+
d1a24f06 119| Configuration | |DRAM controller| Slot 1 | Slot 2 |
e1fd16b6 120+-----------+-----------+----------+-------+-------+--------------+--------------+--------------+--------------+
d1a24f06
WD
121| | | | | | Rank 1 | Rank 2 | Rank 1 | Rank 2 |
122+ Slot 1 | Slot 2 |Write/Read| Write | Read |-------+------+-------+------+-------+------+-------+------+
123| | | | | | Write | Read | Write | Read | Write | Read | Write | Read |
e1fd16b6 124+-----------+-----------+----------+-------+-------+-------+------+-------+------+-------+------+-------+------+
d1a24f06 125| | | Slot 1 | off | 75 | 120 | off | off | off | off | off | 30 | 30 |
e1fd16b6 126| Dual Rank | Dual Rank |----------+-------+-------+-------+------+-------+------+-------+------+-------+------+
d1a24f06 127| | | Slot 2 | off | 75 | off | off | 30 | 30 | 120 | off | off | off |
e1fd16b6 128+-----------+-----------+----------+-------+-------+-------+------+-------+------+-------+------+-------+------+
d1a24f06 129| | | Slot 1 | off | 75 | 120 | off | off | off | 20 | 20 | | |
e1fd16b6 130| Dual Rank |Single Rank|----------+-------+-------+-------+------+-------+------+-------+------+-------+------+
d1a24f06 131| | | Slot 2 | off | 75 | off | off | 20 | 20 | 120 *| off | | |
e1fd16b6 132+-----------+-----------+----------+-------+-------+-------+------+-------+------+-------+------+-------+------+
d1a24f06 133| | | Slot 1 | off | 75 | 120 *| off | | | off | off | 20 | 20 |
e1fd16b6 134|Single Rank| Dual Rank |----------+-------+-------+-------+------+-------+------+-------+------+-------+------+
d1a24f06 135| | | Slot 2 | off | 75 | 20 | 20 | | | 120 | off | off | off |
e1fd16b6 136+-----------+-----------+----------+-------+-------+-------+------+-------+------+-------+------+-------+------+
d1a24f06 137| | | Slot 1 | off | 75 | 120 *| off | | | 30 | 30 | | |
e1fd16b6 138|Single Rank|Single Rank|----------+-------+-------+-------+------+-------+------+-------+------+-------+------+
d1a24f06 139| | | Slot 2 | off | 75 | 30 | 30 | | | 120 *| off | | |
e1fd16b6 140+-----------+-----------+----------+-------+-------+-------+------+-------+------+-------+------+-------+------+
d1a24f06 141| Dual Rank | Empty | Slot 1 | off | 75 | 40 | off | off | off | | | | |
e1fd16b6 142+-----------+-----------+----------+-------+-------+-------+------+-------+------+-------+------+-------+------+
d1a24f06 143| Empty | Dual Rank | Slot 2 | off | 75 | | | | | 40 | off | off | off |
e1fd16b6 144+-----------+-----------+----------+-------+-------+-------+------+-------+------+-------+------+-------+------+
d1a24f06 145|Single Rank| Empty | Slot 1 | off | 75 | 40 | off | | | | | | |
e1fd16b6 146+-----------+-----------+----------+-------+-------+-------+------+-------+------+-------+------+-------+------+
d1a24f06 147| Empty |Single Rank| Slot 2 | off | 75 | | | | | 40 | off | | |
e1fd16b6
YS
148+-----------+-----------+----------+-------+-------+-------+------+-------+------+-------+------+-------+------+
149
150Single slot system
151+-------------+------------+---------------+-----------------------------+-----------------------------+
d1a24f06 152| | |DRAM controller| Rank 1 | Rank 2 | Rank 3 | Rank 4 |
e1fd16b6 153|Configuration| Write/Read |-------+-------+-------+------+-------+------+-------+------+-------+------+
d1a24f06 154| | | Write | Read | Write | Read | Write | Read | Write | Read | Write | Read |
e1fd16b6 155+-------------+------------+-------+-------+-------+------+-------+------+-------+------+-------+------+
d1a24f06
WD
156| | R1 | off | 75 | 120 *| off | off | off | 20 | 20 | off | off |
157| |------------+-------+-------+-------+------+-------+------+-------+------+-------+------+
158| | R2 | off | 75 | off | 20 | 120 | off | 20 | 20 | off | off |
e1fd16b6 159| Quad Rank |------------+-------+-------+-------+------+-------+------+-------+------+-------+------+
d1a24f06
WD
160| | R3 | off | 75 | 20 | 20 | off | off | 120 *| off | off | off |
161| |------------+-------+-------+-------+------+-------+------+-------+------+-------+------+
162| | R4 | off | 75 | 20 | 20 | off | off | off | 20 | 120 | off |
e1fd16b6 163+-------------+------------+-------+-------+-------+------+-------+------+-------+------+-------+------+
d1a24f06 164| | R1 | off | 75 | 40 | off | off | off |
e1fd16b6 165| Dual Rank |------------+-------+-------+-------+------+-------+------+
d1a24f06 166| | R2 | off | 75 | 40 | off | off | off |
e1fd16b6 167+-------------+------------+-------+-------+-------+------+-------+------+
d1a24f06 168| Single Rank | R1 | off | 75 | 40 | off |
e1fd16b6
YS
169+-------------+------------+-------+-------+-------+------+
170
171Reference http://www.xrosstalkmag.com/mag_issues/xrosstalk_oct08_final.pdf
d1a24f06 172 http://download.micron.com/pdf/technotes/ddr3/tn4108_ddr3_design_guide.pdf
This page took 0.147198 seconds and 4 git commands to generate.