1 /* SPDX-License-Identifier: GPL-2.0+ */
3 * Copyright (C) 2013 Marek Vasut <marex@denx.de>
5 #ifndef __CONFIGS_MX23_OLINUXINO_H__
6 #define __CONFIGS_MX23_OLINUXINO_H__
8 /* System configurations */
9 #define CONFIG_MACH_TYPE 4105
13 /* Memory configuration */
14 #define PHYS_SDRAM_1 0x40000000 /* Base address */
15 #define PHYS_SDRAM_1_SIZE 0x08000000 /* Max 128 MB RAM */
16 #define CONFIG_SYS_SDRAM_BASE PHYS_SDRAM_1
22 #define CONFIG_EHCI_MXS_PORT0
23 #define CONFIG_USB_MAX_CONTROLLER_COUNT 1
29 #define CONFIG_BOOTFILE "uImage"
30 #define CONFIG_SYS_LOAD_ADDR 0x42000000
32 /* Extra Environment */
33 #define CONFIG_EXTRA_ENV_SETTINGS \
34 "update_sd_firmware_filename=u-boot.sd\0" \
35 "update_sd_firmware=" /* Update the SD firmware partition */ \
36 "if mmc rescan ; then " \
37 "if tftp ${update_sd_firmware_filename} ; then " \
38 "setexpr fw_sz ${filesize} / 0x200 ; " /* SD block size */ \
39 "setexpr fw_sz ${fw_sz} + 1 ; " \
40 "mmc write ${loadaddr} 0x800 ${fw_sz} ; " \
46 "fdt_file=imx23-olinuxino.dtb\0" \
47 "fdt_addr=0x41000000\0" \
52 "mmcroot=/dev/mmcblk0p3 rw rootwait\0" \
53 "mmcargs=setenv bootargs console=${console},${baudrate} " \
56 "fatload mmc ${mmcdev}:${mmcpart} ${loadaddr} ${script};\0" \
57 "bootscript=echo Running bootscript from mmc ...; " \
59 "loaduimage=fatload mmc ${mmcdev}:${mmcpart} ${loadaddr} ${uimage}\0" \
60 "loadfdt=fatload mmc ${mmcdev}:${mmcpart} ${fdt_addr} ${fdt_file}\0" \
61 "mmcboot=echo Booting from mmc ...; " \
63 "if test ${boot_fdt} = yes || test ${boot_fdt} = try; then " \
64 "if run loadfdt; then " \
65 "bootm ${loadaddr} - ${fdt_addr}; " \
67 "if test ${boot_fdt} = try; then " \
70 "echo WARN: Cannot load the DT; " \
76 "netargs=setenv bootargs console=${console},${baudrate} " \
78 "ip=dhcp nfsroot=${serverip}:${nfsroot},v3,tcp\0" \
79 "netboot=echo Booting from net ...; " \
82 "if test ${ip_dyn} = yes; then " \
83 "setenv get_cmd dhcp; " \
85 "setenv get_cmd tftp; " \
87 "${get_cmd} ${uimage}; " \
88 "if test ${boot_fdt} = yes; then " \
89 "if ${get_cmd} ${fdt_addr} ${fdt_file}; then " \
90 "bootm ${loadaddr} - ${fdt_addr}; " \
92 "if test ${boot_fdt} = try; then " \
95 "echo WARN: Cannot load the DT; " \
102 #define CONFIG_BOOTCOMMAND \
103 "mmc dev ${mmcdev}; if mmc rescan; then " \
104 "if run loadbootscript; then " \
107 "if run loaduimage; then " \
109 "else run netboot; " \
112 "else run netboot; fi"
114 /* The rest of the configuration is shared */
115 #include <configs/mxs.h>
117 #endif /* __CONFIGS_MX23_OLINUXINO_H__ */