1 /* SPDX-License-Identifier: GPL-2.0+ */
3 * Copyright (C) 2017 Logic PD, Inc.
4 * Adam Ford <aford173@gmail.com>
6 * Refer doc/README.imximage for more details about how-to configure
7 * and create imximage boot image
9 * The syntax is taken as close as possible with the kwbimage
12 #include <asm/mach-imx/imximage.cfg>
17 BOOT_OFFSET FLASH_OFFSET_STANDARD
20 * Device Configuration Data (DCD)
22 * Each entry must have the format:
23 * Addr-type Address Value
26 * Addr-type register length (1,2 or 4 bytes)
27 * Address absolute address of the register
28 * value value to be stored in the register
33 #include "asm/arch-mx6/mx6-ddr.h"
34 #include "asm/arch-mx6/iomux.h"
35 #include "asm/arch-mx6/crm_regs.h"
37 DATA 4, MX6_IOM_GRP_DDR_TYPE, 0x000C0000
38 DATA 4, MX6_IOM_GRP_DDRPKE, 0x00000000
39 DATA 4, MX6_IOM_DRAM_SDCLK_0, 0x00000030
40 DATA 4, MX6_IOM_DRAM_SDCLK_1, 0x00000030
41 DATA 4, MX6_IOM_DRAM_CAS, 0x00000030
42 DATA 4, MX6_IOM_DRAM_RAS, 0x00000030
43 DATA 4, MX6_IOM_GRP_ADDDS, 0x00000030
44 DATA 4, MX6_IOM_DRAM_RESET, 0x00000030
45 DATA 4, MX6_IOM_DRAM_SDBA2, 0x00000000
46 DATA 4, MX6_IOM_DRAM_SDODT0, 0x00000030
47 DATA 4, MX6_IOM_DRAM_SDODT1, 0x00000030
48 DATA 4, MX6_IOM_GRP_CTLDS, 0x00000030
49 DATA 4, MX6_IOM_DDRMODE_CTL, 0x00020000
50 DATA 4, MX6_IOM_DRAM_SDQS0, 0x00000030
51 DATA 4, MX6_IOM_DRAM_SDQS1, 0x00000030
52 DATA 4, MX6_IOM_DRAM_SDQS2, 0x00000030
53 DATA 4, MX6_IOM_DRAM_SDQS3, 0x00000030
54 DATA 4, MX6_IOM_GRP_DDRMODE, 0x00020000
55 DATA 4, MX6_IOM_GRP_B0DS, 0x00000030
56 DATA 4, MX6_IOM_GRP_B1DS, 0x00000030
57 DATA 4, MX6_IOM_GRP_B2DS, 0x00000030
58 DATA 4, MX6_IOM_GRP_B3DS, 0x00000030
59 DATA 4, MX6_IOM_DRAM_DQM0, 0x00000030
60 DATA 4, MX6_IOM_DRAM_DQM1, 0x00000030
61 DATA 4, MX6_IOM_DRAM_DQM2, 0x00000030
62 DATA 4, MX6_IOM_DRAM_DQM3, 0x00000030
63 DATA 4, MX6_MMDC_P0_MDSCR, 0x00008000
64 DATA 4, MX6_MMDC_P0_MPZQHWCTRL, 0xA1390003
65 DATA 4, MX6_MMDC_P0_MPWLDECTRL0, 0x002D003A
66 DATA 4, MX6_MMDC_P0_MPWLDECTRL1, 0x0038002B
67 DATA 4, MX6_MMDC_P0_MPDGCTRL0, 0x03340338
68 DATA 4, MX6_MMDC_P0_MPDGCTRL1, 0x0334032C
69 DATA 4, MX6_MMDC_P0_MPRDDLCTL, 0x4036383C
70 DATA 4, MX6_MMDC_P0_MPWRDLCTL, 0x2E384038
71 DATA 4, MX6_MMDC_P0_MPRDDQBY0DL, 0x33333333
72 DATA 4, MX6_MMDC_P0_MPRDDQBY1DL, 0x33333333
73 DATA 4, MX6_MMDC_P0_MPRDDQBY2DL, 0x33333333
74 DATA 4, MX6_MMDC_P0_MPRDDQBY3DL, 0x33333333
75 DATA 4, MX6_MMDC_P0_MPMUR0, 0x00000800
76 DATA 4, MX6_MMDC_P0_MDPDC, 0x00020036
77 DATA 4, MX6_MMDC_P0_MDOTC, 0x09444040
78 DATA 4, MX6_MMDC_P0_MDCFG0, 0xB8BE7955
79 DATA 4, MX6_MMDC_P0_MDCFG1, 0xFF328F64
80 DATA 4, MX6_MMDC_P0_MDCFG2, 0x01FF00DB
81 DATA 4, MX6_MMDC_P0_MDMISC, 0x00011740
82 DATA 4, MX6_MMDC_P0_MDSCR, 0x00008000
83 DATA 4, MX6_MMDC_P0_MDRWD, 0x000026D2
84 DATA 4, MX6_MMDC_P0_MDOR, 0x00BE1023
85 DATA 4, MX6_MMDC_P0_MDASP, 0x00000047
86 DATA 4, MX6_MMDC_P0_MDCTL, 0x85190000
87 DATA 4, MX6_MMDC_P0_MDSCR, 0x00888032
88 DATA 4, MX6_MMDC_P0_MDSCR, 0x00008033
89 DATA 4, MX6_MMDC_P0_MDSCR, 0x00008031
90 DATA 4, MX6_MMDC_P0_MDSCR, 0x19408030
91 DATA 4, MX6_MMDC_P0_MDSCR, 0x04008040
92 DATA 4, MX6_MMDC_P0_MDREF, 0x00007800
93 DATA 4, MX6_MMDC_P0_MPODTCTRL, 0x00000007
94 DATA 4, MX6_MMDC_P0_MDPDC, 0x00025576
95 DATA 4, MX6_MMDC_P0_MAPSR, 0x00011006
96 DATA 4, MX6_MMDC_P0_MDSCR, 0x00000000
98 /* set the default clock gate to save power */
99 DATA 4, CCM_CCGR0, 0x00C03F3F
100 DATA 4, CCM_CCGR1, 0x0030FC03
101 DATA 4, CCM_CCGR2, 0x0FFFC000
102 DATA 4, CCM_CCGR3, 0x3FF00000
103 DATA 4, CCM_CCGR4, 0xFFFFF300
104 DATA 4, CCM_CCGR5, 0x0F0000F3
105 DATA 4, CCM_CCGR6, 0x00000FFF
107 /* enable AXI cache for VDOA/VPU/IPU */
108 DATA 4 MX6_IOMUXC_GPR4 0xF00000CF
109 /* set IPU AXI-id0 Qos=0xf(bypass) AXI-id1 Qos=0x7 */
110 DATA 4 MX6_IOMUXC_GPR6 0x007F007F
111 DATA 4 MX6_IOMUXC_GPR7 0x007F007F