1860b32eeSFabio Estevam /* 2860b32eeSFabio Estevam * Copyright (C) 2011 Freescale Semiconductor, Inc. 3860b32eeSFabio Estevam * 4c4c596fbSFabio Estevam * Configuration settings for the MX53SMD Freescale board. 5860b32eeSFabio Estevam * 61a459660SWolfgang Denk * SPDX-License-Identifier: GPL-2.0+ 7860b32eeSFabio Estevam */ 8860b32eeSFabio Estevam 9860b32eeSFabio Estevam #ifndef __CONFIG_H 10860b32eeSFabio Estevam #define __CONFIG_H 11860b32eeSFabio Estevam 12860b32eeSFabio Estevam #define CONFIG_MX53 13860b32eeSFabio Estevam 14860b32eeSFabio Estevam #define CONFIG_DISPLAY_CPUINFO 15860b32eeSFabio Estevam #define CONFIG_DISPLAY_BOARDINFO 16860b32eeSFabio Estevam 17c4c596fbSFabio Estevam #define CONFIG_MACH_TYPE MACH_TYPE_MX53_SMD 18c4c596fbSFabio Estevam 19860b32eeSFabio Estevam #include <asm/arch/imx-regs.h> 20860b32eeSFabio Estevam 21860b32eeSFabio Estevam #define CONFIG_CMDLINE_TAG /* enable passing of ATAGs */ 22860b32eeSFabio Estevam #define CONFIG_SETUP_MEMORY_TAGS 23860b32eeSFabio Estevam #define CONFIG_INITRD_TAG 24fd622f23SFabio Estevam #define CONFIG_REVISION_TAG 25860b32eeSFabio Estevam 265a416df0SFabio Estevam #define CONFIG_SYS_GENERIC_BOARD 275a416df0SFabio Estevam 28860b32eeSFabio Estevam /* Size of malloc() pool */ 29860b32eeSFabio Estevam #define CONFIG_SYS_MALLOC_LEN (CONFIG_ENV_SIZE + 2 * 1024 * 1024) 30860b32eeSFabio Estevam 31860b32eeSFabio Estevam #define CONFIG_BOARD_EARLY_INIT_F 32860b32eeSFabio Estevam #define CONFIG_MXC_GPIO 33860b32eeSFabio Estevam 34860b32eeSFabio Estevam #define CONFIG_MXC_UART 3540f6fffeSStefano Babic #define CONFIG_MXC_UART_BASE UART1_BASE 36860b32eeSFabio Estevam 37860b32eeSFabio Estevam /* I2C Configs */ 38860b32eeSFabio Estevam #define CONFIG_CMD_I2C 39b089d039Strem #define CONFIG_SYS_I2C 40b089d039Strem #define CONFIG_SYS_I2C_MXC 41*f8cb101eSYork Sun #define CONFIG_SYS_I2C_MXC_I2C3 /* enable I2C bus 3 */ 42860b32eeSFabio Estevam 43860b32eeSFabio Estevam /* MMC Configs */ 44860b32eeSFabio Estevam #define CONFIG_FSL_ESDHC 45860b32eeSFabio Estevam #define CONFIG_SYS_FSL_ESDHC_ADDR 0 46860b32eeSFabio Estevam #define CONFIG_SYS_FSL_ESDHC_NUM 1 47860b32eeSFabio Estevam 48860b32eeSFabio Estevam #define CONFIG_MMC 49860b32eeSFabio Estevam #define CONFIG_CMD_MMC 50860b32eeSFabio Estevam #define CONFIG_GENERIC_MMC 51860b32eeSFabio Estevam #define CONFIG_CMD_FAT 52860b32eeSFabio Estevam #define CONFIG_DOS_PARTITION 53860b32eeSFabio Estevam 54860b32eeSFabio Estevam /* Eth Configs */ 55860b32eeSFabio Estevam #define CONFIG_HAS_ETH1 56860b32eeSFabio Estevam #define CONFIG_MII 57860b32eeSFabio Estevam 58860b32eeSFabio Estevam #define CONFIG_FEC_MXC 59860b32eeSFabio Estevam #define IMX_FEC_BASE FEC_BASE_ADDR 60860b32eeSFabio Estevam #define CONFIG_FEC_MXC_PHYADDR 0x1F 61860b32eeSFabio Estevam 62860b32eeSFabio Estevam #define CONFIG_CMD_PING 63860b32eeSFabio Estevam #define CONFIG_CMD_DHCP 64860b32eeSFabio Estevam #define CONFIG_CMD_MII 65860b32eeSFabio Estevam #define CONFIG_CMD_NET 66860b32eeSFabio Estevam 67860b32eeSFabio Estevam /* allow to overwrite serial and ethaddr */ 68860b32eeSFabio Estevam #define CONFIG_ENV_OVERWRITE 69860b32eeSFabio Estevam #define CONFIG_CONS_INDEX 1 70860b32eeSFabio Estevam #define CONFIG_BAUDRATE 115200 71860b32eeSFabio Estevam 72860b32eeSFabio Estevam /* Command definition */ 73860b32eeSFabio Estevam #include <config_cmd_default.h> 74860b32eeSFabio Estevam 75860b32eeSFabio Estevam #undef CONFIG_CMD_IMLS 76860b32eeSFabio Estevam 77860b32eeSFabio Estevam #define CONFIG_BOOTDELAY 3 78860b32eeSFabio Estevam 7928b119e9SWolfgang Grandegger #define CONFIG_ETHPRIME "FEC0" 80860b32eeSFabio Estevam 81860b32eeSFabio Estevam #define CONFIG_LOADADDR 0x70800000 /* loadaddr env var */ 82860b32eeSFabio Estevam #define CONFIG_SYS_TEXT_BASE 0x77800000 83860b32eeSFabio Estevam 84860b32eeSFabio Estevam #define CONFIG_EXTRA_ENV_SETTINGS \ 85860b32eeSFabio Estevam "script=boot.scr\0" \ 86860b32eeSFabio Estevam "uimage=uImage\0" \ 87860b32eeSFabio Estevam "mmcdev=0\0" \ 88860b32eeSFabio Estevam "mmcpart=2\0" \ 89860b32eeSFabio Estevam "mmcroot=/dev/mmcblk0p3 rw\0" \ 90860b32eeSFabio Estevam "mmcrootfstype=ext3 rootwait\0" \ 91860b32eeSFabio Estevam "mmcargs=setenv bootargs console=ttymxc0,${baudrate} " \ 92860b32eeSFabio Estevam "root=${mmcroot} " \ 93860b32eeSFabio Estevam "rootfstype=${mmcrootfstype}\0" \ 94860b32eeSFabio Estevam "loadbootscript=" \ 95860b32eeSFabio Estevam "fatload mmc ${mmcdev}:${mmcpart} ${loadaddr} ${script};\0" \ 96860b32eeSFabio Estevam "bootscript=echo Running bootscript from mmc ...; " \ 97860b32eeSFabio Estevam "source\0" \ 98860b32eeSFabio Estevam "loaduimage=fatload mmc ${mmcdev}:${mmcpart} ${loadaddr} ${uimage}\0" \ 99860b32eeSFabio Estevam "mmcboot=echo Booting from mmc ...; " \ 100860b32eeSFabio Estevam "run mmcargs; " \ 101860b32eeSFabio Estevam "bootm\0" \ 102860b32eeSFabio Estevam "netargs=setenv bootargs console=ttymxc0,${baudrate} " \ 103860b32eeSFabio Estevam "root=/dev/nfs " \ 104860b32eeSFabio Estevam "ip=dhcp nfsroot=${serverip}:${nfsroot},v3,tcp\0" \ 105860b32eeSFabio Estevam "netboot=echo Booting from net ...; " \ 106860b32eeSFabio Estevam "run netargs; " \ 107860b32eeSFabio Estevam "dhcp ${uimage}; bootm\0" \ 108860b32eeSFabio Estevam 109860b32eeSFabio Estevam #define CONFIG_BOOTCOMMAND \ 11066968110SAndrew Bradford "mmc dev ${mmcdev}; if mmc rescan; then " \ 111860b32eeSFabio Estevam "if run loadbootscript; then " \ 112860b32eeSFabio Estevam "run bootscript; " \ 113860b32eeSFabio Estevam "else " \ 114860b32eeSFabio Estevam "if run loaduimage; then " \ 115860b32eeSFabio Estevam "run mmcboot; " \ 116860b32eeSFabio Estevam "else run netboot; " \ 117860b32eeSFabio Estevam "fi; " \ 118860b32eeSFabio Estevam "fi; " \ 119860b32eeSFabio Estevam "else run netboot; fi" 120860b32eeSFabio Estevam #define CONFIG_ARP_TIMEOUT 200UL 121860b32eeSFabio Estevam 122860b32eeSFabio Estevam /* Miscellaneous configurable options */ 123860b32eeSFabio Estevam #define CONFIG_SYS_LONGHELP /* undef to save memory */ 124860b32eeSFabio Estevam #define CONFIG_SYS_HUSH_PARSER /* use "hush" command parser */ 125860b32eeSFabio Estevam #define CONFIG_AUTO_COMPLETE 126860b32eeSFabio Estevam #define CONFIG_SYS_CBSIZE 256 /* Console I/O Buffer Size */ 127860b32eeSFabio Estevam 128860b32eeSFabio Estevam /* Print Buffer Size */ 129860b32eeSFabio Estevam #define CONFIG_SYS_PBSIZE (CONFIG_SYS_CBSIZE + sizeof(CONFIG_SYS_PROMPT) + 16) 130860b32eeSFabio Estevam #define CONFIG_SYS_MAXARGS 16 /* max number of command args */ 131860b32eeSFabio Estevam #define CONFIG_SYS_BARGSIZE CONFIG_SYS_CBSIZE /* Boot Argument Buffer Size */ 132860b32eeSFabio Estevam 133860b32eeSFabio Estevam #define CONFIG_SYS_MEMTEST_START 0x70000000 134869aed7bSFabio Estevam #define CONFIG_SYS_MEMTEST_END 0x70010000 135860b32eeSFabio Estevam 136860b32eeSFabio Estevam #define CONFIG_SYS_LOAD_ADDR CONFIG_LOADADDR 137860b32eeSFabio Estevam 138860b32eeSFabio Estevam #define CONFIG_CMDLINE_EDITING 139860b32eeSFabio Estevam 140860b32eeSFabio Estevam /* Physical Memory Map */ 141860b32eeSFabio Estevam #define CONFIG_NR_DRAM_BANKS 2 142860b32eeSFabio Estevam #define PHYS_SDRAM_1 CSD0_BASE_ADDR 143860b32eeSFabio Estevam #define PHYS_SDRAM_1_SIZE (512 * 1024 * 1024) 144860b32eeSFabio Estevam #define PHYS_SDRAM_2 CSD1_BASE_ADDR 145860b32eeSFabio Estevam #define PHYS_SDRAM_2_SIZE (512 * 1024 * 1024) 146860b32eeSFabio Estevam #define PHYS_SDRAM_SIZE (PHYS_SDRAM_1_SIZE + PHYS_SDRAM_2_SIZE) 147860b32eeSFabio Estevam 148860b32eeSFabio Estevam #define CONFIG_SYS_SDRAM_BASE (PHYS_SDRAM_1) 149860b32eeSFabio Estevam #define CONFIG_SYS_INIT_RAM_ADDR (IRAM_BASE_ADDR) 150860b32eeSFabio Estevam #define CONFIG_SYS_INIT_RAM_SIZE (IRAM_SIZE) 151860b32eeSFabio Estevam 152860b32eeSFabio Estevam #define CONFIG_SYS_INIT_SP_OFFSET \ 153860b32eeSFabio Estevam (CONFIG_SYS_INIT_RAM_SIZE - GENERATED_GBL_DATA_SIZE) 154860b32eeSFabio Estevam #define CONFIG_SYS_INIT_SP_ADDR \ 155860b32eeSFabio Estevam (CONFIG_SYS_INIT_RAM_ADDR + CONFIG_SYS_INIT_SP_OFFSET) 156860b32eeSFabio Estevam 157860b32eeSFabio Estevam /* FLASH and environment organization */ 158860b32eeSFabio Estevam #define CONFIG_SYS_NO_FLASH 159860b32eeSFabio Estevam 160860b32eeSFabio Estevam #define CONFIG_ENV_OFFSET (6 * 64 * 1024) 161860b32eeSFabio Estevam #define CONFIG_ENV_SIZE (8 * 1024) 162860b32eeSFabio Estevam #define CONFIG_ENV_IS_IN_MMC 163860b32eeSFabio Estevam #define CONFIG_SYS_MMC_ENV_DEV 0 164860b32eeSFabio Estevam 165860b32eeSFabio Estevam #define CONFIG_OF_LIBFDT 166860b32eeSFabio Estevam 167860b32eeSFabio Estevam #endif /* __CONFIG_H */ 168