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 * 6c59e1b4dSTimur Tabi * This program is free software; you can redistribute it and/or modify it 7c59e1b4dSTimur Tabi * under the terms of the GNU General Public License as published by the Free 8c59e1b4dSTimur Tabi * Software Foundation; either version 2 of the License, or (at your option) 9c59e1b4dSTimur Tabi * any later version. 10c59e1b4dSTimur Tabi */ 11c59e1b4dSTimur Tabi 12c59e1b4dSTimur Tabi #ifndef __CONFIG_H 13c59e1b4dSTimur Tabi #define __CONFIG_H 14c59e1b4dSTimur Tabi 15c59e1b4dSTimur Tabi #include "../board/freescale/common/ics307_clk.h" 16c59e1b4dSTimur Tabi 179899ac19SJiang Yutang #ifdef CONFIG_36BIT 189899ac19SJiang Yutang #define CONFIG_PHYS_64BIT 199899ac19SJiang Yutang #endif 209899ac19SJiang Yutang 21*af253608SMatthew McClintock #ifdef CONFIG_SDCARD 22*af253608SMatthew McClintock #define CONFIG_RAMBOOT_SDCARD 23*af253608SMatthew McClintock #define CONFIG_SYS_RAMBOOT 24*af253608SMatthew McClintock #define CONFIG_SYS_EXTRA_ENV_RELOC 25*af253608SMatthew McClintock #define CONFIG_SYS_TEXT_BASE 0x11000000 26*af253608SMatthew McClintock #define CONFIG_RESET_VECTOR_ADDRESS 0x1107fffc 27*af253608SMatthew McClintock #endif 28*af253608SMatthew McClintock 29*af253608SMatthew McClintock #ifdef CONFIG_SPIFLASH 30*af253608SMatthew McClintock #define CONFIG_RAMBOOT_SPIFLASH 31*af253608SMatthew McClintock #define CONFIG_SYS_RAMBOOT 32*af253608SMatthew McClintock #define CONFIG_SYS_EXTRA_ENV_RELOC 33*af253608SMatthew McClintock #define CONFIG_SYS_TEXT_BASE 0x11000000 34*af253608SMatthew McClintock #define CONFIG_RESET_VECTOR_ADDRESS 0x1107fffc 35*af253608SMatthew McClintock #endif 36*af253608SMatthew McClintock 37c59e1b4dSTimur Tabi /* High Level Configuration Options */ 38c59e1b4dSTimur Tabi #define CONFIG_BOOKE /* BOOKE */ 39c59e1b4dSTimur Tabi #define CONFIG_E500 /* BOOKE e500 family */ 40c59e1b4dSTimur Tabi #define CONFIG_MPC85xx /* MPC8540/60/55/41/48 */ 41c59e1b4dSTimur Tabi #define CONFIG_P1022 42c59e1b4dSTimur Tabi #define CONFIG_P1022DS 43c59e1b4dSTimur Tabi #define CONFIG_MP /* support multiple processors */ 44c59e1b4dSTimur Tabi 452ae18241SWolfgang Denk #ifndef CONFIG_SYS_TEXT_BASE 462ae18241SWolfgang Denk #define CONFIG_SYS_TEXT_BASE 0xeff80000 472ae18241SWolfgang Denk #endif 482ae18241SWolfgang Denk 497a577fdaSKumar Gala #ifndef CONFIG_RESET_VECTOR_ADDRESS 507a577fdaSKumar Gala #define CONFIG_RESET_VECTOR_ADDRESS 0xeffffffc 517a577fdaSKumar Gala #endif 527a577fdaSKumar Gala 53c59e1b4dSTimur Tabi #define CONFIG_FSL_ELBC /* Has Enhanced localbus controller */ 54c59e1b4dSTimur Tabi #define CONFIG_PCI /* Enable PCI/PCIE */ 55c59e1b4dSTimur Tabi #define CONFIG_PCIE1 /* PCIE controler 1 (slot 1) */ 56c59e1b4dSTimur Tabi #define CONFIG_PCIE2 /* PCIE controler 2 (slot 2) */ 57c59e1b4dSTimur Tabi #define CONFIG_PCIE3 /* PCIE controler 3 (ULI bridge) */ 58c59e1b4dSTimur Tabi #define CONFIG_FSL_PCI_INIT /* Use common FSL init code */ 59c59e1b4dSTimur Tabi #define CONFIG_FSL_PCIE_RESET /* need PCIe reset errata */ 60c59e1b4dSTimur Tabi #define CONFIG_SYS_PCI_64BIT /* enable 64-bit PCI resources */ 61c59e1b4dSTimur Tabi 62c59e1b4dSTimur Tabi #define CONFIG_ENABLE_36BIT_PHYS 63babb348cSTimur Tabi 64babb348cSTimur Tabi #ifdef CONFIG_PHYS_64BIT 65c59e1b4dSTimur Tabi #define CONFIG_ADDR_MAP 66c59e1b4dSTimur Tabi #define CONFIG_SYS_NUM_ADDR_MAP 16 /* number of TLB1 entries */ 679899ac19SJiang Yutang #endif 68c59e1b4dSTimur Tabi 69c59e1b4dSTimur Tabi #define CONFIG_FSL_LAW /* Use common FSL init code */ 70c59e1b4dSTimur Tabi 71c59e1b4dSTimur Tabi #define CONFIG_SYS_CLK_FREQ get_board_sys_clk() 72c59e1b4dSTimur Tabi #define CONFIG_DDR_CLK_FREQ get_board_ddr_clk() 73c59e1b4dSTimur Tabi #define CONFIG_ICS307_REFCLK_HZ 33333000 /* ICS307 clock chip ref freq */ 74c59e1b4dSTimur Tabi 75c59e1b4dSTimur Tabi /* 76c59e1b4dSTimur Tabi * These can be toggled for performance analysis, otherwise use default. 77c59e1b4dSTimur Tabi */ 78c59e1b4dSTimur Tabi #define CONFIG_L2_CACHE 79c59e1b4dSTimur Tabi #define CONFIG_BTB 80c59e1b4dSTimur Tabi 81c59e1b4dSTimur Tabi #define CONFIG_SYS_MEMTEST_START 0x00000000 82c59e1b4dSTimur Tabi #define CONFIG_SYS_MEMTEST_END 0x7fffffff 83c59e1b4dSTimur Tabi 84e46fedfeSTimur Tabi #define CONFIG_SYS_CCSRBAR 0xffe00000 85e46fedfeSTimur Tabi #define CONFIG_SYS_CCSRBAR_PHYS_LOW CONFIG_SYS_CCSRBAR 86c59e1b4dSTimur Tabi 87c59e1b4dSTimur Tabi /* DDR Setup */ 88c59e1b4dSTimur Tabi #define CONFIG_DDR_SPD 89c59e1b4dSTimur Tabi #define CONFIG_VERY_BIG_RAM 90c59e1b4dSTimur Tabi #define CONFIG_FSL_DDR3 91c59e1b4dSTimur Tabi 92c59e1b4dSTimur Tabi #ifdef CONFIG_DDR_ECC 93c59e1b4dSTimur Tabi #define CONFIG_ECC_INIT_VIA_DDRCONTROLLER 94c59e1b4dSTimur Tabi #define CONFIG_MEM_INIT_VALUE 0xdeadbeef 95c59e1b4dSTimur Tabi #endif 96c59e1b4dSTimur Tabi 97c59e1b4dSTimur Tabi #define CONFIG_SYS_DDR_SDRAM_BASE 0x00000000 98c59e1b4dSTimur Tabi #define CONFIG_SYS_SDRAM_BASE CONFIG_SYS_DDR_SDRAM_BASE 99c59e1b4dSTimur Tabi 100c59e1b4dSTimur Tabi #define CONFIG_NUM_DDR_CONTROLLERS 1 101c59e1b4dSTimur Tabi #define CONFIG_DIMM_SLOTS_PER_CTLR 1 102c59e1b4dSTimur Tabi #define CONFIG_CHIP_SELECTS_PER_CTRL (2 * CONFIG_DIMM_SLOTS_PER_CTLR) 103c59e1b4dSTimur Tabi 104c59e1b4dSTimur Tabi /* I2C addresses of SPD EEPROMs */ 105c59e1b4dSTimur Tabi #define CONFIG_SYS_SPD_BUS_NUM 1 106c39f44dcSKumar Gala #define SPD_EEPROM_ADDRESS 0x51 /* CTLR 0 DIMM 0 */ 107c59e1b4dSTimur Tabi 108c59e1b4dSTimur Tabi /* 109c59e1b4dSTimur Tabi * Memory map 110c59e1b4dSTimur Tabi * 111c59e1b4dSTimur Tabi * 0x0000_0000 0x7fff_ffff DDR 2G Cacheable 112c59e1b4dSTimur Tabi * 0x8000_0000 0xdfff_ffff PCI Express Mem 1.5G non-cacheable 113c59e1b4dSTimur Tabi * 0xffc0_0000 0xffc2_ffff PCI IO range 192K non-cacheable 114c59e1b4dSTimur Tabi * 115c59e1b4dSTimur Tabi * Localbus cacheable (TBD) 116c59e1b4dSTimur Tabi * 0xXXXX_XXXX 0xXXXX_XXXX SRAM YZ M Cacheable 117c59e1b4dSTimur Tabi * 118c59e1b4dSTimur Tabi * Localbus non-cacheable 119c59e1b4dSTimur Tabi * 0xe000_0000 0xe80f_ffff Promjet/free 128M non-cacheable 120c59e1b4dSTimur Tabi * 0xe800_0000 0xefff_ffff FLASH 128M non-cacheable 121c59e1b4dSTimur Tabi * 0xffdf_0000 0xffdf_7fff PIXIS 32K non-cacheable TLB0 122c59e1b4dSTimur Tabi * 0xffd0_0000 0xffd0_3fff L1 for stack 16K Cacheable TLB0 123c59e1b4dSTimur Tabi * 0xffe0_0000 0xffef_ffff CCSR 1M non-cacheable 124c59e1b4dSTimur Tabi */ 125c59e1b4dSTimur Tabi 126c59e1b4dSTimur Tabi /* 127c59e1b4dSTimur Tabi * Local Bus Definitions 128c59e1b4dSTimur Tabi */ 129c59e1b4dSTimur Tabi #define CONFIG_SYS_FLASH_BASE 0xe0000000 /* start of FLASH 128M */ 1309899ac19SJiang Yutang #ifdef CONFIG_PHYS_64BIT 131c59e1b4dSTimur Tabi #define CONFIG_SYS_FLASH_BASE_PHYS 0xfe0000000ull 1329899ac19SJiang Yutang #else 1339899ac19SJiang Yutang #define CONFIG_SYS_FLASH_BASE_PHYS CONFIG_SYS_FLASH_BASE 1349899ac19SJiang Yutang #endif 135c59e1b4dSTimur Tabi 136c59e1b4dSTimur Tabi #define CONFIG_FLASH_BR_PRELIM \ 137c59e1b4dSTimur Tabi (BR_PHYS_ADDR((CONFIG_SYS_FLASH_BASE_PHYS + 0x8000000)) | BR_PS_16 | BR_V) 138c59e1b4dSTimur Tabi #define CONFIG_FLASH_OR_PRELIM (OR_AM_128MB | 0xff7) 139c59e1b4dSTimur Tabi 140c59e1b4dSTimur Tabi #define CONFIG_SYS_BR0_PRELIM CONFIG_FLASH_BR_PRELIM /* NOR Base Address */ 141c59e1b4dSTimur Tabi #define CONFIG_SYS_OR0_PRELIM CONFIG_FLASH_OR_PRELIM /* NOR Options */ 142c59e1b4dSTimur Tabi 143c59e1b4dSTimur Tabi #define CONFIG_SYS_BR1_PRELIM \ 144c59e1b4dSTimur Tabi (BR_PHYS_ADDR(CONFIG_SYS_FLASH_BASE_PHYS) | BR_PS_16 | BR_V) 145c59e1b4dSTimur Tabi #define CONFIG_SYS_OR1_PRELIM CONFIG_FLASH_OR_PRELIM 146c59e1b4dSTimur Tabi 147c59e1b4dSTimur Tabi #define CONFIG_SYS_FLASH_BANKS_LIST \ 148c59e1b4dSTimur Tabi {CONFIG_SYS_FLASH_BASE_PHYS + 0x8000000, CONFIG_SYS_FLASH_BASE_PHYS} 149c59e1b4dSTimur Tabi #define CONFIG_SYS_FLASH_QUIET_TEST 150c59e1b4dSTimur Tabi #define CONFIG_FLASH_SHOW_PROGRESS 45 /* count down from 45/5: 9..1 */ 151c59e1b4dSTimur Tabi 152c59e1b4dSTimur Tabi #define CONFIG_SYS_MAX_FLASH_BANKS 2 153c59e1b4dSTimur Tabi #define CONFIG_SYS_MAX_FLASH_SECT 1024 154c59e1b4dSTimur Tabi 15514d0a02aSWolfgang Denk #define CONFIG_SYS_MONITOR_BASE CONFIG_SYS_TEXT_BASE /* start of monitor */ 156c59e1b4dSTimur Tabi 157c59e1b4dSTimur Tabi #define CONFIG_FLASH_CFI_DRIVER 158c59e1b4dSTimur Tabi #define CONFIG_SYS_FLASH_CFI 159c59e1b4dSTimur Tabi #define CONFIG_SYS_FLASH_EMPTY_INFO 160c59e1b4dSTimur Tabi 161c59e1b4dSTimur Tabi #define CONFIG_BOARD_EARLY_INIT_F 162c59e1b4dSTimur Tabi #define CONFIG_BOARD_EARLY_INIT_R 163c59e1b4dSTimur Tabi #define CONFIG_MISC_INIT_R 164a2d12f88STimur Tabi #define CONFIG_HWCONFIG 165c59e1b4dSTimur Tabi 166c59e1b4dSTimur Tabi #define CONFIG_FSL_NGPIXIS 167c59e1b4dSTimur Tabi #define PIXIS_BASE 0xffdf0000 /* PIXIS registers */ 1689899ac19SJiang Yutang #ifdef CONFIG_PHYS_64BIT 169c59e1b4dSTimur Tabi #define PIXIS_BASE_PHYS 0xfffdf0000ull 1709899ac19SJiang Yutang #else 1719899ac19SJiang Yutang #define PIXIS_BASE_PHYS PIXIS_BASE 1729899ac19SJiang Yutang #endif 173c59e1b4dSTimur Tabi 174c59e1b4dSTimur Tabi #define CONFIG_SYS_BR2_PRELIM (BR_PHYS_ADDR(PIXIS_BASE_PHYS) | BR_PS_8 | BR_V) 175c59e1b4dSTimur Tabi #define CONFIG_SYS_OR2_PRELIM (OR_AM_32KB | 0x6ff7) 176c59e1b4dSTimur Tabi 177c59e1b4dSTimur Tabi #define PIXIS_LBMAP_SWITCH 7 1782906845aSYork Sun #define PIXIS_LBMAP_MASK 0xF0 179c59e1b4dSTimur Tabi #define PIXIS_LBMAP_ALTBANK 0x20 1809b6e9d1cSJiang Yutang #define PIXIS_ELBC_SPI_MASK 0xc0 1819b6e9d1cSJiang Yutang #define PIXIS_SPI 0x80 182c59e1b4dSTimur Tabi 183c59e1b4dSTimur Tabi #define CONFIG_SYS_INIT_RAM_LOCK 184c59e1b4dSTimur Tabi #define CONFIG_SYS_INIT_RAM_ADDR 0xffd00000 /* Initial L1 address */ 185553f0982SWolfgang Denk #define CONFIG_SYS_INIT_RAM_SIZE 0x00004000 /* Size of used area in RAM */ 186c59e1b4dSTimur Tabi 187c59e1b4dSTimur Tabi #define CONFIG_SYS_GBL_DATA_OFFSET \ 18825ddd1fbSWolfgang Denk (CONFIG_SYS_INIT_RAM_SIZE - GENERATED_GBL_DATA_SIZE) 189c59e1b4dSTimur Tabi #define CONFIG_SYS_INIT_SP_OFFSET CONFIG_SYS_GBL_DATA_OFFSET 190c59e1b4dSTimur Tabi 191c59e1b4dSTimur Tabi #define CONFIG_SYS_MONITOR_LEN (512 * 1024) 19207b5edc2SJerry Huang #define CONFIG_SYS_MALLOC_LEN (10 * 1024 * 1024) 193c59e1b4dSTimur Tabi 194c59e1b4dSTimur Tabi /* 195c59e1b4dSTimur Tabi * Serial Port 196c59e1b4dSTimur Tabi */ 197c59e1b4dSTimur Tabi #define CONFIG_CONS_INDEX 1 198c59e1b4dSTimur Tabi #define CONFIG_SYS_NS16550 199c59e1b4dSTimur Tabi #define CONFIG_SYS_NS16550_SERIAL 200c59e1b4dSTimur Tabi #define CONFIG_SYS_NS16550_REG_SIZE 1 201c59e1b4dSTimur Tabi #define CONFIG_SYS_NS16550_CLK get_bus_freq(0) 202c59e1b4dSTimur Tabi 203c59e1b4dSTimur Tabi #define CONFIG_SYS_BAUDRATE_TABLE \ 204c59e1b4dSTimur Tabi {300, 600, 1200, 2400, 4800, 9600, 19200, 38400, 57600, 115200} 205c59e1b4dSTimur Tabi 206c59e1b4dSTimur Tabi #define CONFIG_SYS_NS16550_COM1 (CONFIG_SYS_CCSRBAR+0x4500) 207c59e1b4dSTimur Tabi #define CONFIG_SYS_NS16550_COM2 (CONFIG_SYS_CCSRBAR+0x4600) 208c59e1b4dSTimur Tabi 209c59e1b4dSTimur Tabi /* Use the HUSH parser */ 210c59e1b4dSTimur Tabi #define CONFIG_SYS_HUSH_PARSER 211c59e1b4dSTimur Tabi 212c59e1b4dSTimur Tabi /* Video */ 213ba8e76bdSTimur Tabi #define CONFIG_FSL_DIU_FB 214ba8e76bdSTimur Tabi 215d5e01e49STimur Tabi #ifdef CONFIG_FSL_DIU_FB 216d5e01e49STimur Tabi #define CONFIG_SYS_DIU_ADDR (CONFIG_SYS_CCSRBAR + 0x10000) 217d5e01e49STimur Tabi #define CONFIG_VIDEO 218d5e01e49STimur Tabi #define CONFIG_CMD_BMP 219c59e1b4dSTimur Tabi #define CONFIG_CFB_CONSOLE 2207d3053fbSTimur Tabi #define CONFIG_VIDEO_SW_CURSOR 221c59e1b4dSTimur Tabi #define CONFIG_VGA_AS_SINGLE_DEVICE 222d5e01e49STimur Tabi #define CONFIG_VIDEO_LOGO 223d5e01e49STimur Tabi #define CONFIG_VIDEO_BMP_LOGO 22455b05237STimur Tabi #define CONFIG_CFI_FLASH_USE_WEAK_ACCESSORS 22555b05237STimur Tabi /* 22655b05237STimur Tabi * With CONFIG_CFI_FLASH_USE_WEAK_ACCESSORS, flash I/O is really slow, so 22755b05237STimur Tabi * disable empty flash sector detection, which is I/O-intensive. 22855b05237STimur Tabi */ 22955b05237STimur Tabi #undef CONFIG_SYS_FLASH_EMPTY_INFO 230c59e1b4dSTimur Tabi #endif 231c59e1b4dSTimur Tabi 232ba8e76bdSTimur Tabi #ifndef CONFIG_FSL_DIU_FB 233218a758fSJiang Yutang #define CONFIG_ATI 234218a758fSJiang Yutang #endif 235218a758fSJiang Yutang 236218a758fSJiang Yutang #ifdef CONFIG_ATI 237218a758fSJiang Yutang #define VIDEO_IO_OFFSET CONFIG_SYS_PCIE1_IO_VIRT 238218a758fSJiang Yutang #define CONFIG_VIDEO 239218a758fSJiang Yutang #define CONFIG_BIOSEMU 240218a758fSJiang Yutang #define CONFIG_VIDEO_SW_CURSOR 241218a758fSJiang Yutang #define CONFIG_ATI_RADEON_FB 242218a758fSJiang Yutang #define CONFIG_VIDEO_LOGO 243218a758fSJiang Yutang #define CONFIG_SYS_ISA_IO_BASE_ADDRESS VIDEO_IO_OFFSET 244218a758fSJiang Yutang #define CONFIG_CFB_CONSOLE 245218a758fSJiang Yutang #define CONFIG_VGA_AS_SINGLE_DEVICE 246218a758fSJiang Yutang #endif 247218a758fSJiang Yutang 248c59e1b4dSTimur Tabi /* 249c59e1b4dSTimur Tabi * Pass open firmware flat tree 250c59e1b4dSTimur Tabi */ 251c59e1b4dSTimur Tabi #define CONFIG_OF_LIBFDT 252c59e1b4dSTimur Tabi #define CONFIG_OF_BOARD_SETUP 253c59e1b4dSTimur Tabi #define CONFIG_OF_STDOUT_VIA_ALIAS 254c59e1b4dSTimur Tabi 255c59e1b4dSTimur Tabi /* new uImage format support */ 256c59e1b4dSTimur Tabi #define CONFIG_FIT 257c59e1b4dSTimur Tabi #define CONFIG_FIT_VERBOSE 258c59e1b4dSTimur Tabi 259c59e1b4dSTimur Tabi /* I2C */ 260c59e1b4dSTimur Tabi #define CONFIG_FSL_I2C 261c59e1b4dSTimur Tabi #define CONFIG_HARD_I2C 262c59e1b4dSTimur Tabi #define CONFIG_I2C_MULTI_BUS 263c59e1b4dSTimur Tabi #define CONFIG_SYS_I2C_SPEED 400000 264c59e1b4dSTimur Tabi #define CONFIG_SYS_I2C_EEPROM_ADDR 0x57 265c59e1b4dSTimur Tabi #define CONFIG_SYS_I2C_SLAVE 0x7F 266c59e1b4dSTimur Tabi #define CONFIG_SYS_I2C_NOPROBES {{0, 0x29}} 267c59e1b4dSTimur Tabi #define CONFIG_SYS_I2C_OFFSET 0x3000 268c59e1b4dSTimur Tabi #define CONFIG_SYS_I2C2_OFFSET 0x3100 269c59e1b4dSTimur Tabi 270c59e1b4dSTimur Tabi /* 271c59e1b4dSTimur Tabi * I2C2 EEPROM 272c59e1b4dSTimur Tabi */ 273c59e1b4dSTimur Tabi #define CONFIG_ID_EEPROM 274c59e1b4dSTimur Tabi #define CONFIG_SYS_I2C_EEPROM_NXID 275c59e1b4dSTimur Tabi #define CONFIG_SYS_I2C_EEPROM_ADDR 0x57 276c59e1b4dSTimur Tabi #define CONFIG_SYS_I2C_EEPROM_ADDR_LEN 1 277c59e1b4dSTimur Tabi #define CONFIG_SYS_EEPROM_BUS_NUM 1 278c59e1b4dSTimur Tabi 279c59e1b4dSTimur Tabi /* 2809b6e9d1cSJiang Yutang * eSPI - Enhanced SPI 2819b6e9d1cSJiang Yutang */ 2829b6e9d1cSJiang Yutang #define CONFIG_SPI_FLASH 2839b6e9d1cSJiang Yutang #define CONFIG_SPI_FLASH_SPANSION 2849b6e9d1cSJiang Yutang 2859b6e9d1cSJiang Yutang #define CONFIG_HARD_SPI 2869b6e9d1cSJiang Yutang #define CONFIG_FSL_ESPI 2879b6e9d1cSJiang Yutang 2889b6e9d1cSJiang Yutang #define CONFIG_CMD_SF 2899b6e9d1cSJiang Yutang #define CONFIG_SF_DEFAULT_SPEED 10000000 2909b6e9d1cSJiang Yutang #define CONFIG_SF_DEFAULT_MODE 0 2919b6e9d1cSJiang Yutang 2929b6e9d1cSJiang Yutang /* 293c59e1b4dSTimur Tabi * General PCI 294c59e1b4dSTimur Tabi * Memory space is mapped 1-1, but I/O space must start from 0. 295c59e1b4dSTimur Tabi */ 296c59e1b4dSTimur Tabi 297c59e1b4dSTimur Tabi /* controller 1, Slot 2, tgtid 1, Base address a000 */ 298c59e1b4dSTimur Tabi #define CONFIG_SYS_PCIE1_MEM_VIRT 0xc0000000 2999899ac19SJiang Yutang #ifdef CONFIG_PHYS_64BIT 300c59e1b4dSTimur Tabi #define CONFIG_SYS_PCIE1_MEM_BUS 0xe0000000 301c59e1b4dSTimur Tabi #define CONFIG_SYS_PCIE1_MEM_PHYS 0xc40000000ull 3029899ac19SJiang Yutang #else 3039899ac19SJiang Yutang #define CONFIG_SYS_PCIE1_MEM_BUS 0xc0000000 3049899ac19SJiang Yutang #define CONFIG_SYS_PCIE1_MEM_PHYS 0xc0000000 3059899ac19SJiang Yutang #endif 306c59e1b4dSTimur Tabi #define CONFIG_SYS_PCIE1_MEM_SIZE 0x20000000 /* 512M */ 307c59e1b4dSTimur Tabi #define CONFIG_SYS_PCIE1_IO_VIRT 0xffc20000 308c59e1b4dSTimur Tabi #define CONFIG_SYS_PCIE1_IO_BUS 0x00000000 3099899ac19SJiang Yutang #ifdef CONFIG_PHYS_64BIT 310c59e1b4dSTimur Tabi #define CONFIG_SYS_PCIE1_IO_PHYS 0xfffc20000ull 3119899ac19SJiang Yutang #else 3129899ac19SJiang Yutang #define CONFIG_SYS_PCIE1_IO_PHYS 0xffc20000 3139899ac19SJiang Yutang #endif 314c59e1b4dSTimur Tabi #define CONFIG_SYS_PCIE1_IO_SIZE 0x00010000 /* 64k */ 315c59e1b4dSTimur Tabi 316c59e1b4dSTimur Tabi /* controller 2, direct to uli, tgtid 2, Base address 9000 */ 317c59e1b4dSTimur Tabi #define CONFIG_SYS_PCIE2_MEM_VIRT 0xa0000000 3189899ac19SJiang Yutang #ifdef CONFIG_PHYS_64BIT 319c59e1b4dSTimur Tabi #define CONFIG_SYS_PCIE2_MEM_BUS 0xe0000000 320c59e1b4dSTimur Tabi #define CONFIG_SYS_PCIE2_MEM_PHYS 0xc20000000ull 3219899ac19SJiang Yutang #else 3229899ac19SJiang Yutang #define CONFIG_SYS_PCIE2_MEM_BUS 0xa0000000 3239899ac19SJiang Yutang #define CONFIG_SYS_PCIE2_MEM_PHYS 0xa0000000 3249899ac19SJiang Yutang #endif 325c59e1b4dSTimur Tabi #define CONFIG_SYS_PCIE2_MEM_SIZE 0x20000000 /* 512M */ 326c59e1b4dSTimur Tabi #define CONFIG_SYS_PCIE2_IO_VIRT 0xffc10000 327c59e1b4dSTimur Tabi #define CONFIG_SYS_PCIE2_IO_BUS 0x00000000 3289899ac19SJiang Yutang #ifdef CONFIG_PHYS_64BIT 329c59e1b4dSTimur Tabi #define CONFIG_SYS_PCIE2_IO_PHYS 0xfffc10000ull 3309899ac19SJiang Yutang #else 3319899ac19SJiang Yutang #define CONFIG_SYS_PCIE2_IO_PHYS 0xffc10000 3329899ac19SJiang Yutang #endif 333c59e1b4dSTimur Tabi #define CONFIG_SYS_PCIE2_IO_SIZE 0x00010000 /* 64k */ 334c59e1b4dSTimur Tabi 335c59e1b4dSTimur Tabi /* controller 3, Slot 1, tgtid 3, Base address b000 */ 336c59e1b4dSTimur Tabi #define CONFIG_SYS_PCIE3_MEM_VIRT 0x80000000 3379899ac19SJiang Yutang #ifdef CONFIG_PHYS_64BIT 338c59e1b4dSTimur Tabi #define CONFIG_SYS_PCIE3_MEM_BUS 0xe0000000 339c59e1b4dSTimur Tabi #define CONFIG_SYS_PCIE3_MEM_PHYS 0xc00000000ull 3409899ac19SJiang Yutang #else 3419899ac19SJiang Yutang #define CONFIG_SYS_PCIE3_MEM_BUS 0x80000000 3429899ac19SJiang Yutang #define CONFIG_SYS_PCIE3_MEM_PHYS 0x80000000 3439899ac19SJiang Yutang #endif 344c59e1b4dSTimur Tabi #define CONFIG_SYS_PCIE3_MEM_SIZE 0x20000000 /* 512M */ 345c59e1b4dSTimur Tabi #define CONFIG_SYS_PCIE3_IO_VIRT 0xffc00000 346c59e1b4dSTimur Tabi #define CONFIG_SYS_PCIE3_IO_BUS 0x00000000 3479899ac19SJiang Yutang #ifdef CONFIG_PHYS_64BIT 348c59e1b4dSTimur Tabi #define CONFIG_SYS_PCIE3_IO_PHYS 0xfffc00000ull 3499899ac19SJiang Yutang #else 3509899ac19SJiang Yutang #define CONFIG_SYS_PCIE3_IO_PHYS 0xffc00000 3519899ac19SJiang Yutang #endif 352c59e1b4dSTimur Tabi #define CONFIG_SYS_PCIE3_IO_SIZE 0x00010000 /* 64k */ 353c59e1b4dSTimur Tabi 354c59e1b4dSTimur Tabi #ifdef CONFIG_PCI 355c59e1b4dSTimur Tabi #define CONFIG_PCI_PNP /* do pci plug-and-play */ 356c59e1b4dSTimur Tabi #define CONFIG_PCI_SCAN_SHOW /* show pci devices on startup */ 35716855ec1SKumar Gala #define CONFIG_E1000 /* Define e1000 pci Ethernet card */ 358c59e1b4dSTimur Tabi #endif 359c59e1b4dSTimur Tabi 360c59e1b4dSTimur Tabi /* SATA */ 361c59e1b4dSTimur Tabi #define CONFIG_LIBATA 362c59e1b4dSTimur Tabi #define CONFIG_FSL_SATA 363c59e1b4dSTimur Tabi 364c59e1b4dSTimur Tabi #define CONFIG_SYS_SATA_MAX_DEVICE 2 365c59e1b4dSTimur Tabi #define CONFIG_SATA1 366c59e1b4dSTimur Tabi #define CONFIG_SYS_SATA1 CONFIG_SYS_MPC85xx_SATA1_ADDR 367c59e1b4dSTimur Tabi #define CONFIG_SYS_SATA1_FLAGS FLAGS_DMA 368c59e1b4dSTimur Tabi #define CONFIG_SATA2 369c59e1b4dSTimur Tabi #define CONFIG_SYS_SATA2 CONFIG_SYS_MPC85xx_SATA2_ADDR 370c59e1b4dSTimur Tabi #define CONFIG_SYS_SATA2_FLAGS FLAGS_DMA 371c59e1b4dSTimur Tabi 372c59e1b4dSTimur Tabi #ifdef CONFIG_FSL_SATA 373c59e1b4dSTimur Tabi #define CONFIG_LBA48 374c59e1b4dSTimur Tabi #define CONFIG_CMD_SATA 375c59e1b4dSTimur Tabi #define CONFIG_DOS_PARTITION 376c59e1b4dSTimur Tabi #define CONFIG_CMD_EXT2 377c59e1b4dSTimur Tabi #endif 378c59e1b4dSTimur Tabi 379c59e1b4dSTimur Tabi #define CONFIG_MMC 380c59e1b4dSTimur Tabi #ifdef CONFIG_MMC 381c59e1b4dSTimur Tabi #define CONFIG_CMD_MMC 382c59e1b4dSTimur Tabi #define CONFIG_FSL_ESDHC 383c59e1b4dSTimur Tabi #define CONFIG_GENERIC_MMC 384c59e1b4dSTimur Tabi #define CONFIG_SYS_FSL_ESDHC_ADDR CONFIG_SYS_MPC85xx_ESDHC_ADDR 385c59e1b4dSTimur Tabi #endif 386c59e1b4dSTimur Tabi 387c59e1b4dSTimur Tabi #if defined(CONFIG_MMC) || defined(CONFIG_USB_EHCI) 388c59e1b4dSTimur Tabi #define CONFIG_CMD_EXT2 389c59e1b4dSTimur Tabi #define CONFIG_CMD_FAT 390c59e1b4dSTimur Tabi #define CONFIG_DOS_PARTITION 391c59e1b4dSTimur Tabi #endif 392c59e1b4dSTimur Tabi 393c59e1b4dSTimur Tabi #define CONFIG_TSEC_ENET 394c59e1b4dSTimur Tabi #ifdef CONFIG_TSEC_ENET 395c59e1b4dSTimur Tabi 396c59e1b4dSTimur Tabi #define CONFIG_TSECV2 397c59e1b4dSTimur Tabi 398c59e1b4dSTimur Tabi #define CONFIG_MII /* MII PHY management */ 399c59e1b4dSTimur Tabi #define CONFIG_TSEC1 1 400c59e1b4dSTimur Tabi #define CONFIG_TSEC1_NAME "eTSEC1" 401c59e1b4dSTimur Tabi #define CONFIG_TSEC2 1 402c59e1b4dSTimur Tabi #define CONFIG_TSEC2_NAME "eTSEC2" 403c59e1b4dSTimur Tabi 404c59e1b4dSTimur Tabi #define TSEC1_PHY_ADDR 1 405c59e1b4dSTimur Tabi #define TSEC2_PHY_ADDR 2 406c59e1b4dSTimur Tabi 407c59e1b4dSTimur Tabi #define TSEC1_FLAGS (TSEC_GIGABIT | TSEC_REDUCED) 408c59e1b4dSTimur Tabi #define TSEC2_FLAGS (TSEC_GIGABIT | TSEC_REDUCED) 409c59e1b4dSTimur Tabi 410c59e1b4dSTimur Tabi #define TSEC1_PHYIDX 0 411c59e1b4dSTimur Tabi #define TSEC2_PHYIDX 0 412c59e1b4dSTimur Tabi 413c59e1b4dSTimur Tabi #define CONFIG_ETHPRIME "eTSEC1" 414c59e1b4dSTimur Tabi 415c59e1b4dSTimur Tabi #define CONFIG_PHY_GIGE /* Include GbE speed/duplex detection */ 416c59e1b4dSTimur Tabi #endif 417c59e1b4dSTimur Tabi 418c59e1b4dSTimur Tabi /* 419c59e1b4dSTimur Tabi * Environment 420c59e1b4dSTimur Tabi */ 421*af253608SMatthew McClintock #ifdef CONFIG_SYS_RAMBOOT 422*af253608SMatthew McClintock #ifdef CONFIG_RAMBOOT_SPIFLASH 423*af253608SMatthew McClintock #define CONFIG_ENV_IS_IN_SPI_FLASH 424*af253608SMatthew McClintock #define CONFIG_ENV_SPI_BUS 0 425*af253608SMatthew McClintock #define CONFIG_ENV_SPI_CS 0 426*af253608SMatthew McClintock #define CONFIG_ENV_SPI_MAX_HZ 10000000 427*af253608SMatthew McClintock #define CONFIG_ENV_SPI_MODE 0 428*af253608SMatthew McClintock #define CONFIG_ENV_SIZE 0x2000 /* 8KB */ 429*af253608SMatthew McClintock #define CONFIG_ENV_OFFSET 0x100000 /* 1MB */ 430*af253608SMatthew McClintock #define CONFIG_ENV_SECT_SIZE 0x10000 431*af253608SMatthew McClintock #elif defined(CONFIG_RAMBOOT_SDCARD) 432*af253608SMatthew McClintock #define CONFIG_ENV_IS_IN_MMC 433c59e1b4dSTimur Tabi #define CONFIG_ENV_SIZE 0x2000 434*af253608SMatthew McClintock #define CONFIG_SYS_MMC_ENV_DEV 0 435*af253608SMatthew McClintock #elif defined(CONFIG_NAND_U_BOOT) 436*af253608SMatthew McClintock #define CONFIG_ENV_IS_IN_NAND 437*af253608SMatthew McClintock #define CONFIG_ENV_SIZE CONFIG_SYS_NAND_BLOCK_SIZE 438*af253608SMatthew McClintock #define CONFIG_ENV_OFFSET ((512 * 1024) + CONFIG_SYS_NAND_BLOCK_SIZE) 439*af253608SMatthew McClintock #define CONFIG_ENV_RANGE (3 * CONFIG_ENV_SIZE) 440*af253608SMatthew McClintock #else 441*af253608SMatthew McClintock #define CONFIG_ENV_IS_NOWHERE /* Store ENV in memory only */ 442*af253608SMatthew McClintock #define CONFIG_ENV_ADDR (CONFIG_SYS_MONITOR_BASE - 0x1000) 443*af253608SMatthew McClintock #define CONFIG_ENV_SIZE 0x2000 444*af253608SMatthew McClintock #endif 445*af253608SMatthew McClintock #else 446*af253608SMatthew McClintock #define CONFIG_ENV_IS_IN_FLASH 447*af253608SMatthew McClintock #if CONFIG_SYS_MONITOR_BASE > 0xfff80000 448*af253608SMatthew McClintock #define CONFIG_ENV_ADDR 0xfff80000 449*af253608SMatthew McClintock #else 450*af253608SMatthew McClintock #define CONFIG_ENV_ADDR (CONFIG_SYS_MONITOR_BASE - CONFIG_ENV_SECT_SIZE) 451*af253608SMatthew McClintock #endif 452*af253608SMatthew McClintock #define CONFIG_ENV_SIZE 0x2000 453*af253608SMatthew McClintock #define CONFIG_ENV_SECT_SIZE 0x20000 /* 128K (one sector) */ 454*af253608SMatthew McClintock #endif 455c59e1b4dSTimur Tabi 456c59e1b4dSTimur Tabi #define CONFIG_LOADS_ECHO 457c59e1b4dSTimur Tabi #define CONFIG_SYS_LOADS_BAUD_CHANGE 458c59e1b4dSTimur Tabi 459c59e1b4dSTimur Tabi /* 460c59e1b4dSTimur Tabi * Command line configuration. 461c59e1b4dSTimur Tabi */ 462c59e1b4dSTimur Tabi #include <config_cmd_default.h> 463c59e1b4dSTimur Tabi 46479ee3448SKumar Gala #define CONFIG_CMD_ELF 46579ee3448SKumar Gala #define CONFIG_CMD_ERRATA 466c59e1b4dSTimur Tabi #define CONFIG_CMD_IRQ 467c59e1b4dSTimur Tabi #define CONFIG_CMD_I2C 468c59e1b4dSTimur Tabi #define CONFIG_CMD_MII 46979ee3448SKumar Gala #define CONFIG_CMD_PING 470c59e1b4dSTimur Tabi #define CONFIG_CMD_SETEXPR 471b8339e2bSMatthew McClintock #define CONFIG_CMD_REGINFO 472c59e1b4dSTimur Tabi 473c59e1b4dSTimur Tabi #ifdef CONFIG_PCI 474c59e1b4dSTimur Tabi #define CONFIG_CMD_PCI 475c59e1b4dSTimur Tabi #define CONFIG_CMD_NET 476c59e1b4dSTimur Tabi #endif 477c59e1b4dSTimur Tabi 478c59e1b4dSTimur Tabi /* 479c59e1b4dSTimur Tabi * USB 480c59e1b4dSTimur Tabi */ 4813d7506faSramneek mehresh #define CONFIG_HAS_FSL_DR_USB 4823d7506faSramneek mehresh #ifdef CONFIG_HAS_FSL_DR_USB 483c59e1b4dSTimur Tabi #define CONFIG_USB_EHCI 484c59e1b4dSTimur Tabi 485c59e1b4dSTimur Tabi #ifdef CONFIG_USB_EHCI 486c59e1b4dSTimur Tabi #define CONFIG_CMD_USB 487c59e1b4dSTimur Tabi #define CONFIG_EHCI_HCD_INIT_AFTER_RESET 488c59e1b4dSTimur Tabi #define CONFIG_USB_EHCI_FSL 489c59e1b4dSTimur Tabi #define CONFIG_USB_STORAGE 490c59e1b4dSTimur Tabi #define CONFIG_CMD_FAT 491c59e1b4dSTimur Tabi #endif 4923d7506faSramneek mehresh #endif 493c59e1b4dSTimur Tabi 494c59e1b4dSTimur Tabi /* 495c59e1b4dSTimur Tabi * Miscellaneous configurable options 496c59e1b4dSTimur Tabi */ 497c59e1b4dSTimur Tabi #define CONFIG_SYS_LONGHELP /* undef to save memory */ 498c59e1b4dSTimur Tabi #define CONFIG_CMDLINE_EDITING /* Command-line editing */ 4995be58f5fSKim Phillips #define CONFIG_AUTO_COMPLETE /* add autocompletion support */ 500c59e1b4dSTimur Tabi #define CONFIG_SYS_LOAD_ADDR 0x2000000 /* default load address */ 501c59e1b4dSTimur Tabi #define CONFIG_SYS_PROMPT "=> " /* Monitor Command Prompt */ 502c59e1b4dSTimur Tabi #ifdef CONFIG_CMD_KGDB 503c59e1b4dSTimur Tabi #define CONFIG_SYS_CBSIZE 1024 /* Console I/O Buffer Size */ 504c59e1b4dSTimur Tabi #else 505c59e1b4dSTimur Tabi #define CONFIG_SYS_CBSIZE 256 /* Console I/O Buffer Size */ 506c59e1b4dSTimur Tabi #endif 507c59e1b4dSTimur Tabi /* Print Buffer Size */ 508c59e1b4dSTimur Tabi #define CONFIG_SYS_PBSIZE (CONFIG_SYS_CBSIZE + sizeof(CONFIG_SYS_PROMPT) + 16) 509c59e1b4dSTimur Tabi #define CONFIG_SYS_MAXARGS 16 510c59e1b4dSTimur Tabi #define CONFIG_SYS_BARGSIZE CONFIG_SYS_CBSIZE 511c59e1b4dSTimur Tabi #define CONFIG_SYS_HZ 1000 512c59e1b4dSTimur Tabi 513c59e1b4dSTimur Tabi /* 514c59e1b4dSTimur Tabi * For booting Linux, the board info and command line data 515a832ac41SKumar Gala * have to be in the first 64 MB of memory, since this is 516c59e1b4dSTimur Tabi * the maximum mapped by the Linux kernel during initialization. 517c59e1b4dSTimur Tabi */ 518a832ac41SKumar Gala #define CONFIG_SYS_BOOTMAPSZ (64 << 20) /* Initial Memory map for Linux*/ 519a832ac41SKumar Gala #define CONFIG_SYS_BOOTM_LEN (64 << 20) /* Increase max gunzip size */ 520c59e1b4dSTimur Tabi 521c59e1b4dSTimur Tabi #ifdef CONFIG_CMD_KGDB 522c59e1b4dSTimur Tabi #define CONFIG_KGDB_BAUDRATE 230400 /* speed to run kgdb serial port */ 523c59e1b4dSTimur Tabi #define CONFIG_KGDB_SER_INDEX 2 /* which serial port to use */ 524c59e1b4dSTimur Tabi #endif 525c59e1b4dSTimur Tabi 526c59e1b4dSTimur Tabi /* 527c59e1b4dSTimur Tabi * Environment Configuration 528c59e1b4dSTimur Tabi */ 529c59e1b4dSTimur Tabi 530c59e1b4dSTimur Tabi #define CONFIG_HOSTNAME p1022ds 5318b3637c6SJoe Hershberger #define CONFIG_ROOTPATH "/opt/nfsroot" 532b3f44c21SJoe Hershberger #define CONFIG_BOOTFILE "uImage" 533c59e1b4dSTimur Tabi #define CONFIG_UBOOTPATH u-boot.bin /* U-Boot image on TFTP server */ 534c59e1b4dSTimur Tabi 535c59e1b4dSTimur Tabi #define CONFIG_LOADADDR 1000000 536c59e1b4dSTimur Tabi 537c59e1b4dSTimur Tabi #define CONFIG_BOOTDELAY 10 /* -1 disables auto-boot */ 538c59e1b4dSTimur Tabi 539c59e1b4dSTimur Tabi #define CONFIG_BAUDRATE 115200 540c59e1b4dSTimur Tabi 541c59e1b4dSTimur Tabi #define CONFIG_EXTRA_ENV_SETTINGS \ 542c59e1b4dSTimur Tabi "netdev=eth0\0" \ 543c59e1b4dSTimur Tabi "uboot=" MK_STR(CONFIG_UBOOTPATH) "\0" \ 54484e34b65STimur Tabi "ubootaddr=" MK_STR(CONFIG_SYS_TEXT_BASE) "\0" \ 54584e34b65STimur Tabi "tftpflash=tftpboot $loadaddr $uboot && " \ 54684e34b65STimur Tabi "protect off $ubootaddr +$filesize && " \ 54784e34b65STimur Tabi "erase $ubootaddr +$filesize && " \ 54884e34b65STimur Tabi "cp.b $loadaddr $ubootaddr $filesize && " \ 54984e34b65STimur Tabi "protect on $ubootaddr +$filesize && " \ 55084e34b65STimur Tabi "cmp.b $loadaddr $ubootaddr $filesize\0" \ 551c59e1b4dSTimur Tabi "consoledev=ttyS0\0" \ 552c59e1b4dSTimur Tabi "ramdiskaddr=2000000\0" \ 55384e34b65STimur Tabi "ramdiskfile=rootfs.ext2.gz.uboot\0" \ 554c59e1b4dSTimur Tabi "fdtaddr=c00000\0" \ 555c59e1b4dSTimur Tabi "fdtfile=p1022ds.dtb\0" \ 556c59e1b4dSTimur Tabi "bdev=sda3\0" \ 557ba8e76bdSTimur Tabi "hwconfig=esdhc;audclk:12\0" 558c59e1b4dSTimur Tabi 559c59e1b4dSTimur Tabi #define CONFIG_HDBOOT \ 560c59e1b4dSTimur Tabi "setenv bootargs root=/dev/$bdev rw " \ 56184e34b65STimur Tabi "console=$consoledev,$baudrate $othbootargs $videobootargs;" \ 562c59e1b4dSTimur Tabi "tftp $loadaddr $bootfile;" \ 563c59e1b4dSTimur Tabi "tftp $fdtaddr $fdtfile;" \ 564c59e1b4dSTimur Tabi "bootm $loadaddr - $fdtaddr" 565c59e1b4dSTimur Tabi 566c59e1b4dSTimur Tabi #define CONFIG_NFSBOOTCOMMAND \ 567c59e1b4dSTimur Tabi "setenv bootargs root=/dev/nfs rw " \ 568c59e1b4dSTimur Tabi "nfsroot=$serverip:$rootpath " \ 569c59e1b4dSTimur Tabi "ip=$ipaddr:$serverip:$gatewayip:$netmask:$hostname:$netdev:off " \ 57084e34b65STimur Tabi "console=$consoledev,$baudrate $othbootargs $videobootargs;" \ 571c59e1b4dSTimur Tabi "tftp $loadaddr $bootfile;" \ 572c59e1b4dSTimur Tabi "tftp $fdtaddr $fdtfile;" \ 573c59e1b4dSTimur Tabi "bootm $loadaddr - $fdtaddr" 574c59e1b4dSTimur Tabi 575c59e1b4dSTimur Tabi #define CONFIG_RAMBOOTCOMMAND \ 576c59e1b4dSTimur Tabi "setenv bootargs root=/dev/ram rw " \ 57784e34b65STimur Tabi "console=$consoledev,$baudrate $othbootargs $videobootargs;" \ 578c59e1b4dSTimur Tabi "tftp $ramdiskaddr $ramdiskfile;" \ 579c59e1b4dSTimur Tabi "tftp $loadaddr $bootfile;" \ 580c59e1b4dSTimur Tabi "tftp $fdtaddr $fdtfile;" \ 581c59e1b4dSTimur Tabi "bootm $loadaddr $ramdiskaddr $fdtaddr" 582c59e1b4dSTimur Tabi 583c59e1b4dSTimur Tabi #define CONFIG_BOOTCOMMAND CONFIG_RAMBOOTCOMMAND 584c59e1b4dSTimur Tabi 585c59e1b4dSTimur Tabi #endif 586