/* * include/configs/spc300_arch.h * * Copyright (C) 2009 SPiDCOM Technologies * * This program is free software; you can redistribute it and/or * modify it under the terms of the GNU General Public License as * published by the Free Software Foundation; either version 2 of * the License, or (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, * MA 02111-1307 USA */ #ifndef __CONFIG_SPC300_ARCH_H #define __CONFIG_SPC300_ARCH_H #define CONFIG_ARCH_SPC300 1 #if defined (CONFIG_CHIP_SPC300) # define CONFIG_CHIP_FEATURE_SYNOP3504 1 # define CONFIG_CHIP_FEATURE_SYNC_DSP_CLOCK 1 # define CONFIG_CHIP_MAX_MASTER_CLOCK 147000000 #else # error "undefined chip" #endif #include /* * U-BOOT PARAMETERS */ /* * If we are developing, we might want to start armboot from ram * so we MUST NOT initialize critical regs like mem-timing ... * use only if CONFIG_EXEC_FROM_SDRAM = false */ #undef CONFIG_SKIP_LOWLEVEL_INIT /* Allow u-boot to start directly from SDRAM (no init) */ #define CONFIG_EXEC_FROM_SDRAM 1 /* Define U-Boot max size for flash protect */ #define CFG_BOOT_SIZE 0x30000 #undef CFG_U_BOOT_BASE #undef CFG_U_BOOT_SIZE /* Allow verbose help for commands */ #define CFG_LONGHELP 1 /* Monitor command prompt */ #define CFG_PROMPT "SPC300-Boot> " /* Console I/O Buffer Size */ #define CFG_CBSIZE 256 /* Max number of command args */ #define CFG_MAXARGS 16 /* Print Buffer Size */ #define CFG_PBSIZE (CFG_CBSIZE+sizeof(CFG_PROMPT)+16) /* Regular stack */ #define CONFIG_STACKSIZE (64*1024) /* Disable IRQ using */ #undef CONFIG_USE_IRQ #ifdef CONFIG_USE_IRQ #error CONFIG_USE_IRQ not supported #endif /* Use TAGs to start Linux with correct parameters */ #define CONFIG_CMDLINE_TAG 1 #define CONFIG_SETUP_MEMORY_TAGS 1 #define CONFIG_SPC300_TAG 1 /* Disable overwriting serial and ethaddr */ #undef CONFIG_ENV_OVERWRITE #define CONFIG_OVERWRITE_ETHADDR_ONCE 1 /* Environnement parameters are embedded */ #undef CFG_ENV_IS_IN_FLASH #define CFG_ENV_IS_NOWHERE 1 #define CFG_ENV_IS_EMBEDDED 1 #define CFG_ENV_SIZE 0x500 /* Size of malloc() pool */ #define CFG_MALLOC_LEN (128*1024) /* Size in bytes reserved for initial data */ #define CFG_GBL_DATA_SIZE 128 /* Allow late init function */ #define BOARD_LATE_INIT 1 /* Automatic boot command */ #define CONFIG_BOOTCOMMAND "spidboot" /* Time in second before starting automatic boot command */ #define CONFIG_BOOTDELAY 0 #define CONFIG_ZERO_BOOTDELAY_CHECK 1 /* Boot parameters given to Linux */ #define CONFIG_BOOTARGS "console=ttyS0,115200" /* Allow the following commands */ #define CONFIG_COMMANDS \ ( (CONFIG_CMD_DFL | \ CFG_CMD_PING | \ CFG_CMD_MMUON | \ CFG_CMD_SPIDUPD | \ CFG_CMD_SPIDBOOT | \ CFG_CMD_CACHE | \ CFG_CMD_MII | \ CFG_CMD_NET) & \ ~( CFG_CMD_SETGETDCR | \ CFG_CMD_FPGA | \ CFG_CMD_ENV | \ CFG_CMD_ITEST | \ CFG_CMD_XIMG ) ) /* this must be included AFTER the definition of CONFIG_COMMANDS (if any) */ #include /* * CLOCK PARAMETERS */ /* ((MARIA_TIMER_CLOCK==Xclk) max) / timer_prescaler */ #define CFG_HZ (3125000) /* Timer clock in HZ */ /* * UARTS PARAMETERS */ /* Define one of these to choose the USART0 or USART1 as console */ #define CONFIG_USART0 1 /* Set default baudrate */ #define CONFIG_BAUDRATE 115200 #define CFG_BAUDRATE_TABLE {115200 , 19200, 38400, 57600, 9600 } /* Don't include RTS/CTS flow control support */ #undef CONFIG_HWFLOW /* Disable modem initialization stuff */ #undef CONFIG_MODEM_SUPPORT /* Eat the first char if it is a break (to avoid randomly generated * break) */ #define CONFIG_EAT_FIRST_BREAK /* * SDRAM PARAMETERS */ /* Number of SDRAM chips (always 1) */ #define CONFIG_NR_DRAM_BANKS 1 /* SDRAM Base Address */ #define PHYS_SDRAM 0x40000000 /* Memory tests configuration */ #define CFG_MEMTEST_START (PHYS_SDRAM + 0x00000000) #define CFG_MEMTEST_END (PHYS_SDRAM + 0x005FFFFF) #define CFG_MEMTEST_SCRATCH (CFG_MEMTEST_START + 0x01000000 - 4) /*Assume that SDRAM size = 16M*/ #define CFG_ALT_MEMTEST 1 /* Default address to start a script */ #define CFG_LOAD_ADDR 0x40100000 /* * FLASH PARAMETERS */ #undef CFG_NO_FLASH /* SPI Flash configuration */ #define CFG_MAX_FLASH_BANKS 1 #define PHYS_FLASH_SPI_1 0x30000000 #define FLASH_SPI_AREA 0x0FFFFFFF #define CFG_MAX_FLASH_SECT 256 #define CFG_FLASH_PROTECTION 1 /* Timeout for Flash Erase */ #define CFG_FLASH_SPI_ERASE_TOUT (20*CFG_HZ) /* Timeout for Flash Write */ #define CFG_FLASH_SPI_WRITE_TOUT (20*CFG_HZ) /* SPI Controller Address */ #define CFG_FLASH_SPI_BASE 0xF0000000 /* Timeout for SPI controller */ #define SPI_CTL_TMO (30*CFG_HZ) /* * ETHERNET PARAMETERS */ /* Enable SPC Ethernet MAC driver */ #define CONFIG_MII 1 #define CONFIG_DRIVER_NETSPCMAC 1 #define CONFIG_SPCMAC_ADDRESS ETHERNET_CTRL_BASE /* IP layer configuration */ #define CONFIG_ETHADDR 00:13:D7:00:10:01 #define CONFIG_SERVERIP 010.003.000.211 #define CONFIG_IPADDR 010.003.000.001 #define CONFIG_NETMASK 255.255.000.000 #define CONFIG_GATEWAYIP 010.003.000.211 #define CONFIG_HOSTNAME spc300 #define CONFIG_BOOTFILE "linux-kernel-2.6.25.10-arm" /* * OTHER IPs PARAMETERS */ #undef CONFIG_LCD #endif