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