sbc8548.h

来自「最新版的u-boot,2008-10-18发布」· C头文件 代码 · 共 577 行 · 第 1/2 页

H
577
字号
/* * Copyright 2007 Wind River Systems <www.windriver.com> * Copyright 2007 Embedded Specialties, Inc. * Copyright 2004, 2007 Freescale Semiconductor. * * See file CREDITS for list of people who contributed to this * project. * * 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 *//* * sbc8548 board configuration file * * Please refer to doc/README.sbc85xx for more info. * */#ifndef __CONFIG_H#define __CONFIG_H/* High Level Configuration Options */#define CONFIG_BOOKE		1	/* BOOKE */#define CONFIG_E500		1	/* BOOKE e500 family */#define CONFIG_MPC85xx		1	/* MPC8540/60/55/41/48 */#define CONFIG_MPC8548		1	/* MPC8548 specific */#define CONFIG_SBC8548		1	/* SBC8548 board specific */#undef CONFIG_PCI		/* enable any pci type devices */#undef CONFIG_PCI1		/* PCI controller 1 */#undef CONFIG_PCIE1		/* PCIE controler 1 (slot 1) */#undef CONFIG_RIO#undef CONFIG_PCI2#undef CONFIG_FSL_PCI_INIT		/* Use common FSL init code */#define CONFIG_TSEC_ENET		/* tsec ethernet support */#define CONFIG_ENV_OVERWRITE#define CONFIG_INTERRUPTS		/* enable pci, srio, ddr interrupts */#define CONFIG_FSL_LAW		1	/* Use common FSL init code */#define CONFIG_SYS_CLK_FREQ	66000000 /* SBC8548 default SYSCLK *//* * These can be toggled for performance analysis, otherwise use default. */#define CONFIG_L2_CACHE			/* toggle L2 cache */#define CONFIG_BTB			/* toggle branch predition */#define CONFIG_ADDR_STREAMING		/* toggle addr streaming */#define CONFIG_CLEAR_LAW0		/* Clear LAW0 in cpu_init_r *//* * Only possible on E500 Version 2 or newer cores. */#define CONFIG_ENABLE_36BIT_PHYS	1#define CONFIG_BOARD_EARLY_INIT_F	1	/* Call board_pre_init */#undef	CFG_DRAM_TEST			/* memory test, takes time */#define CFG_MEMTEST_START	0x00200000	/* memtest works on */#define CFG_MEMTEST_END		0x00400000/* * Base addresses -- Note these are effective addresses where the * actual resources get mapped (not physical addresses) */#define CFG_CCSRBAR_DEFAULT	0xff700000	/* CCSRBAR Default */#define CFG_CCSRBAR		0xe0000000	/* relocated CCSRBAR */#define CFG_CCSRBAR_PHYS	CFG_CCSRBAR	/* physical addr of CCSRBAR */#define CFG_IMMR		CFG_CCSRBAR	/* PQII uses CFG_IMMR */#define CFG_PCI1_ADDR	(CFG_CCSRBAR+0x8000)#define CFG_PCI2_ADDR	(CFG_CCSRBAR+0x9000)#define CFG_PCIE1_ADDR	(CFG_CCSRBAR+0xa000)/* DDR Setup */#define CONFIG_FSL_DDR2#undef CONFIG_FSL_DDR_INTERACTIVE#undef CONFIG_SPD_EEPROM		/* Use SPD EEPROM for DDR setup */#undef CONFIG_DDR_SPD#undef CONFIG_DDR_ECC			/* only for ECC DDR module */#define CONFIG_ECC_INIT_VIA_DDRCONTROLLER	/* DDR controller or DMA? */#define CONFIG_MEM_INIT_VALUE	0xDeadBeef#define CFG_DDR_SDRAM_BASE	0x00000000#define CFG_SDRAM_BASE		CFG_DDR_SDRAM_BASE#define CONFIG_VERY_BIG_RAM#define CONFIG_NUM_DDR_CONTROLLERS	1#define CONFIG_DIMM_SLOTS_PER_CTLR	1#define CONFIG_CHIP_SELECTS_PER_CTRL	2/* I2C addresses of SPD EEPROMs */#define SPD_EEPROM_ADDRESS	0x51	/* CTLR 0 DIMM 0 *//* * Make sure required options are set */#ifndef CONFIG_SPD_EEPROM	#define CFG_SDRAM_SIZE	256		/* DDR is 256MB */#endif#undef CONFIG_CLOCKS_IN_MHZ/* * FLASH on the Local Bus * Two banks, one 8MB the other 64MB, using the CFI driver. * Boot from BR0/OR0 bank at 0xff80_0000 * Alternate BR6/OR6 bank at 0xfb80_0000 * * BR0: *    Base address 0 = 0xff80_0000 = BR0[0:16] = 1111 1111 1000 0000 0 *    Port Size = 8 bits = BRx[19:20] = 01 *    Use GPCM = BRx[24:26] = 000 *    Valid = BRx[31] = 1 * * 0    4    8    12   16   20   24   28 * 1111 1111 1000 0000 0000 1000 0000 0001 = ff800801    BR0 * * BR6: *    Base address 6 = 0xfb80_0000 = BR6[0:16] = 1111 1011 1000 0000 0 *    Port Size = 32 bits = BRx[19:20] = 11 *    Use GPCM = BRx[24:26] = 000 *    Valid = BRx[31] = 1 * * 0    4    8    12   16   20   24   28 * 1111 1011 1000 0000 0001 1000 0000 0001 = fb801801    BR6 * * OR0: *    Addr Mask = 8M = OR1[0:16] = 1111 1111 1000 0000 0 *    XAM = OR0[17:18] = 11 *    CSNT = OR0[20] = 1 *    ACS = half cycle delay = OR0[21:22] = 11 *    SCY = 6 = OR0[24:27] = 0110 *    TRLX = use relaxed timing = OR0[29] = 1 *    EAD = use external address latch delay = OR0[31] = 1 * * 0    4    8    12   16   20   24   28 * 1111 1111 1000 0000 0110 1110 0110 0101 = ff806e65    OR0 * * OR6: *    Addr Mask = 64M = OR6[0:16] = 1111 1000 0000 0000 0 *    XAM = OR6[17:18] = 11 *    CSNT = OR6[20] = 1 *    ACS = half cycle delay = OR6[21:22] = 11 *    SCY = 6 = OR6[24:27] = 0110 *    TRLX = use relaxed timing = OR6[29] = 1 *    EAD = use external address latch delay = OR6[31] = 1 * * 0    4    8    12   16   20   24   28 * 1111 1000 0000 0000 0110 1110 0110 0101 = f8006e65    OR6 */#define CFG_BOOT_BLOCK		0xff800000	/* start of 8MB Flash */#define CFG_FLASH_BASE		CFG_BOOT_BLOCK	/* start of FLASH 16M */#define CFG_BR0_PRELIM		0xff800801#define CFG_BR6_PRELIM		0xfb801801#define	CFG_OR0_PRELIM		0xff806e65#define	CFG_OR6_PRELIM		0xf8006e65#define CFG_FLASH_BANKS_LIST	{CFG_FLASH_BASE}#define CFG_MAX_FLASH_BANKS	1		/* number of banks */#define CFG_MAX_FLASH_SECT	128		/* sectors per device */#undef	CFG_FLASH_CHECKSUM#define CFG_FLASH_ERASE_TOUT	60000	/* Flash Erase Timeout (ms) */#define CFG_FLASH_WRITE_TOUT	500	/* Flash Write Timeout (ms) */#define CFG_MONITOR_BASE	TEXT_BASE	/* start of monitor */#define CONFIG_FLASH_CFI_DRIVER#define CFG_FLASH_CFI#define CFG_FLASH_EMPTY_INFO/* CS5 = Local bus peripherals controlled by the EPLD */#define CFG_BR5_PRELIM		0xf8000801#define CFG_OR5_PRELIM		0xff006e65#define CFG_EPLD_BASE		0xf8000000#define CFG_LED_DISP_BASE	0xf8000000#define CFG_USER_SWITCHES_BASE	0xf8100000#define CFG_BD_REV		0xf8300000#define CFG_EEPROM_BASE		0xf8b00000/* * SDRAM on the Local Bus */#define CFG_LBC_SDRAM_BASE	0xf0000000	/* Localbus SDRAM */#define CFG_LBC_SDRAM_SIZE	64		/* LBC SDRAM is 64MB *//* * Base Register 3 and Option Register 3 configure SDRAM. * The SDRAM base address, CFG_LBC_SDRAM_BASE, is 0xf0000000. * * For BR3, need: *    Base address of 0xf0000000 = BR[0:16] = 1111 0000 0000 0000 0 *    port-size = 32-bits = BR2[19:20] = 11 *    no parity checking = BR2[21:22] = 00 *    SDRAM for MSEL = BR2[24:26] = 011 *    Valid = BR[31] = 1 * * 0    4    8    12   16   20   24   28 * 1111 0000 0000 0000 0001 1000 0110 0001 = f0001861 * */#define CFG_BR3_PRELIM		0xf0001861/* * The SDRAM size in MB, CFG_LBC_SDRAM_SIZE, is 64. * * For OR3, need: *    64MB mask for AM, OR3[0:7] = 1111 1100 *		   XAM, OR3[17:18] = 11 *    10 columns OR3[19-21] = 011 *    12 rows   OR3[23-25] = 011 *    EAD set for extra time OR[31] = 0 * * 0    4    8    12   16   20   24   28 * 1111 1100 0000 0000 0110 1100 1100 0000 = fc006cc0 */#define CFG_OR3_PRELIM		0xfc006cc0#define CFG_LBC_LCRR		0x00000002    /* LB clock ratio reg */#define CFG_LBC_LBCR		0x00000000    /* LB config reg */#define CFG_LBC_LSRT		0x20000000  /* LB sdram refresh timer */#define CFG_LBC_MRTPR		0x00000000  /* LB refresh timer prescal*//* * LSDMR masks */#define CFG_LBC_LSDMR_RFEN	(1 << (31 -  1))#define CFG_LBC_LSDMR_BSMA1516	(3 << (31 - 10))#define CFG_LBC_LSDMR_BSMA1617	(4 << (31 - 10))#define CFG_LBC_LSDMR_RFCR16	(7 << (31 - 16))#define CFG_LBC_LSDMR_PRETOACT7	(7 << (31 - 19))#define CFG_LBC_LSDMR_ACTTORW7	(7 << (31 - 22))#define CFG_LBC_LSDMR_ACTTORW6	(6 << (31 - 22))#define CFG_LBC_LSDMR_BL8	(1 << (31 - 23))#define CFG_LBC_LSDMR_WRC4	(0 << (31 - 27))#define CFG_LBC_LSDMR_CL3	(3 << (31 - 31))#define CFG_LBC_LSDMR_OP_NORMAL	(0 << (31 - 4))#define CFG_LBC_LSDMR_OP_ARFRSH	(1 << (31 - 4))#define CFG_LBC_LSDMR_OP_SRFRSH	(2 << (31 - 4))#define CFG_LBC_LSDMR_OP_MRW	(3 << (31 - 4))#define CFG_LBC_LSDMR_OP_PRECH	(4 << (31 - 4))#define CFG_LBC_LSDMR_OP_PCHALL	(5 << (31 - 4))#define CFG_LBC_LSDMR_OP_ACTBNK	(6 << (31 - 4))#define CFG_LBC_LSDMR_OP_RWINV	(7 << (31 - 4))/* * Common settings for all Local Bus SDRAM commands. * At run time, either BSMA1516 (for CPU 1.1) *                  or BSMA1617 (for CPU 1.0) (old) * is OR'ed in too. */#define CFG_LBC_LSDMR_COMMON	( CFG_LBC_LSDMR_RFCR16		\				| CFG_LBC_LSDMR_PRETOACT7	\				| CFG_LBC_LSDMR_ACTTORW7	\				| CFG_LBC_LSDMR_BL8		\				| CFG_LBC_LSDMR_WRC4		\				| CFG_LBC_LSDMR_CL3		\				| CFG_LBC_LSDMR_RFEN		\				)#define CONFIG_L1_INIT_RAM#define CFG_INIT_RAM_LOCK	1#define CFG_INIT_RAM_ADDR	0xe4010000	/* Initial RAM address */#define CFG_INIT_RAM_END	0x4000		/* End of used area in RAM */#define CFG_INIT_L2_ADDR	0xf8f80000	/* relocate boot L2SRAM */

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?