imximage_hynix.cfg 6.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209
  1. #
  2. # (C) Copyright 2009
  3. # Stefano Babic DENX Software Engineering sbabic@denx.de.
  4. #
  5. # (C) Copyright 2010
  6. # Klaus Steinhammer TTECH Control Gmbh kst@tttech.com
  7. #
  8. # See file CREDITS for list of people who contributed to this
  9. # project.
  10. #
  11. # This program is free software; you can redistribute it and/or
  12. # modify it under the terms of the GNU General Public License as
  13. # published by the Free Software Foundation; either version 2 of
  14. # the License or (at your option) any later version.
  15. #
  16. # This program is distributed in the hope that it will be useful,
  17. # but WITHOUT ANY WARRANTY; without even the implied warranty of
  18. # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  19. # GNU General Public License for more details.
  20. #
  21. # You should have received a copy of the GNU General Public License
  22. # along with this program; if not write to the Free Software
  23. # Foundation Inc. 51 Franklin Street Fifth Floor Boston,
  24. # MA 02110-1301 USA
  25. #
  26. # Refer docs/README.imxmage for more details about how-to configure
  27. # and create imximage boot image
  28. #
  29. # The syntax is taken as close as possible with the kwbimage
  30. # Boot Device : one of
  31. # spi, nand, onenand, sd
  32. BOOT_FROM spi
  33. # Device Configuration Data (DCD)
  34. #
  35. # Each entry must have the format:
  36. # Addr-type Address Value
  37. #
  38. # where:
  39. # Addr-type register length (1,2 or 4 bytes)
  40. # Address absolute address of the register
  41. # value value to be stored in the register
  42. #######################
  43. ### Disable WDOG ###
  44. #######################
  45. DATA 2 0x73f98000 0x30
  46. #######################
  47. ### SET DDR Clk ###
  48. #######################
  49. # CCM: CBMCR - ddr_clk_sel: axi_b (133MHz)
  50. DATA 4 0x73FD4018 0x000024C0
  51. # DOUBLE SPI CLK (13MHz->26 MHz Clock)
  52. DATA 4 0x73FD4038 0x2010241
  53. #IOMUXC_SW_PAD_CTL_PAD_CSPI1_MOSI HYS_ENABLE | DRV_MAX | SRE_FAST
  54. DATA 4 0x73fa8600 0x00000107
  55. #IOMUXC_SW_PAD_CTL_PAD_CSPI1_MISO HYS_ENABLE | DRV_MAX | SRE_FAST
  56. DATA 4 0x73fa8604 0x00000107
  57. #IOMUXC_SW_PAD_CTL_PAD_CSPI1_SS0 HYS_ENABLE | PKE_ENABLE | DRV_MAX | SRE_FAST
  58. DATA 4 0x73fa8608 0x00000187
  59. #IOMUXC_SW_PAD_CTL_PAD_CSPI1_SS1 HYS_ENABLE | PKE_ENABLE | DRV_MAX | SRE_FAST
  60. DATA 4 0x73fa860c 0x00000187
  61. #IOMUXC_SW_PAD_CTL_PAD_CSPI1_SCLK HYS_ENABLE | DRV_MAX | SRE_FAST
  62. DATA 4 0x73fa8614 0x00000107
  63. #IOMUXC_SW_PAD_CTL_PAD_DI1_PIN11 HYS_ENABLE | DRV_MAX | SRE_FAST (CSPI1_SS2)
  64. DATA 4 0x73fa86a8 0x00000187
  65. #######################
  66. ### Settings IOMUXC ###
  67. #######################
  68. # DDR IOMUX configuration
  69. # Control, Data, Address pads are in their default state: HIGH DS, FAST SR.
  70. # IOMUXC_SW_PAD_CTL_PAD_DRAM_SDCLK MAX DS
  71. DATA 4 0x73fa84b8 0x000000e7
  72. # PVTC MAX (at GPC, PGR reg)
  73. #DATA 4 0x73FD8004 0x1fc00000
  74. #DQM0 DS high slew rate slow
  75. DATA 4 0x73fa84d4 0x000000e4
  76. #DQM1 DS high slew rate slow
  77. DATA 4 0x73fa84d8 0x000000e4
  78. #DQM2 DS high slew rate slow
  79. DATA 4 0x73fa84dc 0x000000e4
  80. #DQM3 DS high slew rate slow
  81. DATA 4 0x73fa84e0 0x000000e4
  82. #IOMUXC_SW_PAD_CTL_PAD_DRAM_SDQS0 DS high & SLEW slow
  83. DATA 4 0x73fa84bc 0x000000c4
  84. #IOMUXC_SW_PAD_CTL_PAD_DRAM_SDQS1 DS high & SLEW slow
  85. DATA 4 0x73fa84c0 0x000000c4
  86. #IOMUXC_SW_PAD_CTL_PAD_DRAM_SDQS2 DS high & SLEW slow
  87. DATA 4 0x73fa84c4 0x000000c4
  88. #IOMUXC_SW_PAD_CTL_PAD_DRAM_SDQS3 DS high & SLEW slow
  89. DATA 4 0x73fa84c8 0x000000c4
  90. #DRAM_DATA B0
  91. DATA 4 0x73fa88a4 0x00000004
  92. #DRAM_DATA B1
  93. DATA 4 0x73fa88ac 0x00000004
  94. #DRAM_DATA B2
  95. DATA 4 0x73fa88b8 0x00000004
  96. #DRAM_DATA B3
  97. DATA 4 0x73fa882c 0x00000004
  98. #DRAM_DATA B0 slew rate
  99. DATA 4 0x73fa8878 0x00000000
  100. #DRAM_DATA B1 slew rate
  101. DATA 4 0x73fa8880 0x00000000
  102. #DRAM_DATA B2 slew rate
  103. DATA 4 0x73fa888c 0x00000000
  104. #DRAM_DATA B3 slew rate
  105. DATA 4 0x73fa889c 0x00000000
  106. #######################
  107. ### Configure SDRAM ###
  108. #######################
  109. # Configure CS0
  110. #######################
  111. # ESDCTL0: Enable controller
  112. DATA 4 0x83fd9000 0x83220000
  113. # Init DRAM on CS0
  114. # ESDSCR: Precharge command
  115. DATA 4 0x83fd9014 0x04008008
  116. # ESDSCR: Refresh command
  117. DATA 4 0x83fd9014 0x00008010
  118. # ESDSCR: Refresh command
  119. DATA 4 0x83fd9014 0x00008010
  120. # ESDSCR: LMR with CAS=3 and BL=3 (Burst Length = 8)
  121. DATA 4 0x83fd9014 0x00338018
  122. # ESDSCR: EMR with half Drive strength (= medium strength @ i.MX51)
  123. DATA 4 0x83fd9014 0x0020801a
  124. # ESDSCR
  125. DATA 4 0x83fd9014 0x00008000
  126. # ESDSCR: EMR with full Drive strength
  127. #DATA 4 0x83fd9014 0x0000801a
  128. # ESDCTL0: 14 ROW, 10 COL, 32Bit, SREF=8
  129. DATA 4 0x83fd9000 0xC3220000
  130. # ESDCFG0: tRFC:22clks, tXSR:28clks, tXP:2clks, tWTR:2clk, tRP:3clks, tMRD:2clks
  131. # tRAS:8clks, tRRD:2clks, tWR:3clks, tRCD:3clks, tRC:11clks
  132. #DATA 4 0x83fd9004 0xC33574AA
  133. #micron mDDR
  134. # ESDCFG0: tRFC:11clks, tXSR:19clks, tXP:1clks, tWTR:2clk, tRP:3clks, tMRD:2clks
  135. # tRAS:7clks, tRRD:2clks, tWR:3clks, tRCD:3clks, tRC:9clks
  136. #DATA 4 0x83FD9004 0x101564a8
  137. #hynix mDDR
  138. # ESDCFG0: tRFC:17clks, tXSR:21clks, tXP:3clks, tWTR:1clk, tRP:3clks, tMRD:2clks
  139. # tRAS:7clks, tRRD:2clks, tWR:3clks, tRCD:3clks, tRC:9clks
  140. DATA 4 0x83FD9004 0x704564a8
  141. # ESDMISC: AP=10, Bank interleaving on, MIF3 en, RALAT=2
  142. DATA 4 0x83fd9010 0x000a1700
  143. # Configure CS1
  144. #######################
  145. # ESDCTL1: Enable controller
  146. DATA 4 0x83fd9008 0x83220000
  147. # Init DRAM on CS1
  148. # ESDSCR: Precharge command
  149. DATA 4 0x83fd9014 0x0400800c
  150. # ESDSCR: Refresh command
  151. DATA 4 0x83fd9014 0x00008014
  152. # ESDSCR: Refresh command
  153. DATA 4 0x83fd9014 0x00008014
  154. # ESDSCR: LMR with CAS=3 and BL=3 (Burst Length = 8)
  155. DATA 4 0x83fd9014 0x0033801c
  156. # ESDSCR: EMR with half Drive strength (= medium strength @ i.MX51)
  157. DATA 4 0x83fd9014 0x0020801e
  158. # ESDSCR
  159. DATA 4 0x83fd9014 0x00008004
  160. # ESDCTL1: 14 ROW, 10 COL, 32Bit, SREF=8
  161. DATA 4 0x83fd9008 0xC3220000
  162. # ESDCFG1: tRFC:22clks, tXSR:28clks, tXP:2clks, tWTR:2clk, tRP:3clks, tMRD:2clks
  163. # tRAS:8clks, tRRD:2clks, tWR:3clks, tRCD:3clks, tRC:11clks
  164. #DATA 4 0x83fd900c 0xC33574AA
  165. #micron mDDR
  166. # ESDCFG1: tRFC:11clks, tXSR:19clks, tXP:1clks, tWTR:2clk, tRP:3clks, tMRD:2clks
  167. # tRAS:7clks, tRRD:2clks, tWR:3clks, tRCD:3clks, tRC:9clks
  168. #DATA 4 0x83FD900C 0x101564a8
  169. #hynix mDDR
  170. # ESDCFG0: tRFC:17clks, tXSR:21clks, tXP:3clks, tWTR:1clk, tRP:3clks, tMRD:2clks
  171. # tRAS:7clks, tRRD:2clks, tWR:3clks, tRCD:3clks, tRC:9clks
  172. DATA 4 0x83FD900C 0x704564a8
  173. # ESDSCR (mDRAM configuration finished)
  174. DATA 4 0x83FD9014 0x00000004
  175. # ESDSCR - clear "configuration request" bit
  176. DATA 4 0x83fd9014 0x00000000