2 * Copyright 2013 Freescale Semiconductor, Inc.
4 * Configuration settings for the Freescale i.MX6SL EVK board.
6 * SPDX-License-Identifier: GPL-2.0+
12 #include <asm/arch/imx-regs.h>
13 #include <asm/imx-common/gpio.h>
14 #include <linux/sizes.h>
15 #include "mx6_common.h"
18 #define CONFIG_DISPLAY_CPUINFO
19 #define CONFIG_DISPLAY_BOARDINFO
21 #define MACH_TYPE_MX6SLEVK 4307
22 #define CONFIG_MACH_TYPE MACH_TYPE_MX6SLEVK
24 #define CONFIG_CMDLINE_TAG
25 #define CONFIG_SETUP_MEMORY_TAGS
26 #define CONFIG_INITRD_TAG
27 #define CONFIG_REVISION_TAG
29 #define CONFIG_SYS_GENERIC_BOARD
31 /* Size of malloc() pool */
32 #define CONFIG_SYS_MALLOC_LEN (3 * SZ_1M)
34 #define CONFIG_BOARD_EARLY_INIT_F
35 #define CONFIG_MXC_GPIO
37 #define CONFIG_MXC_UART
38 #define CONFIG_MXC_UART_BASE UART1_IPS_BASE_ADDR
41 #define CONFIG_FSL_ESDHC
42 #define CONFIG_FSL_USDHC
43 #define CONFIG_SYS_FSL_ESDHC_ADDR 0
46 #define CONFIG_CMD_MMC
47 #define CONFIG_GENERIC_MMC
48 #define CONFIG_CMD_FAT
49 #define CONFIG_DOS_PARTITION
51 #define CONFIG_CMD_PING
52 #define CONFIG_CMD_DHCP
53 #define CONFIG_CMD_MII
54 #define CONFIG_CMD_NET
55 #define CONFIG_FEC_MXC
57 #define IMX_FEC_BASE ENET_BASE_ADDR
58 #define CONFIG_FEC_XCV_TYPE RMII
59 #define CONFIG_ETHPRIME "FEC"
60 #define CONFIG_FEC_MXC_PHYADDR 0
63 #define CONFIG_PHY_SMSC
65 /* allow to overwrite serial and ethaddr */
66 #define CONFIG_ENV_OVERWRITE
67 #define CONFIG_CONS_INDEX 1
68 #define CONFIG_BAUDRATE 115200
70 /* Command definition */
71 #include <config_cmd_default.h>
73 #undef CONFIG_CMD_IMLS
75 #define CONFIG_BOOTDELAY 3
77 #define CONFIG_LOADADDR 0x82000000
78 #define CONFIG_SYS_TEXT_BASE 0x87800000
80 #define CONFIG_EXTRA_ENV_SETTINGS \
84 "fdt_high=0xffffffff\0" \
85 "initrd_high=0xffffffff\0" \
86 "fdt_file=imx6sl-evk.dtb\0" \
87 "fdt_addr=0x88000000\0" \
92 "mmcroot=/dev/mmcblk0p2 rootwait rw\0" \
93 "mmcargs=setenv bootargs console=${console},${baudrate} " \
96 "fatload mmc ${mmcdev}:${mmcpart} ${loadaddr} ${script};\0" \
97 "bootscript=echo Running bootscript from mmc ...; " \
99 "loadimage=fatload mmc ${mmcdev}:${mmcpart} ${loadaddr} ${image}\0" \
100 "loadfdt=fatload mmc ${mmcdev}:${mmcpart} ${fdt_addr} ${fdt_file}\0" \
101 "mmcboot=echo Booting from mmc ...; " \
103 "if test ${boot_fdt} = yes || test ${boot_fdt} = try; then " \
104 "if run loadfdt; then " \
105 "bootz ${loadaddr} - ${fdt_addr}; " \
107 "if test ${boot_fdt} = try; then " \
110 "echo WARN: Cannot load the DT; " \
116 "netargs=setenv bootargs console=${console},${baudrate} " \
118 "ip=dhcp nfsroot=${serverip}:${nfsroot},v3,tcp\0" \
119 "netboot=echo Booting from net ...; " \
121 "if test ${ip_dyn} = yes; then " \
122 "setenv get_cmd dhcp; " \
124 "setenv get_cmd tftp; " \
126 "${get_cmd} ${image}; " \
127 "if test ${boot_fdt} = yes || test ${boot_fdt} = try; then " \
128 "if ${get_cmd} ${fdt_addr} ${fdt_file}; then " \
129 "bootz ${loadaddr} - ${fdt_addr}; " \
131 "if test ${boot_fdt} = try; then " \
134 "echo WARN: Cannot load the DT; " \
141 #define CONFIG_BOOTCOMMAND \
142 "mmc dev ${mmcdev};" \
143 "mmc dev ${mmcdev}; if mmc rescan; then " \
144 "if run loadbootscript; then " \
147 "if run loadimage; then " \
149 "else run netboot; " \
152 "else run netboot; fi"
154 /* Miscellaneous configurable options */
155 #define CONFIG_SYS_LONGHELP
156 #define CONFIG_SYS_HUSH_PARSER
157 #define CONFIG_AUTO_COMPLETE
158 #define CONFIG_SYS_CBSIZE 256
160 /* Print Buffer Size */
161 #define CONFIG_SYS_PBSIZE (CONFIG_SYS_CBSIZE + sizeof(CONFIG_SYS_PROMPT) + 16)
162 #define CONFIG_SYS_MAXARGS 16
163 #define CONFIG_SYS_BARGSIZE CONFIG_SYS_CBSIZE
165 #define CONFIG_SYS_MEMTEST_START 0x80000000
166 #define CONFIG_SYS_MEMTEST_END (CONFIG_SYS_MEMTEST_START + SZ_512M)
168 #define CONFIG_SYS_LOAD_ADDR CONFIG_LOADADDR
170 #define CONFIG_CMDLINE_EDITING
171 #define CONFIG_STACKSIZE SZ_128K
173 /* Physical Memory Map */
174 #define CONFIG_NR_DRAM_BANKS 1
175 #define PHYS_SDRAM MMDC0_ARB_BASE_ADDR
176 #define PHYS_SDRAM_SIZE SZ_1G
178 #define CONFIG_SYS_SDRAM_BASE PHYS_SDRAM
179 #define CONFIG_SYS_INIT_RAM_ADDR IRAM_BASE_ADDR
180 #define CONFIG_SYS_INIT_RAM_SIZE IRAM_SIZE
182 #define CONFIG_SYS_INIT_SP_OFFSET \
183 (CONFIG_SYS_INIT_RAM_SIZE - GENERATED_GBL_DATA_SIZE)
184 #define CONFIG_SYS_INIT_SP_ADDR \
185 (CONFIG_SYS_INIT_RAM_ADDR + CONFIG_SYS_INIT_SP_OFFSET)
187 /* FLASH and environment organization */
188 #define CONFIG_SYS_NO_FLASH
190 #define CONFIG_ENV_OFFSET (6 * SZ_64K)
191 #define CONFIG_ENV_SIZE SZ_8K
192 #define CONFIG_ENV_IS_IN_MMC
193 #define CONFIG_SYS_MMC_ENV_DEV 0
195 #define CONFIG_OF_LIBFDT
196 #define CONFIG_CMD_BOOTZ
198 #ifndef CONFIG_SYS_DCACHE_OFF
199 #define CONFIG_CMD_CACHE
202 #define CONFIG_CMD_SF
204 #define CONFIG_SPI_FLASH
205 #define CONFIG_SPI_FLASH_STMICRO
206 #define CONFIG_MXC_SPI
207 #define CONFIG_SF_DEFAULT_BUS 0
208 #define CONFIG_SF_DEFAULT_CS (0 | (IMX_GPIO_NR(4, 11) << 8))
209 #define CONFIG_SF_DEFAULT_SPEED 20000000
210 #define CONFIG_SF_DEFAULT_MODE SPI_MODE_0
213 #endif /* __CONFIG_H */