1 /* SPDX-License-Identifier: GPL-2.0+ */
3 * Copyright (C) 2015 Freescale Semiconductor, Inc.
5 * Configuration settings for the SolidRun mx6 based boards
7 #ifndef __MX6CUBOXI_CONFIG_H
8 #define __MX6CUBOXI_CONFIG_H
10 #include <linux/stringify.h>
12 #include "mx6_common.h"
16 #define CONFIG_IMX_THERMAL
18 #define CONFIG_SYS_MALLOC_LEN (10 * SZ_1M)
19 #define CONFIG_MXC_UART
22 #define CONFIG_SYS_FSL_ESDHC_ADDR USDHC2_BASE_ADDR
24 /* SATA Configuration */
25 #ifdef CONFIG_CMD_SATA
26 #define CONFIG_SYS_SATA_MAX_DEVICE 1
27 #define CONFIG_DWC_AHSATA_PORT_ID 0
28 #define CONFIG_DWC_AHSATA_BASE_ADDR SATA_ARB_BASE_ADDR
33 #define CONFIG_VIDEO_BMP_RLE8
34 #define CONFIG_SPLASH_SCREEN
35 #define CONFIG_SPLASH_SCREEN_ALIGN
36 #define CONFIG_BMP_16BPP
37 #define CONFIG_VIDEO_LOGO
38 #define CONFIG_VIDEO_BMP_LOGO
39 #define CONFIG_IMX_HDMI
40 #define CONFIG_IMX_VIDEO_SKIP
43 #define CONFIG_MXC_USB_PORTSC (PORT_PTS_UTMI | PORT_PTS_PTW)
45 /* Command definition */
47 #define CONFIG_MXC_UART_BASE UART1_BASE
48 #define CONSOLE_DEV "ttymxc0"
49 #define CONFIG_SYS_MMC_ENV_DEV 0 /* SDHC2 */
51 #ifndef CONFIG_SPL_BUILD
52 #define CONFIG_EXTRA_ENV_SETTINGS \
53 "som_rev=undefined\0" \
54 "has_emmc=undefined\0" \
55 "fdtfile=undefined\0" \
56 "fdt_addr_r=0x18000000\0" \
57 "fdt_addr=0x18000000\0" \
58 "kernel_addr_r=" __stringify(CONFIG_LOADADDR) "\0" \
59 "pxefile_addr_r=" __stringify(CONFIG_LOADADDR) "\0" \
60 "scriptaddr=" __stringify(CONFIG_LOADADDR) "\0" \
61 "ramdisk_addr_r=0x13000000\0" \
62 "ramdiskaddr=0x13000000\0" \
63 "initrd_high=0xffffffff\0" \
65 "console=" CONSOLE_DEV ",115200\0" \
66 "bootm_size=0x10000000\0" \
67 "mmcdev=" __stringify(CONFIG_SYS_MMC_ENV_DEV) "\0" \
68 "finduuid=part uuid mmc 0:1 uuid\0" \
69 "update_sd_firmware=" \
70 "if test ${ip_dyn} = yes; then " \
71 "setenv get_cmd dhcp; " \
73 "setenv get_cmd tftp; " \
75 "if mmc dev ${mmcdev}; then " \
76 "if ${get_cmd} ${update_sd_firmware_filename}; then " \
77 "setexpr fw_sz ${filesize} / 0x200; " \
78 "setexpr fw_sz ${fw_sz} + 1; " \
79 "mmc write ${loadaddr} 0x2 ${fw_sz}; " \
83 "if test ${board_rev} = MX6Q; then " \
84 "setenv fdtprefix imx6q; fi; " \
85 "if test ${board_rev} = MX6DL; then " \
86 "setenv fdtprefix imx6dl; fi; " \
87 "if test ${som_rev} = V15; then " \
88 "setenv fdtsuffix -som-v15; fi; " \
89 "if test ${has_emmc} = yes; then " \
90 "setenv emmcsuffix -emmc; fi; " \
91 "if test ${board_name} = HUMMINGBOARD2 ; then " \
92 "setenv fdtfile ${fdtprefix}-hummingboard2${emmcsuffix}${fdtsuffix}.dtb; fi; " \
93 "if test ${board_name} = HUMMINGBOARD ; then " \
94 "setenv fdtfile ${fdtprefix}-hummingboard${emmcsuffix}${fdtsuffix}.dtb; fi; " \
95 "if test ${board_name} = CUBOXI ; then " \
96 "setenv fdtfile ${fdtprefix}-cubox-i${emmcsuffix}${fdtsuffix}.dtb; fi; " \
97 "if test ${fdtfile} = undefined; then " \
98 "echo WARNING: Could not determine dtb to use; fi; \0" \
101 #define BOOT_TARGET_DEVICES(func) \
104 func(SATA, sata, 0) \
109 #include <config_distro_bootcmd.h>
112 #define CONFIG_EXTRA_ENV_SETTINGS
113 #endif /* CONFIG_SPL_BUILD */
115 /* Physical Memory Map */
116 #define CONFIG_SYS_SDRAM_BASE MMDC0_ARB_BASE_ADDR
117 #define CONFIG_SYS_INIT_RAM_ADDR IRAM_BASE_ADDR
118 #define CONFIG_SYS_INIT_RAM_SIZE IRAM_SIZE
120 #define CONFIG_SYS_INIT_SP_OFFSET \
121 (CONFIG_SYS_INIT_RAM_SIZE - GENERATED_GBL_DATA_SIZE)
122 #define CONFIG_SYS_INIT_SP_ADDR \
123 (CONFIG_SYS_INIT_RAM_ADDR + CONFIG_SYS_INIT_SP_OFFSET)
125 /* Environment organization */
127 #endif /* __MX6CUBOXI_CONFIG_H */