18be4f40eSStefano Babic /* 28be4f40eSStefano Babic * Copyright (C) Stefano Babic <sbabic@denx.de> 38be4f40eSStefano Babic * 48be4f40eSStefano Babic * Configuration settings for the E+L i.MX6Q DO82 board. 58be4f40eSStefano Babic * 68be4f40eSStefano Babic * SPDX-License-Identifier: GPL-2.0+ 78be4f40eSStefano Babic */ 88be4f40eSStefano Babic 98be4f40eSStefano Babic #ifndef __EL6Q_COMMON_CONFIG_H 108be4f40eSStefano Babic #define __EL6Q_COMMON_CONFIG_H 118be4f40eSStefano Babic 128be4f40eSStefano Babic #define CONFIG_BOARD_NAME EL6Q 138be4f40eSStefano Babic 148be4f40eSStefano Babic #include <config_distro_defaults.h> 158be4f40eSStefano Babic #include "mx6_common.h" 168be4f40eSStefano Babic 178be4f40eSStefano Babic #define CONFIG_IMX_THERMAL 188be4f40eSStefano Babic 198be4f40eSStefano Babic /* Size of malloc() pool */ 208be4f40eSStefano Babic #define CONFIG_SYS_MALLOC_LEN (10 * SZ_1M) 218be4f40eSStefano Babic 228be4f40eSStefano Babic #define CONFIG_BOARD_EARLY_INIT_F 238be4f40eSStefano Babic #define CONFIG_BOARD_LATE_INIT 248be4f40eSStefano Babic 258be4f40eSStefano Babic #define CONFIG_MXC_UART 268be4f40eSStefano Babic 278be4f40eSStefano Babic #ifdef CONFIG_SPL 288be4f40eSStefano Babic #define CONFIG_SYS_SPI_U_BOOT_OFFS (64 * 1024) 298be4f40eSStefano Babic #define CONFIG_SPL_SPI_LOAD 308be4f40eSStefano Babic #include "imx6_spl.h" 318be4f40eSStefano Babic #endif 328be4f40eSStefano Babic 338be4f40eSStefano Babic /* MMC Configs */ 348be4f40eSStefano Babic #define CONFIG_SYS_FSL_ESDHC_ADDR 0 358be4f40eSStefano Babic #define CONFIG_SYS_FSL_USDHC_NUM 2 368be4f40eSStefano Babic 378be4f40eSStefano Babic /* I2C config */ 388be4f40eSStefano Babic #define CONFIG_SYS_I2C 398be4f40eSStefano Babic #define CONFIG_SYS_I2C_MXC 408be4f40eSStefano Babic #define CONFIG_SYS_I2C_MXC_I2C1 /* enable I2C bus 1 */ 418be4f40eSStefano Babic #define CONFIG_SYS_I2C_MXC_I2C2 /* enable I2C bus 2 */ 428be4f40eSStefano Babic #define CONFIG_SYS_I2C_MXC_I2C3 /* enable I2C bus 3 */ 438be4f40eSStefano Babic #define CONFIG_SYS_I2C_SPEED 100000 448be4f40eSStefano Babic 458be4f40eSStefano Babic /* PMIC */ 468be4f40eSStefano Babic #define CONFIG_POWER 478be4f40eSStefano Babic #define CONFIG_POWER_I2C 488be4f40eSStefano Babic #define CONFIG_POWER_PFUZE100 498be4f40eSStefano Babic #define CONFIG_POWER_PFUZE100_I2C_ADDR 0x08 508be4f40eSStefano Babic 518be4f40eSStefano Babic /* Commands */ 528be4f40eSStefano Babic #define CONFIG_MXC_SPI 538be4f40eSStefano Babic #define CONFIG_SF_DEFAULT_BUS 3 548be4f40eSStefano Babic #define CONFIG_SF_DEFAULT_CS 0 558be4f40eSStefano Babic #define CONFIG_SF_DEFAULT_SPEED 20000000 568be4f40eSStefano Babic #define CONFIG_SF_DEFAULT_MODE SPI_MODE_0 578be4f40eSStefano Babic 588be4f40eSStefano Babic /* allow to overwrite serial and ethaddr */ 598be4f40eSStefano Babic #define CONFIG_ENV_OVERWRITE 608be4f40eSStefano Babic #define CONFIG_MXC_UART_BASE UART2_BASE 618be4f40eSStefano Babic #define CONFIG_BAUDRATE 115200 628be4f40eSStefano Babic 638be4f40eSStefano Babic /* Command definition */ 648be4f40eSStefano Babic 658be4f40eSStefano Babic #define CONFIG_CMD_BMODE 668be4f40eSStefano Babic #define CONFIG_CMD_BOOTZ 678be4f40eSStefano Babic #undef CONFIG_CMD_IMLS 688be4f40eSStefano Babic 698be4f40eSStefano Babic #define CONFIG_BOARD_NAME EL6Q 708be4f40eSStefano Babic 718be4f40eSStefano Babic #define CONFIG_ENV_VARS_UBOOT_RUNTIME_CONFIG 728be4f40eSStefano Babic #define CONFIG_EXTRA_ENV_SETTINGS \ 738be4f40eSStefano Babic "board="__stringify(CONFIG_BOARD_NAME)"\0" \ 748be4f40eSStefano Babic "cma_size="__stringify(EL6Q_CMA_SIZE)"\0" \ 758be4f40eSStefano Babic "chp_size="__stringify(EL6Q_COHERENT_POOL_SIZE)"\0" \ 76*12ca05a3SSimon Glass "console=" CONSOLE_DEV "\0" \ 778be4f40eSStefano Babic "fdtfile=undefined\0" \ 788be4f40eSStefano Babic "fdt_high=0xffffffff\0" \ 798be4f40eSStefano Babic "fdt_addr_r=0x18000000\0" \ 808be4f40eSStefano Babic "fdt_addr=0x18000000\0" \ 818be4f40eSStefano Babic "findfdt=setenv fdtfile " CONFIG_DEFAULT_FDT_FILE "\0" \ 828be4f40eSStefano Babic "kernel_addr_r=" __stringify(CONFIG_LOADADDR) "\0" \ 838be4f40eSStefano Babic "scriptaddr=" __stringify(CONFIG_LOADADDR) "\0" \ 848be4f40eSStefano Babic "pxefile_addr_r=" __stringify(CONFIG_LOADADDR) "\0" \ 858be4f40eSStefano Babic BOOTENV 868be4f40eSStefano Babic 878be4f40eSStefano Babic #define BOOT_TARGET_DEVICES(func) \ 888be4f40eSStefano Babic func(MMC, mmc, 0) \ 898be4f40eSStefano Babic func(MMC, mmc, 1) \ 908be4f40eSStefano Babic func(PXE, PXE, na) \ 918be4f40eSStefano Babic func(DHCP, dhcp, na) 928be4f40eSStefano Babic 938be4f40eSStefano Babic #define CONFIG_BOOTCOMMAND \ 948be4f40eSStefano Babic "run findfdt; " \ 958be4f40eSStefano Babic "run distro_bootcmd" 968be4f40eSStefano Babic 978be4f40eSStefano Babic #include <config_distro_bootcmd.h> 988be4f40eSStefano Babic 998be4f40eSStefano Babic #define CONFIG_ARP_TIMEOUT 200UL 1008be4f40eSStefano Babic 1018be4f40eSStefano Babic #define CONFIG_CMD_MEMTEST 1028be4f40eSStefano Babic 1038be4f40eSStefano Babic #define CONFIG_SYS_MEMTEST_START 0x10000000 1048be4f40eSStefano Babic #define CONFIG_SYS_MEMTEST_END 0x10800000 1058be4f40eSStefano Babic #define CONFIG_SYS_MEMTEST_SCRATCH 0x10800000 1068be4f40eSStefano Babic 1078be4f40eSStefano Babic #define CONFIG_STACKSIZE (128 * 1024) 1088be4f40eSStefano Babic 1098be4f40eSStefano Babic /* Physical Memory Map */ 1108be4f40eSStefano Babic #define CONFIG_NR_DRAM_BANKS 1 1118be4f40eSStefano Babic #define PHYS_SDRAM MMDC0_ARB_BASE_ADDR 1128be4f40eSStefano Babic 1138be4f40eSStefano Babic #define CONFIG_SYS_SDRAM_BASE PHYS_SDRAM 1148be4f40eSStefano Babic #define CONFIG_SYS_INIT_RAM_ADDR IRAM_BASE_ADDR 1158be4f40eSStefano Babic #define CONFIG_SYS_INIT_RAM_SIZE IRAM_SIZE 1168be4f40eSStefano Babic 1178be4f40eSStefano Babic #define CONFIG_SYS_INIT_SP_OFFSET \ 1188be4f40eSStefano Babic (CONFIG_SYS_INIT_RAM_SIZE - GENERATED_GBL_DATA_SIZE) 1198be4f40eSStefano Babic #define CONFIG_SYS_INIT_SP_ADDR \ 1208be4f40eSStefano Babic (CONFIG_SYS_INIT_RAM_ADDR + CONFIG_SYS_INIT_SP_OFFSET) 1218be4f40eSStefano Babic 1228be4f40eSStefano Babic /* FLASH and environment organization */ 1238be4f40eSStefano Babic #define CONFIG_SYS_NO_FLASH 1248be4f40eSStefano Babic 1258be4f40eSStefano Babic #define CONFIG_ENV_SIZE (8 * 1024) 1268be4f40eSStefano Babic 1278be4f40eSStefano Babic #define CONFIG_ENV_IS_IN_MMC 1288be4f40eSStefano Babic 1298be4f40eSStefano Babic #if defined(CONFIG_ENV_IS_IN_MMC) 1308be4f40eSStefano Babic #define CONFIG_SYS_MMC_ENV_DEV 1 1318be4f40eSStefano Babic #define CONFIG_SYS_MMC_ENV_PART 2 1328be4f40eSStefano Babic #define CONFIG_ENV_OFFSET 0x0 1338be4f40eSStefano Babic #endif 1348be4f40eSStefano Babic 1358be4f40eSStefano Babic #endif /* __EL6Q_COMMON_CONFIG_H */ 136