1 # SPDX-License-Identifier: GPL-2.0-or-later
3 # The IMX31PDK eval board has a single IMX31 chip
4 source [find target/imx31.cfg]
5 source [find target/imx.cfg]
6 $_TARGETNAME configure -event reset-init { imx31pdk_init }
9 echo "Running 100 iterations of test."
10 dump_image /ram/test 0x80000000 0x40000
11 for {set i 0} {$i < 100} {set i [expr {$i+1}]} {
14 mww 0x80000000 0x12345678 0x10000
15 load_image /ram/test 0x80000000 bin
16 verify_image /ram/test 0x80000000 bin
21 # Slow fallback frequency
22 # measure_clk indicates ca. 3-4MHz.
25 proc imx31pdk_init { } {
29 # This setup puts RAM at 0x80000000
32 mww 0x53F80000 0x074B0B7D
34 # 399MHz - 26MHz input, PD=1,MFI=7, MFN=27, MFD=40
35 #mww 0x53F80004 0xFF871D50
36 #mww 0x53F80010 0x00271C1B
38 # Start 16 bit NorFlash Initialization on CS0
39 mww 0xb8002000 0x0000CC03
40 mww 0xb8002004 0xa0330D01
41 mww 0xb8002008 0x00220800
43 # Configure CPLD on CS4
44 mww 0xb8002040 0x0000DCF6
45 mww 0xb8002044 0x444A4541
46 mww 0xb8002048 0x44443302
63 # DQM2, DQM1, DQM0, SD31-SD0, A25-A0, MA10 (0x288..0x2DC)
87 # Initialization script for 32 bit DDR on MX31 ADS
88 mww 0xB8001010 0x00000004
89 mww 0xB8001004 0x006ac73a
90 mww 0xB8001000 0x92100000
91 mww 0x80000f00 0x12344321
92 mww 0xB8001000 0xa2100000
93 mww 0x80000000 0x12344321
94 mww 0x80000000 0x12344321
95 mww 0xB8001000 0xb2100000
98 mww 0xB8001000 0x82226080
99 mww 0x80000000 0xDEADBEEF
100 mww 0xB8001010 0x0000000c