1c59e1b4dSTimur Tabi /* 23d7506faSramneek mehresh * Copyright 2010-2012 Freescale Semiconductor, Inc. 3c59e1b4dSTimur Tabi * Authors: Srikanth Srinivasan <srikanth.srinivasan@freescale.com> 4c59e1b4dSTimur Tabi * Timur Tabi <timur@freescale.com> 5c59e1b4dSTimur Tabi * 61a459660SWolfgang Denk * SPDX-License-Identifier: GPL-2.0+ 7c59e1b4dSTimur Tabi */ 8c59e1b4dSTimur Tabi 9c59e1b4dSTimur Tabi #ifndef __CONFIG_H 10c59e1b4dSTimur Tabi #define __CONFIG_H 11c59e1b4dSTimur Tabi 12c59e1b4dSTimur Tabi #include "../board/freescale/common/ics307_clk.h" 13c59e1b4dSTimur Tabi 149899ac19SJiang Yutang #ifdef CONFIG_36BIT 159899ac19SJiang Yutang #define CONFIG_PHYS_64BIT 169899ac19SJiang Yutang #endif 179899ac19SJiang Yutang 18af253608SMatthew McClintock #ifdef CONFIG_SDCARD 19*7c8eea59SYing Zhang #define CONFIG_SPL 20*7c8eea59SYing Zhang #define CONFIG_SPL_MPC8XXX_INIT_DDR_SUPPORT 21*7c8eea59SYing Zhang #define CONFIG_SPL_ENV_SUPPORT 22*7c8eea59SYing Zhang #define CONFIG_SPL_SERIAL_SUPPORT 23*7c8eea59SYing Zhang #define CONFIG_SPL_MMC_SUPPORT 24*7c8eea59SYing Zhang #define CONFIG_SPL_MMC_MINIMAL 25*7c8eea59SYing Zhang #define CONFIG_SPL_FLUSH_IMAGE 26*7c8eea59SYing Zhang #define CONFIG_SPL_TARGET "u-boot-with-spl.bin" 27*7c8eea59SYing Zhang #define CONFIG_SPL_LIBGENERIC_SUPPORT 28*7c8eea59SYing Zhang #define CONFIG_SPL_LIBCOMMON_SUPPORT 29*7c8eea59SYing Zhang #define CONFIG_SPL_I2C_SUPPORT 30*7c8eea59SYing Zhang #define CONFIG_FSL_LAW /* Use common FSL init code */ 31*7c8eea59SYing Zhang #define CONFIG_SYS_TEXT_BASE 0x11001000 32*7c8eea59SYing Zhang #define CONFIG_SPL_TEXT_BASE 0xf8f81000 33*7c8eea59SYing Zhang #define CONFIG_SPL_PAD_TO 0x18000 34*7c8eea59SYing Zhang #define CONFIG_SPL_MAX_SIZE (96 * 1024) 35*7c8eea59SYing Zhang #define CONFIG_SYS_MMC_U_BOOT_SIZE (512 << 10) 36*7c8eea59SYing Zhang #define CONFIG_SYS_MMC_U_BOOT_DST (0x11000000) 37*7c8eea59SYing Zhang #define CONFIG_SYS_MMC_U_BOOT_START (0x11000000) 38*7c8eea59SYing Zhang #define CONFIG_SYS_MMC_U_BOOT_OFFS (96 << 10) 39*7c8eea59SYing Zhang #define CONFIG_SYS_MPC85XX_NO_RESETVEC 40*7c8eea59SYing Zhang #define CONFIG_SYS_LDSCRIPT "arch/powerpc/cpu/mpc85xx/u-boot.lds" 41*7c8eea59SYing Zhang #define CONFIG_SPL_MMC_BOOT 42*7c8eea59SYing Zhang #ifdef CONFIG_SPL_BUILD 43*7c8eea59SYing Zhang #define CONFIG_SPL_COMMON_INIT_DDR 44*7c8eea59SYing Zhang #endif 45af253608SMatthew McClintock #endif 46af253608SMatthew McClintock 47af253608SMatthew McClintock #ifdef CONFIG_SPIFLASH 48af253608SMatthew McClintock #define CONFIG_RAMBOOT_SPIFLASH 49af253608SMatthew McClintock #define CONFIG_SYS_RAMBOOT 50af253608SMatthew McClintock #define CONFIG_SYS_EXTRA_ENV_RELOC 51af253608SMatthew McClintock #define CONFIG_SYS_TEXT_BASE 0x11000000 52af253608SMatthew McClintock #define CONFIG_RESET_VECTOR_ADDRESS 0x1107fffc 53af253608SMatthew McClintock #endif 54af253608SMatthew McClintock 55f45210d6SMatthew McClintock #define CONFIG_NAND_FSL_ELBC 56f45210d6SMatthew McClintock 57f45210d6SMatthew McClintock #ifdef CONFIG_NAND 58f45210d6SMatthew McClintock #define CONFIG_SPL 59f45210d6SMatthew McClintock #define CONFIG_SPL_INIT_MINIMAL 60f45210d6SMatthew McClintock #define CONFIG_SPL_SERIAL_SUPPORT 61f45210d6SMatthew McClintock #define CONFIG_SPL_NAND_SUPPORT 62f45210d6SMatthew McClintock #define CONFIG_SPL_FLUSH_IMAGE 63f45210d6SMatthew McClintock #define CONFIG_SPL_TARGET "u-boot-with-spl.bin" 64f45210d6SMatthew McClintock 65f45210d6SMatthew McClintock #define CONFIG_SYS_TEXT_BASE 0x00201000 66f45210d6SMatthew McClintock #define CONFIG_SPL_TEXT_BASE 0xfffff000 675ed6f447STom Rini #define CONFIG_SPL_MAX_SIZE 4096 68f45210d6SMatthew McClintock #define CONFIG_SPL_RELOC_TEXT_BASE 0x00100000 69f45210d6SMatthew McClintock #define CONFIG_SPL_RELOC_STACK 0x00100000 70f45210d6SMatthew McClintock #define CONFIG_SYS_NAND_U_BOOT_SIZE ((512 << 10) + CONFIG_SPL_MAX_SIZE) 71f45210d6SMatthew McClintock #define CONFIG_SYS_NAND_U_BOOT_DST (0x00200000 - CONFIG_SPL_MAX_SIZE) 72f45210d6SMatthew McClintock #define CONFIG_SYS_NAND_U_BOOT_START 0x00200000 73f45210d6SMatthew McClintock #define CONFIG_SYS_NAND_U_BOOT_OFFS 0 74f45210d6SMatthew McClintock #define CONFIG_SYS_LDSCRIPT "arch/powerpc/cpu/mpc85xx/u-boot-nand.lds" 75f45210d6SMatthew McClintock #endif 76f45210d6SMatthew McClintock 77c59e1b4dSTimur Tabi /* High Level Configuration Options */ 78c59e1b4dSTimur Tabi #define CONFIG_BOOKE /* BOOKE */ 79c59e1b4dSTimur Tabi #define CONFIG_E500 /* BOOKE e500 family */ 80c59e1b4dSTimur Tabi #define CONFIG_MPC85xx /* MPC8540/60/55/41/48 */ 81c59e1b4dSTimur Tabi #define CONFIG_P1022 82c59e1b4dSTimur Tabi #define CONFIG_P1022DS 83c59e1b4dSTimur Tabi #define CONFIG_MP /* support multiple processors */ 84c59e1b4dSTimur Tabi 852ae18241SWolfgang Denk #ifndef CONFIG_SYS_TEXT_BASE 862ae18241SWolfgang Denk #define CONFIG_SYS_TEXT_BASE 0xeff80000 872ae18241SWolfgang Denk #endif 882ae18241SWolfgang Denk 897a577fdaSKumar Gala #ifndef CONFIG_RESET_VECTOR_ADDRESS 907a577fdaSKumar Gala #define CONFIG_RESET_VECTOR_ADDRESS 0xeffffffc 917a577fdaSKumar Gala #endif 927a577fdaSKumar Gala 93c59e1b4dSTimur Tabi #define CONFIG_FSL_ELBC /* Has Enhanced localbus controller */ 94c59e1b4dSTimur Tabi #define CONFIG_PCI /* Enable PCI/PCIE */ 95c59e1b4dSTimur Tabi #define CONFIG_PCIE1 /* PCIE controler 1 (slot 1) */ 96c59e1b4dSTimur Tabi #define CONFIG_PCIE2 /* PCIE controler 2 (slot 2) */ 97c59e1b4dSTimur Tabi #define CONFIG_PCIE3 /* PCIE controler 3 (ULI bridge) */ 98c59e1b4dSTimur Tabi #define CONFIG_FSL_PCI_INIT /* Use common FSL init code */ 99c59e1b4dSTimur Tabi #define CONFIG_FSL_PCIE_RESET /* need PCIe reset errata */ 100c59e1b4dSTimur Tabi #define CONFIG_SYS_PCI_64BIT /* enable 64-bit PCI resources */ 101c59e1b4dSTimur Tabi 102c59e1b4dSTimur Tabi #define CONFIG_ENABLE_36BIT_PHYS 103babb348cSTimur Tabi 104babb348cSTimur Tabi #ifdef CONFIG_PHYS_64BIT 105c59e1b4dSTimur Tabi #define CONFIG_ADDR_MAP 106c59e1b4dSTimur Tabi #define CONFIG_SYS_NUM_ADDR_MAP 16 /* number of TLB1 entries */ 1079899ac19SJiang Yutang #endif 108c59e1b4dSTimur Tabi 109c59e1b4dSTimur Tabi #define CONFIG_FSL_LAW /* Use common FSL init code */ 110c59e1b4dSTimur Tabi 111c59e1b4dSTimur Tabi #define CONFIG_SYS_CLK_FREQ get_board_sys_clk() 112c59e1b4dSTimur Tabi #define CONFIG_DDR_CLK_FREQ get_board_ddr_clk() 113c59e1b4dSTimur Tabi #define CONFIG_ICS307_REFCLK_HZ 33333000 /* ICS307 clock chip ref freq */ 114c59e1b4dSTimur Tabi 115c59e1b4dSTimur Tabi /* 116c59e1b4dSTimur Tabi * These can be toggled for performance analysis, otherwise use default. 117c59e1b4dSTimur Tabi */ 118c59e1b4dSTimur Tabi #define CONFIG_L2_CACHE 119c59e1b4dSTimur Tabi #define CONFIG_BTB 120c59e1b4dSTimur Tabi 121c59e1b4dSTimur Tabi #define CONFIG_SYS_MEMTEST_START 0x00000000 122c59e1b4dSTimur Tabi #define CONFIG_SYS_MEMTEST_END 0x7fffffff 123c59e1b4dSTimur Tabi 124e46fedfeSTimur Tabi #define CONFIG_SYS_CCSRBAR 0xffe00000 125e46fedfeSTimur Tabi #define CONFIG_SYS_CCSRBAR_PHYS_LOW CONFIG_SYS_CCSRBAR 126c59e1b4dSTimur Tabi 127f45210d6SMatthew McClintock /* IN case of NAND bootloader relocate CCSRBAR in RAMboot code not in the 4k 128f45210d6SMatthew McClintock SPL code*/ 129f45210d6SMatthew McClintock #ifdef CONFIG_SPL_BUILD 130f45210d6SMatthew McClintock #define CONFIG_SYS_CCSR_DO_NOT_RELOCATE 131f45210d6SMatthew McClintock #endif 132f45210d6SMatthew McClintock 133f45210d6SMatthew McClintock 134c59e1b4dSTimur Tabi /* DDR Setup */ 135c59e1b4dSTimur Tabi #define CONFIG_DDR_SPD 136c59e1b4dSTimur Tabi #define CONFIG_VERY_BIG_RAM 137c59e1b4dSTimur Tabi #define CONFIG_FSL_DDR3 138c59e1b4dSTimur Tabi 139c59e1b4dSTimur Tabi #ifdef CONFIG_DDR_ECC 140c59e1b4dSTimur Tabi #define CONFIG_ECC_INIT_VIA_DDRCONTROLLER 141c59e1b4dSTimur Tabi #define CONFIG_MEM_INIT_VALUE 0xdeadbeef 142c59e1b4dSTimur Tabi #endif 143c59e1b4dSTimur Tabi 144c59e1b4dSTimur Tabi #define CONFIG_SYS_DDR_SDRAM_BASE 0x00000000 145c59e1b4dSTimur Tabi #define CONFIG_SYS_SDRAM_BASE CONFIG_SYS_DDR_SDRAM_BASE 146c59e1b4dSTimur Tabi 147c59e1b4dSTimur Tabi #define CONFIG_NUM_DDR_CONTROLLERS 1 148c59e1b4dSTimur Tabi #define CONFIG_DIMM_SLOTS_PER_CTLR 1 149c59e1b4dSTimur Tabi #define CONFIG_CHIP_SELECTS_PER_CTRL (2 * CONFIG_DIMM_SLOTS_PER_CTLR) 150c59e1b4dSTimur Tabi 151c59e1b4dSTimur Tabi /* I2C addresses of SPD EEPROMs */ 152c59e1b4dSTimur Tabi #define CONFIG_SYS_SPD_BUS_NUM 1 153c39f44dcSKumar Gala #define SPD_EEPROM_ADDRESS 0x51 /* CTLR 0 DIMM 0 */ 154c59e1b4dSTimur Tabi 155f45210d6SMatthew McClintock /* These are used when DDR doesn't use SPD. */ 156f45210d6SMatthew McClintock #define CONFIG_SYS_SDRAM_SIZE 2048 157f45210d6SMatthew McClintock #define CONFIG_SYS_SDRAM_SIZE_LAW LAW_SIZE_2G 158f45210d6SMatthew McClintock #define CONFIG_SYS_DDR_CS0_BNDS 0x0000003F 159f45210d6SMatthew McClintock #define CONFIG_SYS_DDR_CS0_CONFIG 0x80014202 160f45210d6SMatthew McClintock #define CONFIG_SYS_DDR_CS1_BNDS 0x0040007F 161f45210d6SMatthew McClintock #define CONFIG_SYS_DDR_CS1_CONFIG 0x80014202 162f45210d6SMatthew McClintock #define CONFIG_SYS_DDR_TIMING_3 0x00010000 163f45210d6SMatthew McClintock #define CONFIG_SYS_DDR_TIMING_0 0x40110104 164f45210d6SMatthew McClintock #define CONFIG_SYS_DDR_TIMING_1 0x5c5bd746 165f45210d6SMatthew McClintock #define CONFIG_SYS_DDR_TIMING_2 0x0fa8d4ca 166f45210d6SMatthew McClintock #define CONFIG_SYS_DDR_MODE_1 0x00441221 167f45210d6SMatthew McClintock #define CONFIG_SYS_DDR_MODE_2 0x00000000 168f45210d6SMatthew McClintock #define CONFIG_SYS_DDR_INTERVAL 0x0a280100 169f45210d6SMatthew McClintock #define CONFIG_SYS_DDR_DATA_INIT 0xdeadbeef 170f45210d6SMatthew McClintock #define CONFIG_SYS_DDR_CLK_CTRL 0x02800000 171f45210d6SMatthew McClintock #define CONFIG_SYS_DDR_CONTROL 0xc7000008 172f45210d6SMatthew McClintock #define CONFIG_SYS_DDR_CONTROL_2 0x24401041 173f45210d6SMatthew McClintock #define CONFIG_SYS_DDR_TIMING_4 0x00220001 174f45210d6SMatthew McClintock #define CONFIG_SYS_DDR_TIMING_5 0x02401400 175f45210d6SMatthew McClintock #define CONFIG_SYS_DDR_ZQ_CONTROL 0x89080600 176f45210d6SMatthew McClintock #define CONFIG_SYS_DDR_WRLVL_CONTROL 0x8675f608 177f45210d6SMatthew McClintock 178f45210d6SMatthew McClintock 179c59e1b4dSTimur Tabi /* 180c59e1b4dSTimur Tabi * Memory map 181c59e1b4dSTimur Tabi * 182c59e1b4dSTimur Tabi * 0x0000_0000 0x7fff_ffff DDR 2G Cacheable 183c59e1b4dSTimur Tabi * 0x8000_0000 0xdfff_ffff PCI Express Mem 1.5G non-cacheable 184c59e1b4dSTimur Tabi * 0xffc0_0000 0xffc2_ffff PCI IO range 192K non-cacheable 185c59e1b4dSTimur Tabi * 186c59e1b4dSTimur Tabi * Localbus cacheable (TBD) 187c59e1b4dSTimur Tabi * 0xXXXX_XXXX 0xXXXX_XXXX SRAM YZ M Cacheable 188c59e1b4dSTimur Tabi * 189c59e1b4dSTimur Tabi * Localbus non-cacheable 190c59e1b4dSTimur Tabi * 0xe000_0000 0xe80f_ffff Promjet/free 128M non-cacheable 191c59e1b4dSTimur Tabi * 0xe800_0000 0xefff_ffff FLASH 128M non-cacheable 192f45210d6SMatthew McClintock * 0xff80_0000 0xff80_7fff NAND 32K non-cacheable 193c59e1b4dSTimur Tabi * 0xffdf_0000 0xffdf_7fff PIXIS 32K non-cacheable TLB0 194c59e1b4dSTimur Tabi * 0xffd0_0000 0xffd0_3fff L1 for stack 16K Cacheable TLB0 195c59e1b4dSTimur Tabi * 0xffe0_0000 0xffef_ffff CCSR 1M non-cacheable 196c59e1b4dSTimur Tabi */ 197c59e1b4dSTimur Tabi 198c59e1b4dSTimur Tabi /* 199c59e1b4dSTimur Tabi * Local Bus Definitions 200c59e1b4dSTimur Tabi */ 201f45210d6SMatthew McClintock #define CONFIG_SYS_FLASH_BASE 0xe8000000 /* start of FLASH 128M */ 2029899ac19SJiang Yutang #ifdef CONFIG_PHYS_64BIT 203f45210d6SMatthew McClintock #define CONFIG_SYS_FLASH_BASE_PHYS 0xfe8000000ull 2049899ac19SJiang Yutang #else 2059899ac19SJiang Yutang #define CONFIG_SYS_FLASH_BASE_PHYS CONFIG_SYS_FLASH_BASE 2069899ac19SJiang Yutang #endif 207c59e1b4dSTimur Tabi 208c59e1b4dSTimur Tabi #define CONFIG_FLASH_BR_PRELIM \ 209f45210d6SMatthew McClintock (BR_PHYS_ADDR(CONFIG_SYS_FLASH_BASE_PHYS) | BR_PS_16 | BR_V) 210c59e1b4dSTimur Tabi #define CONFIG_FLASH_OR_PRELIM (OR_AM_128MB | 0xff7) 211c59e1b4dSTimur Tabi 212f45210d6SMatthew McClintock #ifdef CONFIG_NAND 213f45210d6SMatthew McClintock #define CONFIG_SYS_BR1_PRELIM CONFIG_FLASH_BR_PRELIM /* NOR Base Address */ 214f45210d6SMatthew McClintock #define CONFIG_SYS_OR1_PRELIM CONFIG_FLASH_OR_PRELIM /* NOR Options */ 215f45210d6SMatthew McClintock #else 216c59e1b4dSTimur Tabi #define CONFIG_SYS_BR0_PRELIM CONFIG_FLASH_BR_PRELIM /* NOR Base Address */ 217c59e1b4dSTimur Tabi #define CONFIG_SYS_OR0_PRELIM CONFIG_FLASH_OR_PRELIM /* NOR Options */ 218f45210d6SMatthew McClintock #endif 219c59e1b4dSTimur Tabi 220f45210d6SMatthew McClintock #define CONFIG_SYS_FLASH_BANKS_LIST {CONFIG_SYS_FLASH_BASE_PHYS} 221c59e1b4dSTimur Tabi #define CONFIG_SYS_FLASH_QUIET_TEST 222c59e1b4dSTimur Tabi #define CONFIG_FLASH_SHOW_PROGRESS 45 /* count down from 45/5: 9..1 */ 223c59e1b4dSTimur Tabi 224f45210d6SMatthew McClintock #define CONFIG_SYS_MAX_FLASH_BANKS 1 225c59e1b4dSTimur Tabi #define CONFIG_SYS_MAX_FLASH_SECT 1024 226c59e1b4dSTimur Tabi 227f45210d6SMatthew McClintock #ifndef CONFIG_SYS_MONITOR_BASE 228f45210d6SMatthew McClintock #ifdef CONFIG_SPL_BUILD 229f45210d6SMatthew McClintock #define CONFIG_SYS_MONITOR_BASE CONFIG_SPL_TEXT_BASE 230f45210d6SMatthew McClintock #else 23114d0a02aSWolfgang Denk #define CONFIG_SYS_MONITOR_BASE CONFIG_SYS_TEXT_BASE /* start of monitor */ 232f45210d6SMatthew McClintock #endif 233f45210d6SMatthew McClintock #endif 234c59e1b4dSTimur Tabi 235c59e1b4dSTimur Tabi #define CONFIG_FLASH_CFI_DRIVER 236c59e1b4dSTimur Tabi #define CONFIG_SYS_FLASH_CFI 237c59e1b4dSTimur Tabi #define CONFIG_SYS_FLASH_EMPTY_INFO 238c59e1b4dSTimur Tabi 239f45210d6SMatthew McClintock /* Nand Flash */ 240f45210d6SMatthew McClintock #if defined(CONFIG_NAND_FSL_ELBC) 241f45210d6SMatthew McClintock #define CONFIG_SYS_NAND_BASE 0xff800000 242f45210d6SMatthew McClintock #ifdef CONFIG_PHYS_64BIT 243f45210d6SMatthew McClintock #define CONFIG_SYS_NAND_BASE_PHYS 0xfff800000ull 244f45210d6SMatthew McClintock #else 245f45210d6SMatthew McClintock #define CONFIG_SYS_NAND_BASE_PHYS CONFIG_SYS_NAND_BASE 246f45210d6SMatthew McClintock #endif 247f45210d6SMatthew McClintock 248f45210d6SMatthew McClintock #define CONFIG_SYS_NAND_BASE_LIST { CONFIG_SYS_NAND_BASE, } 249f45210d6SMatthew McClintock #define CONFIG_SYS_MAX_NAND_DEVICE 1 250f45210d6SMatthew McClintock #define CONFIG_MTD_NAND_VERIFY_WRITE 251f45210d6SMatthew McClintock #define CONFIG_CMD_NAND 1 252f45210d6SMatthew McClintock #define CONFIG_SYS_NAND_BLOCK_SIZE (256 * 1024) 253f45210d6SMatthew McClintock #define CONFIG_ELBC_NAND_SPL_STATIC_PGSIZE 254f45210d6SMatthew McClintock 255f45210d6SMatthew McClintock /* NAND flash config */ 256f45210d6SMatthew McClintock #define CONFIG_SYS_NAND_BR_PRELIM (BR_PHYS_ADDR(CONFIG_SYS_NAND_BASE_PHYS) \ 257f45210d6SMatthew McClintock | (2<<BR_DECC_SHIFT) /* Use HW ECC */ \ 258f45210d6SMatthew McClintock | BR_PS_8 /* Port Size = 8 bit */ \ 259f45210d6SMatthew McClintock | BR_MS_FCM /* MSEL = FCM */ \ 260f45210d6SMatthew McClintock | BR_V) /* valid */ 261f45210d6SMatthew McClintock #define CONFIG_SYS_NAND_OR_PRELIM (OR_AM_32KB /* length 256K */ \ 262f45210d6SMatthew McClintock | OR_FCM_PGS /* Large Page*/ \ 263f45210d6SMatthew McClintock | OR_FCM_CSCT \ 264f45210d6SMatthew McClintock | OR_FCM_CST \ 265f45210d6SMatthew McClintock | OR_FCM_CHT \ 266f45210d6SMatthew McClintock | OR_FCM_SCY_1 \ 267f45210d6SMatthew McClintock | OR_FCM_TRLX \ 268f45210d6SMatthew McClintock | OR_FCM_EHTR) 269f45210d6SMatthew McClintock #ifdef CONFIG_NAND 270f45210d6SMatthew McClintock #define CONFIG_SYS_BR0_PRELIM CONFIG_SYS_NAND_BR_PRELIM /* NAND Base Address */ 271f45210d6SMatthew McClintock #define CONFIG_SYS_OR0_PRELIM CONFIG_SYS_NAND_OR_PRELIM /* NAND Options */ 272f45210d6SMatthew McClintock #else 273f45210d6SMatthew McClintock #define CONFIG_SYS_BR1_PRELIM CONFIG_SYS_NAND_BR_PRELIM /* NAND Base Address */ 274f45210d6SMatthew McClintock #define CONFIG_SYS_OR1_PRELIM CONFIG_SYS_NAND_OR_PRELIM /* NAND Options */ 275f45210d6SMatthew McClintock #endif 276f45210d6SMatthew McClintock 277f45210d6SMatthew McClintock #endif /* CONFIG_NAND_FSL_ELBC */ 278f45210d6SMatthew McClintock 279c59e1b4dSTimur Tabi #define CONFIG_BOARD_EARLY_INIT_F 280c59e1b4dSTimur Tabi #define CONFIG_BOARD_EARLY_INIT_R 281c59e1b4dSTimur Tabi #define CONFIG_MISC_INIT_R 282a2d12f88STimur Tabi #define CONFIG_HWCONFIG 283c59e1b4dSTimur Tabi 284c59e1b4dSTimur Tabi #define CONFIG_FSL_NGPIXIS 285c59e1b4dSTimur Tabi #define PIXIS_BASE 0xffdf0000 /* PIXIS registers */ 2869899ac19SJiang Yutang #ifdef CONFIG_PHYS_64BIT 287c59e1b4dSTimur Tabi #define PIXIS_BASE_PHYS 0xfffdf0000ull 2889899ac19SJiang Yutang #else 2899899ac19SJiang Yutang #define PIXIS_BASE_PHYS PIXIS_BASE 2909899ac19SJiang Yutang #endif 291c59e1b4dSTimur Tabi 292c59e1b4dSTimur Tabi #define CONFIG_SYS_BR2_PRELIM (BR_PHYS_ADDR(PIXIS_BASE_PHYS) | BR_PS_8 | BR_V) 293c59e1b4dSTimur Tabi #define CONFIG_SYS_OR2_PRELIM (OR_AM_32KB | 0x6ff7) 294c59e1b4dSTimur Tabi 295c59e1b4dSTimur Tabi #define PIXIS_LBMAP_SWITCH 7 2962906845aSYork Sun #define PIXIS_LBMAP_MASK 0xF0 297c59e1b4dSTimur Tabi #define PIXIS_LBMAP_ALTBANK 0x20 298f45210d6SMatthew McClintock #define PIXIS_SPD 0x07 299f45210d6SMatthew McClintock #define PIXIS_SPD_SYSCLK_MASK 0x07 3009b6e9d1cSJiang Yutang #define PIXIS_ELBC_SPI_MASK 0xc0 3019b6e9d1cSJiang Yutang #define PIXIS_SPI 0x80 302c59e1b4dSTimur Tabi 303c59e1b4dSTimur Tabi #define CONFIG_SYS_INIT_RAM_LOCK 304c59e1b4dSTimur Tabi #define CONFIG_SYS_INIT_RAM_ADDR 0xffd00000 /* Initial L1 address */ 305553f0982SWolfgang Denk #define CONFIG_SYS_INIT_RAM_SIZE 0x00004000 /* Size of used area in RAM */ 306c59e1b4dSTimur Tabi 307c59e1b4dSTimur Tabi #define CONFIG_SYS_GBL_DATA_OFFSET \ 30825ddd1fbSWolfgang Denk (CONFIG_SYS_INIT_RAM_SIZE - GENERATED_GBL_DATA_SIZE) 309c59e1b4dSTimur Tabi #define CONFIG_SYS_INIT_SP_OFFSET CONFIG_SYS_GBL_DATA_OFFSET 310c59e1b4dSTimur Tabi 311c59e1b4dSTimur Tabi #define CONFIG_SYS_MONITOR_LEN (512 * 1024) 31207b5edc2SJerry Huang #define CONFIG_SYS_MALLOC_LEN (10 * 1024 * 1024) 313c59e1b4dSTimur Tabi 314c59e1b4dSTimur Tabi /* 315*7c8eea59SYing Zhang * Config the L2 Cache as L2 SRAM 316*7c8eea59SYing Zhang */ 317*7c8eea59SYing Zhang #if defined(CONFIG_SPL_BUILD) 318*7c8eea59SYing Zhang #if defined(CONFIG_SDCARD) 319*7c8eea59SYing Zhang #define CONFIG_SYS_INIT_L2_ADDR 0xf8f80000 320*7c8eea59SYing Zhang #define CONFIG_SYS_INIT_L2_ADDR_PHYS CONFIG_SYS_INIT_L2_ADDR 321*7c8eea59SYing Zhang #define CONFIG_SYS_L2_SIZE (256 << 10) 322*7c8eea59SYing Zhang #define CONFIG_SYS_INIT_L2_END (CONFIG_SYS_INIT_L2_ADDR + CONFIG_SYS_L2_SIZE) 323*7c8eea59SYing Zhang #define CONFIG_SPL_RELOC_TEXT_BASE 0xf8f81000 324*7c8eea59SYing Zhang #define CONFIG_SPL_RELOC_STACK (CONFIG_SYS_INIT_L2_ADDR + 128 * 1024) 325*7c8eea59SYing Zhang #define CONFIG_SPL_RELOC_STACK_SIZE (32 << 10) 326*7c8eea59SYing Zhang #define CONFIG_SPL_RELOC_MALLOC_ADDR (CONFIG_SYS_INIT_L2_ADDR + 160 * 1024) 327*7c8eea59SYing Zhang #define CONFIG_SPL_RELOC_MALLOC_SIZE (96 << 10) 328*7c8eea59SYing Zhang #define CONFIG_SPL_GD_ADDR (CONFIG_SYS_INIT_L2_ADDR + 112 * 1024) 329*7c8eea59SYing Zhang #endif 330*7c8eea59SYing Zhang #endif 331*7c8eea59SYing Zhang 332*7c8eea59SYing Zhang /* 333c59e1b4dSTimur Tabi * Serial Port 334c59e1b4dSTimur Tabi */ 335c59e1b4dSTimur Tabi #define CONFIG_CONS_INDEX 1 336c59e1b4dSTimur Tabi #define CONFIG_SYS_NS16550 337c59e1b4dSTimur Tabi #define CONFIG_SYS_NS16550_SERIAL 338c59e1b4dSTimur Tabi #define CONFIG_SYS_NS16550_REG_SIZE 1 339c59e1b4dSTimur Tabi #define CONFIG_SYS_NS16550_CLK get_bus_freq(0) 340*7c8eea59SYing Zhang #if defined(CONFIG_SPL_BUILD) && defined(CONFIG_SPL_INIT_MINIMAL) 341f45210d6SMatthew McClintock #define CONFIG_NS16550_MIN_FUNCTIONS 342f45210d6SMatthew McClintock #endif 343c59e1b4dSTimur Tabi 344c59e1b4dSTimur Tabi #define CONFIG_SYS_BAUDRATE_TABLE \ 345c59e1b4dSTimur Tabi {300, 600, 1200, 2400, 4800, 9600, 19200, 38400, 57600, 115200} 346c59e1b4dSTimur Tabi 347c59e1b4dSTimur Tabi #define CONFIG_SYS_NS16550_COM1 (CONFIG_SYS_CCSRBAR+0x4500) 348c59e1b4dSTimur Tabi #define CONFIG_SYS_NS16550_COM2 (CONFIG_SYS_CCSRBAR+0x4600) 349c59e1b4dSTimur Tabi 350c59e1b4dSTimur Tabi /* Use the HUSH parser */ 351c59e1b4dSTimur Tabi #define CONFIG_SYS_HUSH_PARSER 352c59e1b4dSTimur Tabi 353c59e1b4dSTimur Tabi /* Video */ 354ba8e76bdSTimur Tabi 355d5e01e49STimur Tabi #ifdef CONFIG_FSL_DIU_FB 356d5e01e49STimur Tabi #define CONFIG_SYS_DIU_ADDR (CONFIG_SYS_CCSRBAR + 0x10000) 357d5e01e49STimur Tabi #define CONFIG_VIDEO 358d5e01e49STimur Tabi #define CONFIG_CMD_BMP 359c59e1b4dSTimur Tabi #define CONFIG_CFB_CONSOLE 3607d3053fbSTimur Tabi #define CONFIG_VIDEO_SW_CURSOR 361c59e1b4dSTimur Tabi #define CONFIG_VGA_AS_SINGLE_DEVICE 362d5e01e49STimur Tabi #define CONFIG_VIDEO_LOGO 363d5e01e49STimur Tabi #define CONFIG_VIDEO_BMP_LOGO 36455b05237STimur Tabi #define CONFIG_CFI_FLASH_USE_WEAK_ACCESSORS 36555b05237STimur Tabi /* 36655b05237STimur Tabi * With CONFIG_CFI_FLASH_USE_WEAK_ACCESSORS, flash I/O is really slow, so 36755b05237STimur Tabi * disable empty flash sector detection, which is I/O-intensive. 36855b05237STimur Tabi */ 36955b05237STimur Tabi #undef CONFIG_SYS_FLASH_EMPTY_INFO 370c59e1b4dSTimur Tabi #endif 371c59e1b4dSTimur Tabi 372ba8e76bdSTimur Tabi #ifndef CONFIG_FSL_DIU_FB 373218a758fSJiang Yutang #endif 374218a758fSJiang Yutang 375218a758fSJiang Yutang #ifdef CONFIG_ATI 376218a758fSJiang Yutang #define VIDEO_IO_OFFSET CONFIG_SYS_PCIE1_IO_VIRT 377218a758fSJiang Yutang #define CONFIG_VIDEO 378218a758fSJiang Yutang #define CONFIG_BIOSEMU 379218a758fSJiang Yutang #define CONFIG_VIDEO_SW_CURSOR 380218a758fSJiang Yutang #define CONFIG_ATI_RADEON_FB 381218a758fSJiang Yutang #define CONFIG_VIDEO_LOGO 382218a758fSJiang Yutang #define CONFIG_SYS_ISA_IO_BASE_ADDRESS VIDEO_IO_OFFSET 383218a758fSJiang Yutang #define CONFIG_CFB_CONSOLE 384218a758fSJiang Yutang #define CONFIG_VGA_AS_SINGLE_DEVICE 385218a758fSJiang Yutang #endif 386218a758fSJiang Yutang 387c59e1b4dSTimur Tabi /* 388c59e1b4dSTimur Tabi * Pass open firmware flat tree 389c59e1b4dSTimur Tabi */ 390c59e1b4dSTimur Tabi #define CONFIG_OF_LIBFDT 391c59e1b4dSTimur Tabi #define CONFIG_OF_BOARD_SETUP 392c59e1b4dSTimur Tabi #define CONFIG_OF_STDOUT_VIA_ALIAS 393c59e1b4dSTimur Tabi 394c59e1b4dSTimur Tabi /* new uImage format support */ 395c59e1b4dSTimur Tabi #define CONFIG_FIT 396c59e1b4dSTimur Tabi #define CONFIG_FIT_VERBOSE 397c59e1b4dSTimur Tabi 398c59e1b4dSTimur Tabi /* I2C */ 39900f792e0SHeiko Schocher #define CONFIG_SYS_I2C 40000f792e0SHeiko Schocher #define CONFIG_SYS_I2C_FSL 40100f792e0SHeiko Schocher #define CONFIG_SYS_FSL_I2C_SPEED 400000 40200f792e0SHeiko Schocher #define CONFIG_SYS_FSL_I2C_SLAVE 0x7F 40300f792e0SHeiko Schocher #define CONFIG_SYS_FSL_I2C_OFFSET 0x3000 40400f792e0SHeiko Schocher #define CONFIG_SYS_FSL_I2C2_SPEED 400000 40500f792e0SHeiko Schocher #define CONFIG_SYS_FSL_I2C2_SLAVE 0x7F 40600f792e0SHeiko Schocher #define CONFIG_SYS_FSL_I2C2_OFFSET 0x3100 407c59e1b4dSTimur Tabi #define CONFIG_SYS_I2C_NOPROBES {{0, 0x29}} 408c59e1b4dSTimur Tabi 409c59e1b4dSTimur Tabi /* 410c59e1b4dSTimur Tabi * I2C2 EEPROM 411c59e1b4dSTimur Tabi */ 412c59e1b4dSTimur Tabi #define CONFIG_ID_EEPROM 413c59e1b4dSTimur Tabi #define CONFIG_SYS_I2C_EEPROM_NXID 414c59e1b4dSTimur Tabi #define CONFIG_SYS_I2C_EEPROM_ADDR 0x57 415c59e1b4dSTimur Tabi #define CONFIG_SYS_I2C_EEPROM_ADDR_LEN 1 416c59e1b4dSTimur Tabi #define CONFIG_SYS_EEPROM_BUS_NUM 1 417c59e1b4dSTimur Tabi 418c59e1b4dSTimur Tabi /* 4199b6e9d1cSJiang Yutang * eSPI - Enhanced SPI 4209b6e9d1cSJiang Yutang */ 4219b6e9d1cSJiang Yutang #define CONFIG_SPI_FLASH 4229b6e9d1cSJiang Yutang #define CONFIG_SPI_FLASH_SPANSION 4239b6e9d1cSJiang Yutang 4249b6e9d1cSJiang Yutang #define CONFIG_HARD_SPI 4259b6e9d1cSJiang Yutang #define CONFIG_FSL_ESPI 4269b6e9d1cSJiang Yutang 4279b6e9d1cSJiang Yutang #define CONFIG_CMD_SF 4289b6e9d1cSJiang Yutang #define CONFIG_SF_DEFAULT_SPEED 10000000 4299b6e9d1cSJiang Yutang #define CONFIG_SF_DEFAULT_MODE 0 4309b6e9d1cSJiang Yutang 4319b6e9d1cSJiang Yutang /* 432c59e1b4dSTimur Tabi * General PCI 433c59e1b4dSTimur Tabi * Memory space is mapped 1-1, but I/O space must start from 0. 434c59e1b4dSTimur Tabi */ 435c59e1b4dSTimur Tabi 436c59e1b4dSTimur Tabi /* controller 1, Slot 2, tgtid 1, Base address a000 */ 437c59e1b4dSTimur Tabi #define CONFIG_SYS_PCIE1_MEM_VIRT 0xc0000000 4389899ac19SJiang Yutang #ifdef CONFIG_PHYS_64BIT 439c59e1b4dSTimur Tabi #define CONFIG_SYS_PCIE1_MEM_BUS 0xe0000000 440c59e1b4dSTimur Tabi #define CONFIG_SYS_PCIE1_MEM_PHYS 0xc40000000ull 4419899ac19SJiang Yutang #else 4429899ac19SJiang Yutang #define CONFIG_SYS_PCIE1_MEM_BUS 0xc0000000 4439899ac19SJiang Yutang #define CONFIG_SYS_PCIE1_MEM_PHYS 0xc0000000 4449899ac19SJiang Yutang #endif 445c59e1b4dSTimur Tabi #define CONFIG_SYS_PCIE1_MEM_SIZE 0x20000000 /* 512M */ 446c59e1b4dSTimur Tabi #define CONFIG_SYS_PCIE1_IO_VIRT 0xffc20000 447c59e1b4dSTimur Tabi #define CONFIG_SYS_PCIE1_IO_BUS 0x00000000 4489899ac19SJiang Yutang #ifdef CONFIG_PHYS_64BIT 449c59e1b4dSTimur Tabi #define CONFIG_SYS_PCIE1_IO_PHYS 0xfffc20000ull 4509899ac19SJiang Yutang #else 4519899ac19SJiang Yutang #define CONFIG_SYS_PCIE1_IO_PHYS 0xffc20000 4529899ac19SJiang Yutang #endif 453c59e1b4dSTimur Tabi #define CONFIG_SYS_PCIE1_IO_SIZE 0x00010000 /* 64k */ 454c59e1b4dSTimur Tabi 455c59e1b4dSTimur Tabi /* controller 2, direct to uli, tgtid 2, Base address 9000 */ 456c59e1b4dSTimur Tabi #define CONFIG_SYS_PCIE2_MEM_VIRT 0xa0000000 4579899ac19SJiang Yutang #ifdef CONFIG_PHYS_64BIT 458c59e1b4dSTimur Tabi #define CONFIG_SYS_PCIE2_MEM_BUS 0xe0000000 459c59e1b4dSTimur Tabi #define CONFIG_SYS_PCIE2_MEM_PHYS 0xc20000000ull 4609899ac19SJiang Yutang #else 4619899ac19SJiang Yutang #define CONFIG_SYS_PCIE2_MEM_BUS 0xa0000000 4629899ac19SJiang Yutang #define CONFIG_SYS_PCIE2_MEM_PHYS 0xa0000000 4639899ac19SJiang Yutang #endif 464c59e1b4dSTimur Tabi #define CONFIG_SYS_PCIE2_MEM_SIZE 0x20000000 /* 512M */ 465c59e1b4dSTimur Tabi #define CONFIG_SYS_PCIE2_IO_VIRT 0xffc10000 466c59e1b4dSTimur Tabi #define CONFIG_SYS_PCIE2_IO_BUS 0x00000000 4679899ac19SJiang Yutang #ifdef CONFIG_PHYS_64BIT 468c59e1b4dSTimur Tabi #define CONFIG_SYS_PCIE2_IO_PHYS 0xfffc10000ull 4699899ac19SJiang Yutang #else 4709899ac19SJiang Yutang #define CONFIG_SYS_PCIE2_IO_PHYS 0xffc10000 4719899ac19SJiang Yutang #endif 472c59e1b4dSTimur Tabi #define CONFIG_SYS_PCIE2_IO_SIZE 0x00010000 /* 64k */ 473c59e1b4dSTimur Tabi 474c59e1b4dSTimur Tabi /* controller 3, Slot 1, tgtid 3, Base address b000 */ 475c59e1b4dSTimur Tabi #define CONFIG_SYS_PCIE3_MEM_VIRT 0x80000000 4769899ac19SJiang Yutang #ifdef CONFIG_PHYS_64BIT 477c59e1b4dSTimur Tabi #define CONFIG_SYS_PCIE3_MEM_BUS 0xe0000000 478c59e1b4dSTimur Tabi #define CONFIG_SYS_PCIE3_MEM_PHYS 0xc00000000ull 4799899ac19SJiang Yutang #else 4809899ac19SJiang Yutang #define CONFIG_SYS_PCIE3_MEM_BUS 0x80000000 4819899ac19SJiang Yutang #define CONFIG_SYS_PCIE3_MEM_PHYS 0x80000000 4829899ac19SJiang Yutang #endif 483c59e1b4dSTimur Tabi #define CONFIG_SYS_PCIE3_MEM_SIZE 0x20000000 /* 512M */ 484c59e1b4dSTimur Tabi #define CONFIG_SYS_PCIE3_IO_VIRT 0xffc00000 485c59e1b4dSTimur Tabi #define CONFIG_SYS_PCIE3_IO_BUS 0x00000000 4869899ac19SJiang Yutang #ifdef CONFIG_PHYS_64BIT 487c59e1b4dSTimur Tabi #define CONFIG_SYS_PCIE3_IO_PHYS 0xfffc00000ull 4889899ac19SJiang Yutang #else 4899899ac19SJiang Yutang #define CONFIG_SYS_PCIE3_IO_PHYS 0xffc00000 4909899ac19SJiang Yutang #endif 491c59e1b4dSTimur Tabi #define CONFIG_SYS_PCIE3_IO_SIZE 0x00010000 /* 64k */ 492c59e1b4dSTimur Tabi 493c59e1b4dSTimur Tabi #ifdef CONFIG_PCI 494842033e6SGabor Juhos #define CONFIG_PCI_INDIRECT_BRIDGE 495c59e1b4dSTimur Tabi #define CONFIG_PCI_PNP /* do pci plug-and-play */ 496c59e1b4dSTimur Tabi #define CONFIG_PCI_SCAN_SHOW /* show pci devices on startup */ 49716855ec1SKumar Gala #define CONFIG_E1000 /* Define e1000 pci Ethernet card */ 498c59e1b4dSTimur Tabi #endif 499c59e1b4dSTimur Tabi 500c59e1b4dSTimur Tabi /* SATA */ 501c59e1b4dSTimur Tabi #define CONFIG_LIBATA 502c59e1b4dSTimur Tabi #define CONFIG_FSL_SATA 5039760b274SZang Roy-R61911 #define CONFIG_FSL_SATA_V2 504c59e1b4dSTimur Tabi 505c59e1b4dSTimur Tabi #define CONFIG_SYS_SATA_MAX_DEVICE 2 506c59e1b4dSTimur Tabi #define CONFIG_SATA1 507c59e1b4dSTimur Tabi #define CONFIG_SYS_SATA1 CONFIG_SYS_MPC85xx_SATA1_ADDR 508c59e1b4dSTimur Tabi #define CONFIG_SYS_SATA1_FLAGS FLAGS_DMA 509c59e1b4dSTimur Tabi #define CONFIG_SATA2 510c59e1b4dSTimur Tabi #define CONFIG_SYS_SATA2 CONFIG_SYS_MPC85xx_SATA2_ADDR 511c59e1b4dSTimur Tabi #define CONFIG_SYS_SATA2_FLAGS FLAGS_DMA 512c59e1b4dSTimur Tabi 513c59e1b4dSTimur Tabi #ifdef CONFIG_FSL_SATA 514c59e1b4dSTimur Tabi #define CONFIG_LBA48 515c59e1b4dSTimur Tabi #define CONFIG_CMD_SATA 516c59e1b4dSTimur Tabi #define CONFIG_DOS_PARTITION 517c59e1b4dSTimur Tabi #define CONFIG_CMD_EXT2 518c59e1b4dSTimur Tabi #endif 519c59e1b4dSTimur Tabi 520c59e1b4dSTimur Tabi #define CONFIG_MMC 521c59e1b4dSTimur Tabi #ifdef CONFIG_MMC 522c59e1b4dSTimur Tabi #define CONFIG_CMD_MMC 523c59e1b4dSTimur Tabi #define CONFIG_FSL_ESDHC 524c59e1b4dSTimur Tabi #define CONFIG_GENERIC_MMC 525c59e1b4dSTimur Tabi #define CONFIG_SYS_FSL_ESDHC_ADDR CONFIG_SYS_MPC85xx_ESDHC_ADDR 526c59e1b4dSTimur Tabi #endif 527c59e1b4dSTimur Tabi 528c59e1b4dSTimur Tabi #if defined(CONFIG_MMC) || defined(CONFIG_USB_EHCI) 529c59e1b4dSTimur Tabi #define CONFIG_CMD_EXT2 530c59e1b4dSTimur Tabi #define CONFIG_CMD_FAT 531c59e1b4dSTimur Tabi #define CONFIG_DOS_PARTITION 532c59e1b4dSTimur Tabi #endif 533c59e1b4dSTimur Tabi 534c59e1b4dSTimur Tabi #define CONFIG_TSEC_ENET 535c59e1b4dSTimur Tabi #ifdef CONFIG_TSEC_ENET 536c59e1b4dSTimur Tabi 537c59e1b4dSTimur Tabi #define CONFIG_TSECV2 538c59e1b4dSTimur Tabi 539c59e1b4dSTimur Tabi #define CONFIG_MII /* MII PHY management */ 540c59e1b4dSTimur Tabi #define CONFIG_TSEC1 1 541c59e1b4dSTimur Tabi #define CONFIG_TSEC1_NAME "eTSEC1" 542c59e1b4dSTimur Tabi #define CONFIG_TSEC2 1 543c59e1b4dSTimur Tabi #define CONFIG_TSEC2_NAME "eTSEC2" 544c59e1b4dSTimur Tabi 545c59e1b4dSTimur Tabi #define TSEC1_PHY_ADDR 1 546c59e1b4dSTimur Tabi #define TSEC2_PHY_ADDR 2 547c59e1b4dSTimur Tabi 548c59e1b4dSTimur Tabi #define TSEC1_FLAGS (TSEC_GIGABIT | TSEC_REDUCED) 549c59e1b4dSTimur Tabi #define TSEC2_FLAGS (TSEC_GIGABIT | TSEC_REDUCED) 550c59e1b4dSTimur Tabi 551c59e1b4dSTimur Tabi #define TSEC1_PHYIDX 0 552c59e1b4dSTimur Tabi #define TSEC2_PHYIDX 0 553c59e1b4dSTimur Tabi 554c59e1b4dSTimur Tabi #define CONFIG_ETHPRIME "eTSEC1" 555c59e1b4dSTimur Tabi 556c59e1b4dSTimur Tabi #define CONFIG_PHY_GIGE /* Include GbE speed/duplex detection */ 557c59e1b4dSTimur Tabi #endif 558c59e1b4dSTimur Tabi 559c59e1b4dSTimur Tabi /* 560c59e1b4dSTimur Tabi * Environment 561c59e1b4dSTimur Tabi */ 562af253608SMatthew McClintock #ifdef CONFIG_RAMBOOT_SPIFLASH 563af253608SMatthew McClintock #define CONFIG_ENV_IS_IN_SPI_FLASH 564af253608SMatthew McClintock #define CONFIG_ENV_SPI_BUS 0 565af253608SMatthew McClintock #define CONFIG_ENV_SPI_CS 0 566af253608SMatthew McClintock #define CONFIG_ENV_SPI_MAX_HZ 10000000 567af253608SMatthew McClintock #define CONFIG_ENV_SPI_MODE 0 568af253608SMatthew McClintock #define CONFIG_ENV_SIZE 0x2000 /* 8KB */ 569af253608SMatthew McClintock #define CONFIG_ENV_OFFSET 0x100000 /* 1MB */ 570af253608SMatthew McClintock #define CONFIG_ENV_SECT_SIZE 0x10000 571*7c8eea59SYing Zhang #elif defined(CONFIG_SDCARD) 572af253608SMatthew McClintock #define CONFIG_ENV_IS_IN_MMC 573*7c8eea59SYing Zhang #define CONFIG_FSL_FIXED_MMC_LOCATION 574c59e1b4dSTimur Tabi #define CONFIG_ENV_SIZE 0x2000 575af253608SMatthew McClintock #define CONFIG_SYS_MMC_ENV_DEV 0 576f45210d6SMatthew McClintock #elif defined(CONFIG_NAND) 577af253608SMatthew McClintock #define CONFIG_ENV_IS_IN_NAND 578af253608SMatthew McClintock #define CONFIG_ENV_SIZE CONFIG_SYS_NAND_BLOCK_SIZE 579af253608SMatthew McClintock #define CONFIG_ENV_OFFSET ((512 * 1024) + CONFIG_SYS_NAND_BLOCK_SIZE) 580af253608SMatthew McClintock #define CONFIG_ENV_RANGE (3 * CONFIG_ENV_SIZE) 581f45210d6SMatthew McClintock #elif defined(CONFIG_SYS_RAMBOOT) 582af253608SMatthew McClintock #define CONFIG_ENV_IS_NOWHERE /* Store ENV in memory only */ 583af253608SMatthew McClintock #define CONFIG_ENV_ADDR (CONFIG_SYS_MONITOR_BASE - 0x1000) 584af253608SMatthew McClintock #define CONFIG_ENV_SIZE 0x2000 585af253608SMatthew McClintock #else 586af253608SMatthew McClintock #define CONFIG_ENV_IS_IN_FLASH 587af253608SMatthew McClintock #if CONFIG_SYS_MONITOR_BASE > 0xfff80000 588af253608SMatthew McClintock #define CONFIG_ENV_ADDR 0xfff80000 589af253608SMatthew McClintock #else 590af253608SMatthew McClintock #define CONFIG_ENV_ADDR (CONFIG_SYS_MONITOR_BASE - CONFIG_ENV_SECT_SIZE) 591af253608SMatthew McClintock #endif 592af253608SMatthew McClintock #define CONFIG_ENV_SIZE 0x2000 593af253608SMatthew McClintock #define CONFIG_ENV_SECT_SIZE 0x20000 /* 128K (one sector) */ 594af253608SMatthew McClintock #endif 595c59e1b4dSTimur Tabi 596c59e1b4dSTimur Tabi #define CONFIG_LOADS_ECHO 597c59e1b4dSTimur Tabi #define CONFIG_SYS_LOADS_BAUD_CHANGE 598c59e1b4dSTimur Tabi 599c59e1b4dSTimur Tabi /* 600c59e1b4dSTimur Tabi * Command line configuration. 601c59e1b4dSTimur Tabi */ 602c59e1b4dSTimur Tabi #include <config_cmd_default.h> 603c59e1b4dSTimur Tabi 60479ee3448SKumar Gala #define CONFIG_CMD_ELF 60579ee3448SKumar Gala #define CONFIG_CMD_ERRATA 606c59e1b4dSTimur Tabi #define CONFIG_CMD_IRQ 607c59e1b4dSTimur Tabi #define CONFIG_CMD_I2C 608c59e1b4dSTimur Tabi #define CONFIG_CMD_MII 60979ee3448SKumar Gala #define CONFIG_CMD_PING 610c59e1b4dSTimur Tabi #define CONFIG_CMD_SETEXPR 611b8339e2bSMatthew McClintock #define CONFIG_CMD_REGINFO 612c59e1b4dSTimur Tabi 613c59e1b4dSTimur Tabi #ifdef CONFIG_PCI 614c59e1b4dSTimur Tabi #define CONFIG_CMD_PCI 615c59e1b4dSTimur Tabi #define CONFIG_CMD_NET 616c59e1b4dSTimur Tabi #endif 617c59e1b4dSTimur Tabi 618c59e1b4dSTimur Tabi /* 619c59e1b4dSTimur Tabi * USB 620c59e1b4dSTimur Tabi */ 6213d7506faSramneek mehresh #define CONFIG_HAS_FSL_DR_USB 6223d7506faSramneek mehresh #ifdef CONFIG_HAS_FSL_DR_USB 623c59e1b4dSTimur Tabi #define CONFIG_USB_EHCI 624c59e1b4dSTimur Tabi 625c59e1b4dSTimur Tabi #ifdef CONFIG_USB_EHCI 626c59e1b4dSTimur Tabi #define CONFIG_CMD_USB 627c59e1b4dSTimur Tabi #define CONFIG_EHCI_HCD_INIT_AFTER_RESET 628c59e1b4dSTimur Tabi #define CONFIG_USB_EHCI_FSL 629c59e1b4dSTimur Tabi #define CONFIG_USB_STORAGE 630c59e1b4dSTimur Tabi #define CONFIG_CMD_FAT 631c59e1b4dSTimur Tabi #endif 6323d7506faSramneek mehresh #endif 633c59e1b4dSTimur Tabi 634c59e1b4dSTimur Tabi /* 635c59e1b4dSTimur Tabi * Miscellaneous configurable options 636c59e1b4dSTimur Tabi */ 637c59e1b4dSTimur Tabi #define CONFIG_SYS_LONGHELP /* undef to save memory */ 638c59e1b4dSTimur Tabi #define CONFIG_CMDLINE_EDITING /* Command-line editing */ 6395be58f5fSKim Phillips #define CONFIG_AUTO_COMPLETE /* add autocompletion support */ 640c59e1b4dSTimur Tabi #define CONFIG_SYS_LOAD_ADDR 0x2000000 /* default load address */ 641c59e1b4dSTimur Tabi #define CONFIG_SYS_PROMPT "=> " /* Monitor Command Prompt */ 642c59e1b4dSTimur Tabi #ifdef CONFIG_CMD_KGDB 643c59e1b4dSTimur Tabi #define CONFIG_SYS_CBSIZE 1024 /* Console I/O Buffer Size */ 644c59e1b4dSTimur Tabi #else 645c59e1b4dSTimur Tabi #define CONFIG_SYS_CBSIZE 256 /* Console I/O Buffer Size */ 646c59e1b4dSTimur Tabi #endif 647c59e1b4dSTimur Tabi /* Print Buffer Size */ 648c59e1b4dSTimur Tabi #define CONFIG_SYS_PBSIZE (CONFIG_SYS_CBSIZE + sizeof(CONFIG_SYS_PROMPT) + 16) 649c59e1b4dSTimur Tabi #define CONFIG_SYS_MAXARGS 16 650c59e1b4dSTimur Tabi #define CONFIG_SYS_BARGSIZE CONFIG_SYS_CBSIZE 651c59e1b4dSTimur Tabi #define CONFIG_SYS_HZ 1000 652c59e1b4dSTimur Tabi 653c59e1b4dSTimur Tabi /* 654c59e1b4dSTimur Tabi * For booting Linux, the board info and command line data 655a832ac41SKumar Gala * have to be in the first 64 MB of memory, since this is 656c59e1b4dSTimur Tabi * the maximum mapped by the Linux kernel during initialization. 657c59e1b4dSTimur Tabi */ 658a832ac41SKumar Gala #define CONFIG_SYS_BOOTMAPSZ (64 << 20) /* Initial Memory map for Linux*/ 659a832ac41SKumar Gala #define CONFIG_SYS_BOOTM_LEN (64 << 20) /* Increase max gunzip size */ 660c59e1b4dSTimur Tabi 661c59e1b4dSTimur Tabi #ifdef CONFIG_CMD_KGDB 662c59e1b4dSTimur Tabi #define CONFIG_KGDB_BAUDRATE 230400 /* speed to run kgdb serial port */ 663c59e1b4dSTimur Tabi #define CONFIG_KGDB_SER_INDEX 2 /* which serial port to use */ 664c59e1b4dSTimur Tabi #endif 665c59e1b4dSTimur Tabi 666c59e1b4dSTimur Tabi /* 667c59e1b4dSTimur Tabi * Environment Configuration 668c59e1b4dSTimur Tabi */ 669c59e1b4dSTimur Tabi 670c59e1b4dSTimur Tabi #define CONFIG_HOSTNAME p1022ds 6718b3637c6SJoe Hershberger #define CONFIG_ROOTPATH "/opt/nfsroot" 672b3f44c21SJoe Hershberger #define CONFIG_BOOTFILE "uImage" 673c59e1b4dSTimur Tabi #define CONFIG_UBOOTPATH u-boot.bin /* U-Boot image on TFTP server */ 674c59e1b4dSTimur Tabi 675c59e1b4dSTimur Tabi #define CONFIG_LOADADDR 1000000 676c59e1b4dSTimur Tabi 677c59e1b4dSTimur Tabi #define CONFIG_BOOTDELAY 10 /* -1 disables auto-boot */ 678c59e1b4dSTimur Tabi 679c59e1b4dSTimur Tabi #define CONFIG_BAUDRATE 115200 680c59e1b4dSTimur Tabi 681c59e1b4dSTimur Tabi #define CONFIG_EXTRA_ENV_SETTINGS \ 682c59e1b4dSTimur Tabi "netdev=eth0\0" \ 6835368c55dSMarek Vasut "uboot=" __stringify(CONFIG_UBOOTPATH) "\0" \ 6845368c55dSMarek Vasut "ubootaddr=" __stringify(CONFIG_SYS_TEXT_BASE) "\0" \ 68584e34b65STimur Tabi "tftpflash=tftpboot $loadaddr $uboot && " \ 68684e34b65STimur Tabi "protect off $ubootaddr +$filesize && " \ 68784e34b65STimur Tabi "erase $ubootaddr +$filesize && " \ 68884e34b65STimur Tabi "cp.b $loadaddr $ubootaddr $filesize && " \ 68984e34b65STimur Tabi "protect on $ubootaddr +$filesize && " \ 69084e34b65STimur Tabi "cmp.b $loadaddr $ubootaddr $filesize\0" \ 691c59e1b4dSTimur Tabi "consoledev=ttyS0\0" \ 692c59e1b4dSTimur Tabi "ramdiskaddr=2000000\0" \ 69384e34b65STimur Tabi "ramdiskfile=rootfs.ext2.gz.uboot\0" \ 694c59e1b4dSTimur Tabi "fdtaddr=c00000\0" \ 695c59e1b4dSTimur Tabi "fdtfile=p1022ds.dtb\0" \ 696c59e1b4dSTimur Tabi "bdev=sda3\0" \ 697ba8e76bdSTimur Tabi "hwconfig=esdhc;audclk:12\0" 698c59e1b4dSTimur Tabi 699c59e1b4dSTimur Tabi #define CONFIG_HDBOOT \ 700c59e1b4dSTimur Tabi "setenv bootargs root=/dev/$bdev rw " \ 70184e34b65STimur Tabi "console=$consoledev,$baudrate $othbootargs $videobootargs;" \ 702c59e1b4dSTimur Tabi "tftp $loadaddr $bootfile;" \ 703c59e1b4dSTimur Tabi "tftp $fdtaddr $fdtfile;" \ 704c59e1b4dSTimur Tabi "bootm $loadaddr - $fdtaddr" 705c59e1b4dSTimur Tabi 706c59e1b4dSTimur Tabi #define CONFIG_NFSBOOTCOMMAND \ 707c59e1b4dSTimur Tabi "setenv bootargs root=/dev/nfs rw " \ 708c59e1b4dSTimur Tabi "nfsroot=$serverip:$rootpath " \ 709c59e1b4dSTimur Tabi "ip=$ipaddr:$serverip:$gatewayip:$netmask:$hostname:$netdev:off " \ 71084e34b65STimur Tabi "console=$consoledev,$baudrate $othbootargs $videobootargs;" \ 711c59e1b4dSTimur Tabi "tftp $loadaddr $bootfile;" \ 712c59e1b4dSTimur Tabi "tftp $fdtaddr $fdtfile;" \ 713c59e1b4dSTimur Tabi "bootm $loadaddr - $fdtaddr" 714c59e1b4dSTimur Tabi 715c59e1b4dSTimur Tabi #define CONFIG_RAMBOOTCOMMAND \ 716c59e1b4dSTimur Tabi "setenv bootargs root=/dev/ram rw " \ 71784e34b65STimur Tabi "console=$consoledev,$baudrate $othbootargs $videobootargs;" \ 718c59e1b4dSTimur Tabi "tftp $ramdiskaddr $ramdiskfile;" \ 719c59e1b4dSTimur Tabi "tftp $loadaddr $bootfile;" \ 720c59e1b4dSTimur Tabi "tftp $fdtaddr $fdtfile;" \ 721c59e1b4dSTimur Tabi "bootm $loadaddr $ramdiskaddr $fdtaddr" 722c59e1b4dSTimur Tabi 723c59e1b4dSTimur Tabi #define CONFIG_BOOTCOMMAND CONFIG_RAMBOOTCOMMAND 724c59e1b4dSTimur Tabi 725c59e1b4dSTimur Tabi #endif 726