1 /* SPDX-License-Identifier: GPL-2.0-or-later
3 * Copyright (C) 2020 PHYTEC Messtechnik GmbH
4 * Author: Teresa Remmet <t.remmet@phytec.de>
7 #ifndef __PHYCORE_IMX8MP_H
8 #define __PHYCORE_IMX8MP_H
10 #include <linux/sizes.h>
11 #include <asm/arch/imx-regs.h>
13 #define CONFIG_SYS_BOOTM_LEN SZ_64M
15 #define CONFIG_SYS_MONITOR_LEN SZ_512K
16 #define CONFIG_SYS_UBOOT_BASE \
17 (QSPI0_AMBA_BASE + CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR * 512)
19 #ifdef CONFIG_SPL_BUILD
20 #define CONFIG_SPL_ABORT_ON_RAW_IMAGE
22 #define CONFIG_POWER_PCA9450
26 #define CONFIG_EXTRA_ENV_SETTINGS \
28 "console=ttymxc0,115200\0" \
29 "fdt_addr=0x48000000\0" \
30 "fdt_file=" CONFIG_DEFAULT_FDT_FILE "\0" \
32 "mmcdev=" __stringify(CONFIG_SYS_MMC_ENV_DEV) "\0" \
35 "mmcautodetect=yes\0" \
36 "mmcargs=setenv bootargs console=${console} " \
37 "root=/dev/mmcblk${mmcdev}p${mmcroot} rootwait rw\0" \
38 "loadimage=fatload mmc ${mmcdev}:${mmcpart} ${loadaddr} ${image}\0" \
39 "loadfdt=fatload mmc ${mmcdev}:${mmcpart} ${fdt_addr} ${fdt_file}\0" \
40 "mmcboot=echo Booting from mmc ...; " \
42 "if run loadfdt; then " \
43 "booti ${loadaddr} - ${fdt_addr}; " \
45 "echo WARN: Cannot load the DT; " \
48 "netargs=setenv bootargs console=${console} root=/dev/nfs ip=dhcp " \
49 "nfsroot=${serverip}:${nfsroot},v3,tcp\0" \
50 "netboot=echo Booting from net ...; " \
52 "if test ${ip_dyn} = yes; then " \
53 "setenv get_cmd dhcp; " \
55 "setenv get_cmd tftp; " \
57 "${get_cmd} ${loadaddr} ${image}; " \
58 "if ${get_cmd} ${fdt_addr} ${fdt_file}; then " \
59 "booti ${loadaddr} - ${fdt_addr}; " \
61 "echo WARN: Cannot load the DT; " \
64 /* Link Definitions */
66 #define CONFIG_SYS_INIT_RAM_ADDR 0x40000000
67 #define CONFIG_SYS_INIT_RAM_SIZE SZ_512K
70 #define CONFIG_SYS_SDRAM_BASE 0x40000000
72 #define PHYS_SDRAM 0x40000000
73 #define PHYS_SDRAM_SIZE 0x80000000
76 #define CONFIG_MXC_UART_BASE UART_BASE_ADDR(1)
78 #endif /* __PHYCORE_IMX8MP_H */