1 /* SPDX-License-Identifier: GPL-2.0+ */
4 * Copyright 2018 Emcraft Systems
5 * Copyright 2022 Purism
15 #include <linux/sizes.h>
16 #include <asm/arch/imx-regs.h>
18 #ifdef CONFIG_SPL_BUILD
20 #define CONFIG_SPL_ABORT_ON_RAW_IMAGE /* For RAW image gives a error info not panic */
22 #define CONFIG_POWER_BD71837
23 #define CONFIG_POWER_BD71837_I2C_BUS 0
24 #define CONFIG_POWER_BD71837_I2C_ADDR 0x4B
26 #endif /* CONFIG_SPL_BUILD*/
28 #define CFG_SYS_FSL_USDHC_NUM 2
30 #define CONSOLE_ON_UART1
32 #ifdef CONSOLE_ON_UART1
33 #define CONFIG_MXC_UART_BASE UART1_BASE_ADDR
34 #define CONSOLE_UART_CLK 0
35 #define CONSOLE "ttymxc0"
36 #elif defined(CONSOLE_ON_UART2)
37 #define CONFIG_MXC_UART_BASE UART2_BASE_ADDR
38 #define CONSOLE_UART_CLK 1
39 #define CONSOLE "ttymxc1"
40 #elif defined(CONSOLE_ON_UART3)
41 #define CONFIG_MXC_UART_BASE UART3_BASE_ADDR
42 #define CONSOLE_UART_CLK 2
43 #define CONSOLE "ttymxc2"
44 #elif defined(CONSOLE_ON_UART4)
45 #define CONFIG_MXC_UART_BASE UART4_BASE_ADDR
46 #define CONSOLE_UART_CLK 3
47 #define CONSOLE "ttymxc3"
49 #define CONFIG_MXC_UART_BASE UART1_BASE_ADDR
50 #define CONSOLE_UART_CLK 0
51 #define CONSOLE "ttymxc0"
54 #ifndef CONFIG_SPL_BUILD
55 #define BOOT_TARGET_DEVICES(func) \
59 #include <config_distro_bootcmd.h>
64 /* Initial environment variables */
65 #define CONFIG_EXTRA_ENV_SETTINGS \
66 "scriptaddr=0x80000000\0" \
67 "pxefile_addr_r=0x80100000\0" \
68 "kernel_addr_r=0x80800000\0" \
69 "fdt_addr_r=0x84800000\0" \
70 "ramdisk_addr_r=0x85000000\0" \
71 "console=" CONSOLE ",115200\0" \
72 "bootargs=u_boot_version=" PLAIN_VERSION "\0" \
73 "stdin=usbacm,serial\0" \
74 "stdout=usbacm,serial\0" \
75 "stderr=usbacm,serial\0" \
78 /* Link Definitions */
80 #define CFG_SYS_INIT_RAM_ADDR 0x40000000
81 #define CFG_SYS_INIT_RAM_SIZE 0x80000
83 #define CFG_SYS_SDRAM_BASE 0x40000000
84 #define PHYS_SDRAM 0x40000000
85 #define PHYS_SDRAM_SIZE 0xc0000000 /* 3GB LPDDR4 one Rank */
87 /* Monitor Command Prompt */
89 #define CFG_SYS_FSL_ESDHC_ADDR 0