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_MXC_UART 238be4f40eSStefano Babic 248be4f40eSStefano Babic #ifdef CONFIG_SPL 258be4f40eSStefano Babic #define CONFIG_SYS_SPI_U_BOOT_OFFS (64 * 1024) 268be4f40eSStefano Babic #define CONFIG_SPL_SPI_LOAD 278be4f40eSStefano Babic #include "imx6_spl.h" 288be4f40eSStefano Babic #endif 298be4f40eSStefano Babic 308be4f40eSStefano Babic /* MMC Configs */ 318be4f40eSStefano Babic #define CONFIG_SYS_FSL_ESDHC_ADDR 0 328be4f40eSStefano Babic #define CONFIG_SYS_FSL_USDHC_NUM 2 338be4f40eSStefano Babic 348be4f40eSStefano Babic /* I2C config */ 358be4f40eSStefano Babic #define CONFIG_SYS_I2C 368be4f40eSStefano Babic #define CONFIG_SYS_I2C_MXC 378be4f40eSStefano Babic #define CONFIG_SYS_I2C_MXC_I2C1 /* enable I2C bus 1 */ 388be4f40eSStefano Babic #define CONFIG_SYS_I2C_MXC_I2C2 /* enable I2C bus 2 */ 398be4f40eSStefano Babic #define CONFIG_SYS_I2C_MXC_I2C3 /* enable I2C bus 3 */ 408be4f40eSStefano Babic #define CONFIG_SYS_I2C_SPEED 100000 418be4f40eSStefano Babic 428be4f40eSStefano Babic /* PMIC */ 438be4f40eSStefano Babic #define CONFIG_POWER 448be4f40eSStefano Babic #define CONFIG_POWER_I2C 458be4f40eSStefano Babic #define CONFIG_POWER_PFUZE100 468be4f40eSStefano Babic #define CONFIG_POWER_PFUZE100_I2C_ADDR 0x08 478be4f40eSStefano Babic 488be4f40eSStefano Babic /* Commands */ 498be4f40eSStefano Babic #define CONFIG_MXC_SPI 508be4f40eSStefano Babic #define CONFIG_SF_DEFAULT_BUS 3 518be4f40eSStefano Babic #define CONFIG_SF_DEFAULT_CS 0 528be4f40eSStefano Babic #define CONFIG_SF_DEFAULT_SPEED 20000000 538be4f40eSStefano Babic #define CONFIG_SF_DEFAULT_MODE SPI_MODE_0 548be4f40eSStefano Babic 558be4f40eSStefano Babic /* allow to overwrite serial and ethaddr */ 568be4f40eSStefano Babic #define CONFIG_ENV_OVERWRITE 578be4f40eSStefano Babic #define CONFIG_MXC_UART_BASE UART2_BASE 588be4f40eSStefano Babic 598be4f40eSStefano Babic /* Command definition */ 608be4f40eSStefano Babic #undef CONFIG_CMD_IMLS 618be4f40eSStefano Babic 628be4f40eSStefano Babic #define CONFIG_BOARD_NAME EL6Q 638be4f40eSStefano Babic 648be4f40eSStefano Babic #define CONFIG_ENV_VARS_UBOOT_RUNTIME_CONFIG 658be4f40eSStefano Babic #define CONFIG_EXTRA_ENV_SETTINGS \ 668be4f40eSStefano Babic "board="__stringify(CONFIG_BOARD_NAME)"\0" \ 678be4f40eSStefano Babic "cma_size="__stringify(EL6Q_CMA_SIZE)"\0" \ 688be4f40eSStefano Babic "chp_size="__stringify(EL6Q_COHERENT_POOL_SIZE)"\0" \ 6912ca05a3SSimon Glass "console=" CONSOLE_DEV "\0" \ 708be4f40eSStefano Babic "fdtfile=undefined\0" \ 718be4f40eSStefano Babic "fdt_high=0xffffffff\0" \ 728be4f40eSStefano Babic "fdt_addr_r=0x18000000\0" \ 738be4f40eSStefano Babic "fdt_addr=0x18000000\0" \ 748be4f40eSStefano Babic "findfdt=setenv fdtfile " CONFIG_DEFAULT_FDT_FILE "\0" \ 758be4f40eSStefano Babic "kernel_addr_r=" __stringify(CONFIG_LOADADDR) "\0" \ 768be4f40eSStefano Babic "scriptaddr=" __stringify(CONFIG_LOADADDR) "\0" \ 778be4f40eSStefano Babic "pxefile_addr_r=" __stringify(CONFIG_LOADADDR) "\0" \ 788be4f40eSStefano Babic BOOTENV 798be4f40eSStefano Babic 808be4f40eSStefano Babic #define BOOT_TARGET_DEVICES(func) \ 818be4f40eSStefano Babic func(MMC, mmc, 0) \ 828be4f40eSStefano Babic func(MMC, mmc, 1) \ 838be4f40eSStefano Babic func(PXE, PXE, na) \ 848be4f40eSStefano Babic func(DHCP, dhcp, na) 858be4f40eSStefano Babic 868be4f40eSStefano Babic #define CONFIG_BOOTCOMMAND \ 878be4f40eSStefano Babic "run findfdt; " \ 888be4f40eSStefano Babic "run distro_bootcmd" 898be4f40eSStefano Babic 908be4f40eSStefano Babic #include <config_distro_bootcmd.h> 918be4f40eSStefano Babic 928be4f40eSStefano Babic #define CONFIG_ARP_TIMEOUT 200UL 938be4f40eSStefano Babic 948be4f40eSStefano Babic #define CONFIG_CMD_MEMTEST 958be4f40eSStefano Babic 968be4f40eSStefano Babic #define CONFIG_SYS_MEMTEST_START 0x10000000 978be4f40eSStefano Babic #define CONFIG_SYS_MEMTEST_END 0x10800000 988be4f40eSStefano Babic #define CONFIG_SYS_MEMTEST_SCRATCH 0x10800000 998be4f40eSStefano Babic 1008be4f40eSStefano Babic /* Physical Memory Map */ 1018be4f40eSStefano Babic #define CONFIG_NR_DRAM_BANKS 1 1028be4f40eSStefano Babic #define PHYS_SDRAM MMDC0_ARB_BASE_ADDR 1038be4f40eSStefano Babic 1048be4f40eSStefano Babic #define CONFIG_SYS_SDRAM_BASE PHYS_SDRAM 1058be4f40eSStefano Babic #define CONFIG_SYS_INIT_RAM_ADDR IRAM_BASE_ADDR 1068be4f40eSStefano Babic #define CONFIG_SYS_INIT_RAM_SIZE IRAM_SIZE 1078be4f40eSStefano Babic 1088be4f40eSStefano Babic #define CONFIG_SYS_INIT_SP_OFFSET \ 1098be4f40eSStefano Babic (CONFIG_SYS_INIT_RAM_SIZE - GENERATED_GBL_DATA_SIZE) 1108be4f40eSStefano Babic #define CONFIG_SYS_INIT_SP_ADDR \ 1118be4f40eSStefano Babic (CONFIG_SYS_INIT_RAM_ADDR + CONFIG_SYS_INIT_SP_OFFSET) 1128be4f40eSStefano Babic 113*e856bdcfSMasahiro Yamada /* environment organization */ 1148be4f40eSStefano Babic 1158be4f40eSStefano Babic #define CONFIG_ENV_SIZE (8 * 1024) 1168be4f40eSStefano Babic 1178be4f40eSStefano Babic #if defined(CONFIG_ENV_IS_IN_MMC) 1188be4f40eSStefano Babic #define CONFIG_SYS_MMC_ENV_DEV 1 1198be4f40eSStefano Babic #define CONFIG_SYS_MMC_ENV_PART 2 1208be4f40eSStefano Babic #define CONFIG_ENV_OFFSET 0x0 1218be4f40eSStefano Babic #endif 1228be4f40eSStefano Babic 1238be4f40eSStefano Babic #endif /* __EL6Q_COMMON_CONFIG_H */ 124