From 76d4ae251e4a2f7724f4462baccc2779074fa937 Mon Sep 17 00:00:00 2001 From: Vasily Khoruzhick Date: Fri, 13 Jan 2012 10:11:44 +0300 Subject: zipitz2: fix boot issue introduced by PXA low level init rework CONFIG_SYS_INIT_SP_ADDR points to RAM, but it's used before DRAM controller init. Fix it by setting CONFIG_SYS_INIT_SP_ADDR to SRAM Signed-off-by: Vasily Khoruzhick --- include/configs/zipitz2.h | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'include') diff --git a/include/configs/zipitz2.h b/include/configs/zipitz2.h index 26204af2c2..80d78b6717 100644 --- a/include/configs/zipitz2.h +++ b/include/configs/zipitz2.h @@ -161,6 +161,12 @@ unsigned char zipitz2_spi_read(void); #define CONFIG_STACKSIZE_FIQ (4*1024) /* FIQ stack */ #endif +/* + * SRAM Map + */ +#define PHYS_SRAM 0x5c000000 /* SRAM Bank #1 */ +#define PHYS_SRAM_SIZE 0x00040000 /* 256k */ + /* * DRAM Map */ @@ -177,7 +183,7 @@ unsigned char zipitz2_spi_read(void); #define CONFIG_SYS_LOAD_ADDR CONFIG_SYS_DRAM_BASE #define CONFIG_SYS_SDRAM_BASE PHYS_SDRAM_1 -#define CONFIG_SYS_INIT_SP_ADDR (GENERATED_GBL_DATA_SIZE + PHYS_SDRAM_1 + 2048) +#define CONFIG_SYS_INIT_SP_ADDR (GENERATED_GBL_DATA_SIZE + PHYS_SRAM + 2048) /* * NOR FLASH -- cgit From 81f731ca7c387d6ae1560a27118a4c6a09b6e722 Mon Sep 17 00:00:00 2001 From: Vasily Khoruzhick Date: Wed, 25 Jan 2012 22:54:33 +0300 Subject: zipitz2: use pxa_mmc_gen as MMC driver Signed-off-by: Vasily Khoruzhick --- include/configs/zipitz2.h | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'include') diff --git a/include/configs/zipitz2.h b/include/configs/zipitz2.h index 80d78b6717..afe1e891dd 100644 --- a/include/configs/zipitz2.h +++ b/include/configs/zipitz2.h @@ -45,7 +45,8 @@ #define CONFIG_ARCH_CPU_INIT #define CONFIG_BOOTCOMMAND \ - "if mmc init && fatload mmc 0 0xa0000000 uboot.script ; then " \ + "if mmc rescan && ext2load mmc 0 0xa0000000 boot/uboot.script ;"\ + "then " \ "source 0xa0000000; " \ "else " \ "bootm 0x60000; " \ @@ -85,7 +86,8 @@ */ #ifdef CONFIG_CMD_MMC #define CONFIG_MMC -#define CONFIG_PXA_MMC +#define CONFIG_GENERIC_MMC +#define CONFIG_PXA_MMC_GENERIC #define CONFIG_SYS_MMC_BASE 0xF0000000 #define CONFIG_CMD_FAT #define CONFIG_CMD_EXT2 -- cgit From c1ff6d8872401dd421a329440debba8fb91ecf2b Mon Sep 17 00:00:00 2001 From: Marek Vasut Date: Mon, 13 Feb 2012 09:05:16 +0100 Subject: PXA: Remove PXA PCMCIA support Say good bye to some ancient, very broken and unused code. Signed-off-by: Marek Vasut --- include/pcmcia.h | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'include') diff --git a/include/pcmcia.h b/include/pcmcia.h index b60323d3c0..ca0bf224f1 100644 --- a/include/pcmcia.h +++ b/include/pcmcia.h @@ -313,8 +313,7 @@ extern u_int *pcmcia_pgcrx[]; #define PCMCIA_PGCRX(slot) (*pcmcia_pgcrx[slot]) #endif -#if defined(CONFIG_CMD_IDE) && defined(CONFIG_IDE_8xx_PCCARD) \ - || defined(CONFIG_PXA_PCMCIA) +#if defined(CONFIG_CMD_IDE) && defined(CONFIG_IDE_8xx_PCCARD) extern int check_ide_device(int slot); #endif -- cgit From 2ea73e9e38befa872d215c919f766d837d7a1312 Mon Sep 17 00:00:00 2001 From: Wolfgang Grandegger Date: Wed, 8 Feb 2012 22:33:26 +0000 Subject: mx6qsabrelite: add and enable USB Host 1 support Cc: Stefano Babic Cc: Jason Liu Signed-off-by: Wolfgang Grandegger --- include/configs/mx6qsabrelite.h | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to 'include') diff --git a/include/configs/mx6qsabrelite.h b/include/configs/mx6qsabrelite.h index 982f03f710..93000f0376 100644 --- a/include/configs/mx6qsabrelite.h +++ b/include/configs/mx6qsabrelite.h @@ -80,6 +80,19 @@ #define CONFIG_PHYLIB #define CONFIG_PHY_MICREL +/* USB Configs */ +#define CONFIG_CMD_USB +#define CONFIG_CMD_FAT +#define CONFIG_USB_EHCI +#define CONFIG_USB_EHCI_MX6 +#define CONFIG_USB_STORAGE +#define CONFIG_USB_HOST_ETHER +#define CONFIG_USB_ETHER_ASIX +#define CONFIG_USB_ETHER_SMSC95XX +#define CONFIG_MXC_USB_PORT 1 +#define CONFIG_MXC_USB_PORTSC (PORT_PTS_UTMI | PORT_PTS_PTW) +#define CONFIG_MXC_USB_FLAGS 0 + /* allow to overwrite serial and ethaddr */ #define CONFIG_ENV_OVERWRITE #define CONFIG_CONS_INDEX 1 -- cgit From 763cf0a3d24124916824e31793fbafbbb4311597 Mon Sep 17 00:00:00 2001 From: Matt Porter Date: Tue, 31 Jan 2012 12:03:58 +0000 Subject: SPL: Enable YMODEM support on BeagleBone and AM335x EVM Cc: Chandan Nath Tested-by: Tom Rini Signed-off-by: Matt Porter --- include/configs/am335x_evm.h | 1 + 1 file changed, 1 insertion(+) (limited to 'include') diff --git a/include/configs/am335x_evm.h b/include/configs/am335x_evm.h index 6683b3ec29..d0fbc88214 100644 --- a/include/configs/am335x_evm.h +++ b/include/configs/am335x_evm.h @@ -145,6 +145,7 @@ #define CONFIG_SPL_LIBDISK_SUPPORT #define CONFIG_SPL_LIBGENERIC_SUPPORT #define CONFIG_SPL_SERIAL_SUPPORT +#define CONFIG_SPL_YMODEM_SUPPORT #define CONFIG_SPL_LDSCRIPT "$(CPUDIR)/omap-common/u-boot-spl.lds" /* -- cgit From 8e807ec3aa977fd50bea18ce0b51b15877a6bde5 Mon Sep 17 00:00:00 2001 From: Marek Vasut Date: Tue, 6 Mar 2012 00:45:35 +0100 Subject: IXP: Fix missing MACH_TYPE_{ACTUX?,PNB3,DVLHOST} These symbols are no longer defined in Linux-ARM's mach-types files. Replace these with CONFIG_MACH_TYPE instead. Signed-off-by: Marek Vasut Cc: Bryan Hundven Cc: Michael Schwingen --- include/configs/actux1.h | 2 ++ include/configs/actux2.h | 2 ++ include/configs/actux3.h | 2 ++ include/configs/actux4.h | 2 ++ include/configs/dvlhost.h | 2 ++ include/configs/pdnb3.h | 2 ++ 6 files changed, 12 insertions(+) (limited to 'include') diff --git a/include/configs/actux1.h b/include/configs/actux1.h index 00780d0d8b..bdd2239d8e 100644 --- a/include/configs/actux1.h +++ b/include/configs/actux1.h @@ -29,6 +29,8 @@ #define CONFIG_IXP425 1 #define CONFIG_ACTUX1 1 +#define CONFIG_MACH_TYPE 1479 + #define CONFIG_DISPLAY_CPUINFO 1 #define CONFIG_DISPLAY_BOARDINFO 1 diff --git a/include/configs/actux2.h b/include/configs/actux2.h index cb97434c3e..c55571c128 100644 --- a/include/configs/actux2.h +++ b/include/configs/actux2.h @@ -29,6 +29,8 @@ #define CONFIG_IXP425 1 #define CONFIG_ACTUX2 1 +#define CONFIG_MACH_TYPE 1480 + #define CONFIG_DISPLAY_CPUINFO 1 #define CONFIG_DISPLAY_BOARDINFO 1 diff --git a/include/configs/actux3.h b/include/configs/actux3.h index 816d982a31..78ee2b598f 100644 --- a/include/configs/actux3.h +++ b/include/configs/actux3.h @@ -29,6 +29,8 @@ #define CONFIG_IXP425 1 #define CONFIG_ACTUX3 1 +#define CONFIG_MACH_TYPE 1481 + #define CONFIG_DISPLAY_CPUINFO 1 #define CONFIG_DISPLAY_BOARDINFO 1 diff --git a/include/configs/actux4.h b/include/configs/actux4.h index 90badd39c5..c1105df595 100644 --- a/include/configs/actux4.h +++ b/include/configs/actux4.h @@ -29,6 +29,8 @@ #define CONFIG_IXP425 1 #define CONFIG_ACTUX4 1 +#define CONFIG_MACH_TYPE 1532 + #define CONFIG_DISPLAY_CPUINFO 1 #define CONFIG_DISPLAY_BOARDINFO 1 diff --git a/include/configs/dvlhost.h b/include/configs/dvlhost.h index 86fecd15a6..4eda91e7f4 100644 --- a/include/configs/dvlhost.h +++ b/include/configs/dvlhost.h @@ -30,6 +30,8 @@ #define CONFIG_IXP425 1 #define CONFIG_DVLHOST 1 +#define CONFIG_MACH_TYPE 1343 + #define CONFIG_DISPLAY_CPUINFO 1 #define CONFIG_DISPLAY_BOARDINFO 1 diff --git a/include/configs/pdnb3.h b/include/configs/pdnb3.h index 56bb4641fc..43ec38f5d4 100644 --- a/include/configs/pdnb3.h +++ b/include/configs/pdnb3.h @@ -33,6 +33,8 @@ #define CONFIG_IXP425 1 /* This is an IXP425 CPU */ #define CONFIG_PDNB3 1 /* on an PDNB3 board */ +#define CONFIG_MACH_TYPE 1002 + #define CONFIG_DISPLAY_CPUINFO 1 /* display cpu info (and speed) */ #define CONFIG_DISPLAY_BOARDINFO 1 /* display board info */ -- cgit From 9ff323df76b677fb64ae8490e5fafd3a2e51e8da Mon Sep 17 00:00:00 2001 From: Eric Nelson Date: Fri, 2 Mar 2012 12:55:09 +0000 Subject: i.MX6: mx6qsabrelite: add ext2 support Current Ubuntu releases from Freescale contain a boot script in ext3 filesystem. Signed-off-by: Eric Nelson --- include/configs/mx6qsabrelite.h | 1 + 1 file changed, 1 insertion(+) (limited to 'include') diff --git a/include/configs/mx6qsabrelite.h b/include/configs/mx6qsabrelite.h index 93000f0376..bb3a46b2f5 100644 --- a/include/configs/mx6qsabrelite.h +++ b/include/configs/mx6qsabrelite.h @@ -64,6 +64,7 @@ #define CONFIG_MMC #define CONFIG_CMD_MMC #define CONFIG_GENERIC_MMC +#define CONFIG_CMD_EXT2 #define CONFIG_CMD_FAT #define CONFIG_DOS_PARTITION -- cgit From 0bd14dea635e95eb7c16bb93fac38a76095fb586 Mon Sep 17 00:00:00 2001 From: Fabio Estevam Date: Thu, 9 Feb 2012 14:25:08 +0000 Subject: mx51evk: Fix CONFIG_SYS_MEMTEST_END CONFIG_SYS_MEMTEST_END should be higher than CONFIG_SYS_MEMTEST_START. Signed-off-by: Fabio Estevam --- include/configs/mx51evk.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'include') diff --git a/include/configs/mx51evk.h b/include/configs/mx51evk.h index 3b18a18d3e..1477b213bd 100644 --- a/include/configs/mx51evk.h +++ b/include/configs/mx51evk.h @@ -199,7 +199,7 @@ #define CONFIG_SYS_BARGSIZE CONFIG_SYS_CBSIZE /* Boot Argument Buffer Size */ #define CONFIG_SYS_MEMTEST_START 0x90000000 -#define CONFIG_SYS_MEMTEST_END 0x10000 +#define CONFIG_SYS_MEMTEST_END 0x90010000 #define CONFIG_SYS_LOAD_ADDR CONFIG_LOADADDR -- cgit From bc9d5ef107b3feca44eacd18b321e8b4547462f9 Mon Sep 17 00:00:00 2001 From: Fabio Estevam Date: Thu, 9 Feb 2012 14:25:09 +0000 Subject: mx53evk: Fix CONFIG_SYS_MEMTEST_END CONFIG_SYS_MEMTEST_END should be higher than CONFIG_SYS_MEMTEST_START. Cc: Jason Liu Signed-off-by: Fabio Estevam --- include/configs/mx53evk.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'include') diff --git a/include/configs/mx53evk.h b/include/configs/mx53evk.h index 11fe6efe62..a77e5b206d 100644 --- a/include/configs/mx53evk.h +++ b/include/configs/mx53evk.h @@ -161,7 +161,7 @@ #define CONFIG_SYS_BARGSIZE CONFIG_SYS_CBSIZE /* Boot Argument Buffer Size */ #define CONFIG_SYS_MEMTEST_START 0x70000000 -#define CONFIG_SYS_MEMTEST_END 0x10000 +#define CONFIG_SYS_MEMTEST_END 0x70010000 #define CONFIG_SYS_LOAD_ADDR CONFIG_LOADADDR -- cgit From 869aed7bcea04e449521fdf5f494207b13afed6b Mon Sep 17 00:00:00 2001 From: Fabio Estevam Date: Thu, 9 Feb 2012 14:25:10 +0000 Subject: mx53smd: Fix CONFIG_SYS_MEMTEST_END CONFIG_SYS_MEMTEST_END should be higher than CONFIG_SYS_MEMTEST_START. Signed-off-by: Fabio Estevam --- include/configs/mx53smd.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'include') diff --git a/include/configs/mx53smd.h b/include/configs/mx53smd.h index 032f72261e..a04db3ff45 100644 --- a/include/configs/mx53smd.h +++ b/include/configs/mx53smd.h @@ -149,7 +149,7 @@ #define CONFIG_SYS_BARGSIZE CONFIG_SYS_CBSIZE /* Boot Argument Buffer Size */ #define CONFIG_SYS_MEMTEST_START 0x70000000 -#define CONFIG_SYS_MEMTEST_END 0x10000 +#define CONFIG_SYS_MEMTEST_END 0x70010000 #define CONFIG_SYS_LOAD_ADDR CONFIG_LOADADDR -- cgit From f361a5c0753f910f1bc3db51970120df77499b2e Mon Sep 17 00:00:00 2001 From: Fabio Estevam Date: Thu, 9 Feb 2012 14:25:11 +0000 Subject: efikamx: Fix CONFIG_SYS_MEMTEST_END CONFIG_SYS_MEMTEST_END should be higher than CONFIG_SYS_MEMTEST_START. Cc: Marek Vasut Signed-off-by: Fabio Estevam Acked-by: Marek Vasut Tested-by: Marek Vasut --- include/configs/efikamx.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'include') diff --git a/include/configs/efikamx.h b/include/configs/efikamx.h index e2f0f7465d..af542fadce 100644 --- a/include/configs/efikamx.h +++ b/include/configs/efikamx.h @@ -240,7 +240,7 @@ #define CONFIG_SYS_BARGSIZE CONFIG_SYS_CBSIZE /* Boot Argument Buffer Size */ #define CONFIG_SYS_MEMTEST_START 0x90000000 -#define CONFIG_SYS_MEMTEST_END 0x10000 +#define CONFIG_SYS_MEMTEST_END 0x90010000 #define CONFIG_SYS_LOAD_ADDR CONFIG_LOADADDR -- cgit From 304e49e6cbec7ce8577a528e5be36930d098243b Mon Sep 17 00:00:00 2001 From: Fabio Estevam Date: Thu, 9 Feb 2012 14:25:07 +0000 Subject: mx31pdk: Fix CONFIG_SYS_MEMTEST_END CONFIG_SYS_MEMTEST_END should be higher than CONFIG_SYS_MEMTEST_START. Signed-off-by: Fabio Estevam --- include/configs/mx31pdk.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'include') diff --git a/include/configs/mx31pdk.h b/include/configs/mx31pdk.h index 4da6020c8c..49d440b9ae 100644 --- a/include/configs/mx31pdk.h +++ b/include/configs/mx31pdk.h @@ -141,7 +141,7 @@ /* memtest works on */ #define CONFIG_SYS_MEMTEST_START 0x80000000 -#define CONFIG_SYS_MEMTEST_END 0x10000 +#define CONFIG_SYS_MEMTEST_END 0x80010000 /* default load address */ #define CONFIG_SYS_LOAD_ADDR 0x81000000 -- cgit From 1c9ceff8ca896bd04cc2c85f762662dceecd7927 Mon Sep 17 00:00:00 2001 From: Eric Nelson Date: Mon, 12 Mar 2012 15:04:12 +0000 Subject: i.MX6: mx6q_sabrelite: add CONFIG_REVISION_TAG This is needed to support Freescale-supplied userspaces. At the moment, both the IPU and VPU libraries provided by Freescale in the "imx-lib" package contain routines which scrape the system revision from /proc/cpuinfo. In the VPU library, this information is used to load the proper firmware, allowing a single binary to be used across various i.MX processors. Signed-off-by: Eric Nelson Acked-by: Marek Vasut Acked-by: Stefano Babic --- include/configs/mx6qsabrelite.h | 1 + 1 file changed, 1 insertion(+) (limited to 'include') diff --git a/include/configs/mx6qsabrelite.h b/include/configs/mx6qsabrelite.h index bb3a46b2f5..a1a2267bd4 100644 --- a/include/configs/mx6qsabrelite.h +++ b/include/configs/mx6qsabrelite.h @@ -33,6 +33,7 @@ #define CONFIG_CMDLINE_TAG #define CONFIG_SETUP_MEMORY_TAGS #define CONFIG_INITRD_TAG +#define CONFIG_REVISION_TAG /* Size of malloc() pool */ #define CONFIG_SYS_MALLOC_LEN (CONFIG_ENV_SIZE + 2 * 1024 * 1024) -- cgit From c338f0b5c60d3b133139539fdfc39d2f2cb29b06 Mon Sep 17 00:00:00 2001 From: Eric Nelson Date: Sun, 4 Mar 2012 10:51:36 +0000 Subject: i.MX6: mx6qsabrelite: add MACH_TYPE_MX6Q_SABRELITE Allow non-dt kernels to boot Signed-off-by: Troy Kisky --- include/configs/mx6qsabrelite.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'include') diff --git a/include/configs/mx6qsabrelite.h b/include/configs/mx6qsabrelite.h index a1a2267bd4..8bc8a83702 100644 --- a/include/configs/mx6qsabrelite.h +++ b/include/configs/mx6qsabrelite.h @@ -28,6 +28,8 @@ #define CONFIG_DISPLAY_CPUINFO #define CONFIG_DISPLAY_BOARDINFO +#define CONFIG_MACH_TYPE 3769 + #include #define CONFIG_CMDLINE_TAG -- cgit From 1fc3bbd17a9812998a7d7c2a3990b0fe2e605a2c Mon Sep 17 00:00:00 2001 From: Fabio Estevam Date: Thu, 22 Mar 2012 14:29:03 +0000 Subject: mx28evk: Provide default values for SPI bus and chip select Provide default values for SPI bus and chip select. This allows the command "sf probe" to work without passing SPI bus and chip select numbers as arguments. Signed-off-by: Fabio Estevam Acked-by: Marek Vasut --- include/configs/mx28evk.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'include') diff --git a/include/configs/mx28evk.h b/include/configs/mx28evk.h index 04967d7d2c..30814c6c0c 100644 --- a/include/configs/mx28evk.h +++ b/include/configs/mx28evk.h @@ -186,6 +186,8 @@ /* SPI Flash */ #ifdef CONFIG_CMD_SF #define CONFIG_SPI_FLASH +#define CONFIG_SF_DEFAULT_BUS 2 +#define CONFIG_SF_DEFAULT_CS 0 /* this may vary and depends on the installed chip */ #define CONFIG_SPI_FLASH_SST #define CONFIG_SF_DEFAULT_MODE SPI_MODE_0 -- cgit From 94f0003f654fb490ee4be2e2aef1811835f1fb8d Mon Sep 17 00:00:00 2001 From: Fabio Estevam Date: Thu, 22 Mar 2012 14:29:04 +0000 Subject: configs: imx: Use CONFIG_SF_DEFAULT_CS CONFIG_SPI_FLASH_CS is not used anywhere. Use CONFIG_SF_DEFAULT_CS instead. Signed-off-by: Fabio Estevam Acked-by: Marek Vasut Acked-by: Stefano Babic --- include/configs/efikamx.h | 2 +- include/configs/m28evk.h | 2 +- include/configs/vision2.h | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) (limited to 'include') diff --git a/include/configs/efikamx.h b/include/configs/efikamx.h index af542fadce..120055f1d7 100644 --- a/include/configs/efikamx.h +++ b/include/configs/efikamx.h @@ -113,7 +113,7 @@ #define CONFIG_SPI_FLASH #define CONFIG_SPI_FLASH_SST -#define CONFIG_SPI_FLASH_CS (1 | 121 << 8) +#define CONFIG_SF_DEFAULT_CS (1 | 121 << 8) #define CONFIG_SF_DEFAULT_MODE (SPI_MODE_0) #define CONFIG_SF_DEFAULT_SPEED 25000000 diff --git a/include/configs/m28evk.h b/include/configs/m28evk.h index 4d59153706..4b97c7140d 100644 --- a/include/configs/m28evk.h +++ b/include/configs/m28evk.h @@ -252,7 +252,7 @@ #ifdef CONFIG_CMD_SF #define CONFIG_SPI_FLASH #define CONFIG_SPI_FLASH_STMICRO -#define CONFIG_SPI_FLASH_CS 2 +#define CONFIG_SF_DEFAULT_CS 2 #define CONFIG_SF_DEFAULT_MODE SPI_MODE_0 #define CONFIG_SF_DEFAULT_SPEED 24000000 diff --git a/include/configs/vision2.h b/include/configs/vision2.h index 35b71f79e6..f6904f3f6a 100644 --- a/include/configs/vision2.h +++ b/include/configs/vision2.h @@ -72,7 +72,7 @@ * Use gpio 4 pin 25 as chip select for SPI flash * This corresponds to gpio 121 */ -#define CONFIG_SPI_FLASH_CS (1 | (121 << 8)) +#define CONFIG_SF_DEFAULT_CS (1 | (121 << 8)) #define CONFIG_SF_DEFAULT_MODE SPI_MODE_0 #define CONFIG_SF_DEFAULT_SPEED 25000000 -- cgit From 1648a37505e84fc4e5268b026c3f1db862107e00 Mon Sep 17 00:00:00 2001 From: Simon Schwarz Date: Thu, 15 Mar 2012 04:01:34 +0000 Subject: Add cmd_spl command This adds a spl command to the u-boot. Related config: CONFIG_CMD_SPL activate/deactivate the command CONFIG_CMD_SPL_NAND_OFS Offset in NAND to use Signed-off-by: Simon Schwarz Signed-off-by: Stefano Babic CC: Tom Rini CC: Wolfgang Denk --- include/cmd_spl.h | 31 +++++++++++++++++++++++++++++++ include/image.h | 2 ++ 2 files changed, 33 insertions(+) create mode 100644 include/cmd_spl.h (limited to 'include') diff --git a/include/cmd_spl.h b/include/cmd_spl.h new file mode 100644 index 0000000000..6d6206d81b --- /dev/null +++ b/include/cmd_spl.h @@ -0,0 +1,31 @@ +/* Copyright (C) 2011 + * Corscience GmbH & Co. KG - Simon Schwarz + * + * 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 + */ +#ifndef _NAND_SPL_H_ +#define _NAND_SPL_H_ + +#define SPL_EXPORT (0x00000001) + +#define SPL_EXPORT_FDT (0x00000001) +#define SPL_EXPORT_ATAGS (0x00000002) +#define SPL_EXPORT_LAST SPL_EXPORT_ATAGS + +#endif /* _NAND_SPL_H_ */ diff --git a/include/image.h b/include/image.h index bbf80f0cac..a1c6e4e9ad 100644 --- a/include/image.h +++ b/include/image.h @@ -268,6 +268,8 @@ typedef struct bootm_headers { #endif } bootm_headers_t; +extern bootm_headers_t images; + /* * Some systems (for example LWMON) have very short watchdog periods; * we must make sure to split long operations like memmove() or -- cgit From d38bc97dafe1f98650a674f2d62bcf2a3584a2bb Mon Sep 17 00:00:00 2001 From: Simon Schwarz Date: Thu, 15 Mar 2012 04:01:35 +0000 Subject: devkit8000: add config for spl command This adds some configs for devkit8000 to use the new spl command Signed-off-by: Simon Schwarz CC: Tom Rini CC: Stefano Babic CC: Wolfgang Denk --- include/configs/devkit8000.h | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'include') diff --git a/include/configs/devkit8000.h b/include/configs/devkit8000.h index 2b6a6ee091..e323877e26 100644 --- a/include/configs/devkit8000.h +++ b/include/configs/devkit8000.h @@ -351,4 +351,12 @@ #define CONFIG_SYS_SPL_MALLOC_START 0x80208000 #define CONFIG_SYS_SPL_MALLOC_SIZE 0x100000 /* 1 MB */ +/* SPL OS boot options */ +#define CONFIG_CMD_SPL +#define CONFIG_CMD_SPL_WRITE_SIZE 0x400 /* 1024 byte */ +#define CONFIG_CMD_SPL_NAND_OFS (CONFIG_SYS_NAND_SPL_KERNEL_OFFS+\ + 0x400000) +#define CONFIG_SYS_NAND_SPL_KERNEL_OFFS 0x280000 +#define CONFIG_SYS_SPL_ARGS_ADDR (PHYS_SDRAM_1 + 0x100) + #endif /* __CONFIG_H */ -- cgit From 2d52a9a38c20697b4aeecac0541c7496809e8238 Mon Sep 17 00:00:00 2001 From: Simon Schwarz Date: Thu, 15 Mar 2012 04:01:40 +0000 Subject: devkit8000: Implement and activate direct OS boot - Implements spl_start_uboot() for devkit8000 - Add configs to activate direct OS boot from SPL Signed-off-by: Simon Schwarz CC: Tom Rini CC: Stefano Babic CC: Wolfgang Denk --- include/configs/devkit8000.h | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'include') diff --git a/include/configs/devkit8000.h b/include/configs/devkit8000.h index e323877e26..eb7c376780 100644 --- a/include/configs/devkit8000.h +++ b/include/configs/devkit8000.h @@ -35,7 +35,7 @@ #define CONFIG_OMAP 1 /* in a TI OMAP core */ #define CONFIG_OMAP34XX 1 /* which is a 34XX */ #define CONFIG_OMAP3_DEVKIT8000 1 /* working with DevKit8000 */ - +#define CONFIG_MACH_TYPE MACH_TYPE_DEVKIT8000 /* * 1MB into the SDRAM to allow for SPL's bss at the beginning of SDRAM * 64 bytes before this address should be set aside for u-boot.img's @@ -327,7 +327,7 @@ #define CONFIG_SPL_MAX_SIZE 0xB400 /* 45 K */ #define CONFIG_SPL_STACK LOW_LEVEL_SRAM_STACK -#define CONFIG_SPL_BSS_START_ADDR 0x80000000 /*CONFIG_SYS_SDRAM_BASE*/ +#define CONFIG_SPL_BSS_START_ADDR 0x80000500 /* leave space for bootargs*/ #define CONFIG_SPL_BSS_MAX_SIZE 0x80000 /* NAND boot config */ @@ -352,6 +352,9 @@ #define CONFIG_SYS_SPL_MALLOC_SIZE 0x100000 /* 1 MB */ /* SPL OS boot options */ +#define CONFIG_SPL_OS_BOOT +#define CONFIG_SPL_OS_BOOT_KEY 26 + #define CONFIG_CMD_SPL #define CONFIG_CMD_SPL_WRITE_SIZE 0x400 /* 1024 byte */ #define CONFIG_CMD_SPL_NAND_OFS (CONFIG_SYS_NAND_SPL_KERNEL_OFFS+\ -- cgit From 84c21fb16fe474f72109bf665a7cd841e17a2409 Mon Sep 17 00:00:00 2001 From: Stefano Babic Date: Thu, 15 Mar 2012 04:01:44 +0000 Subject: OMAP3: twister: add support to boot Linux from SPL Signed-off-by: Stefano Babic CC: Tom Rini CC: Wolfgang Denk CC: Simon Schwarz --- include/configs/twister.h | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'include') diff --git a/include/configs/twister.h b/include/configs/twister.h index 64a886d3a4..a8524816a8 100644 --- a/include/configs/twister.h +++ b/include/configs/twister.h @@ -51,4 +51,16 @@ #define CONFIG_EXTRA_ENV_SETTINGS CONFIG_TAM3517_SETTINGS \ "bootcmd=run nandboot\0" +/* SPL OS boot options */ +#define CONFIG_CMD_SPL +#define CONFIG_CMD_SPL_WRITE_SIZE 0x400 /* 1024 byte */ +#define CONFIG_SYS_NAND_SPL_KERNEL_OFFS 0x00200000 +#define CONFIG_CMD_SPL_NAND_OFS (CONFIG_SYS_NAND_SPL_KERNEL_OFFS+\ + 0x600000) +#define CONFIG_SPL_OS_BOOT +#define CONFIG_SPL_OS_BOOT_KEY 55 + +#define CONFIG_SYS_SPL_ARGS_ADDR (PHYS_SDRAM_1 + 0x100) +#define CONFIG_SPL_BOARD_INIT + #endif /* __CONFIG_H */ -- cgit From 88b821bbef64f0b69710ff7d857fc490f72a6d3c Mon Sep 17 00:00:00 2001 From: Stefano Babic Date: Wed, 21 Mar 2012 00:14:25 +0000 Subject: OMAP3: mt_ventoux: sets its own mtdparts Signed-off-by: Stefano Babic Cc: Tom Rini --- include/configs/mt_ventoux.h | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'include') diff --git a/include/configs/mt_ventoux.h b/include/configs/mt_ventoux.h index 2034b59f47..5db6d57666 100644 --- a/include/configs/mt_ventoux.h +++ b/include/configs/mt_ventoux.h @@ -39,6 +39,16 @@ #define V_PROMPT "mt_ventoux => " #define CONFIG_SYS_PROMPT V_PROMPT +/* + * Set its own mtdparts, different from common + */ +#undef MTDIDS_DEFAULT +#undef MTDPARTS_DEFAULT +#define MTDIDS_DEFAULT "nand0=omap2-nand.0" +#define MTDPARTS_DEFAULT "mtdparts=omap2-nand.0:512k(MLO)," \ + "1m(u-boot),256k(env1)," \ + "256k(env2),8m(ubisystem),-(rootfs)" + /* * FPGA */ -- cgit From 1441aa6ae8a77ada40407cdfbec783f5559f1646 Mon Sep 17 00:00:00 2001 From: Stefano Babic Date: Wed, 5 Oct 2011 03:08:24 +0000 Subject: Davinci: ea20: use gpio framework to access gpios Drop direct access to SOC's registers and use the function of the GPIO driver for da8xx. [Tom: Remove gpio[68]_base as it's now unused] Signed-off-by: Stefano Babic CC: Bastian Ruppert CC: dzu@denx.de CC: Sandeep Paulraj Signed-off-by: Tom Rini --- include/configs/ea20.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'include') diff --git a/include/configs/ea20.h b/include/configs/ea20.h index b4610d9474..e059b30826 100644 --- a/include/configs/ea20.h +++ b/include/configs/ea20.h @@ -48,6 +48,7 @@ #define CONFIG_SYS_HZ 1000 #define CONFIG_SKIP_LOWLEVEL_INIT #define CONFIG_SYS_TEXT_BASE 0xc1080000 +#define CONFIG_DA8XX_GPIO /* * Memory Info @@ -167,6 +168,7 @@ #define CONFIG_CMD_SAVES #define CONFIG_CMD_MEMORY #define CONFIG_CMD_I2C +#define CONFIG_CMD_GPIO #ifdef CONFIG_CMD_BDI #define CONFIG_CLOCKS -- cgit From 24efef90c4c9ddc65ae3bd982b09b99b2d0cd4e0 Mon Sep 17 00:00:00 2001 From: Heiko Schocher Date: Wed, 7 Mar 2012 04:10:00 +0000 Subject: ARM: davinci: fixes for cam_enc_4xx board - change CONFIG_ENV_RANGE to contain 2 nand erase blocks, one for bad block reserve. - remove from the envvariable "img_writeramdisk" the ubifsmount command, as it is not needed. - erase the hole mtd partition containing u-boot - save environment variable "dvn_app_vers" and "dvn_boot_vers" only after installing the new image. changes requested from Marek Vasut: - arm, davinci: fix eldk-4.2 warnings for cam_enc_4xx board - get rid of run_command2 usage needed since patch: commit 009dde1955583e306cf904c864068f3acb0db499 Author: Simon Glass Date: Tue Feb 14 19:59:20 2012 +0000 Rename run_command2() to run_command() is now in mainline. - add CONFIG_SPL_LIBGENERIC_SUPPORT support - remove CONFIG_CMD_PXE support - fix warning: cam_enc_4xx.c: In function 'menu_handle': cam_enc_4xx.c:609: warning: dereferencing type-punned pointer will break strict-aliasing rules - fix error: arm-linux-ld: u-boot-spl: Not enough room for program headers, try linking with -N Signed-off-by: Heiko Schocher Cc: Marek Vasut Cc: Tom Rini Cc: Fletzer Martin Cc: Wolfgang Denk --- include/configs/cam_enc_4xx.h | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) (limited to 'include') diff --git a/include/configs/cam_enc_4xx.h b/include/configs/cam_enc_4xx.h index 0fee53f750..99856ebfdf 100644 --- a/include/configs/cam_enc_4xx.h +++ b/include/configs/cam_enc_4xx.h @@ -161,15 +161,14 @@ #define CONFIG_MENU #define CONFIG_MENU_SHOW #define CONFIG_FIT -#define CONFIG_CMD_PXE #define CONFIG_BOARD_IMG_ADDR_R 0x80000000 #ifdef CONFIG_NAND_DAVINCI #define CONFIG_ENV_SIZE (16 << 10) #define CONFIG_ENV_IS_IN_NAND #define CONFIG_ENV_OFFSET 0x180000 +#define CONFIG_ENV_RANGE 0x040000 #define CONFIG_ENV_OFFSET_REDUND 0x1c0000 -#define CONFIG_ENV_RANGE 0x020000 #undef CONFIG_ENV_IS_IN_FLASH #endif @@ -220,6 +219,7 @@ /* Defines for SPL */ #define CONFIG_SPL +#define CONFIG_SPL_LIBGENERIC_SUPPORT #define CONFIG_SPL_NAND_SUPPORT #define CONFIG_SPL_NAND_SIMPLE #define CONFIG_SPL_NAND_LOAD @@ -229,7 +229,7 @@ #define CONFIG_SPL_LDSCRIPT "$(BOARDDIR)/u-boot-spl.lds" #define CONFIG_SPL_STACK (0x00010000 + 0x7f00) -#define CONFIG_SPL_TEXT_BASE 0x0000020 /*CONFIG_SYS_SRAM_START*/ +#define CONFIG_SPL_TEXT_BASE 0x00000020 /*CONFIG_SYS_SRAM_START*/ #define CONFIG_SPL_MAX_SIZE 12320 #ifndef CONFIG_SPL_BUILD @@ -274,6 +274,7 @@ #define CONFIG_SYS_NAND_U_BOOT_OFFS 0x80000 #define CONFIG_SYS_NAND_U_BOOT_SIZE 0xa0000 +#define CONFIG_SYS_NAND_U_BOOT_ERA_SIZE 0x100000 /* for UBL header */ #define CONFIG_SYS_UBL_BLOCK (CONFIG_SYS_NAND_PAGE_SIZE) @@ -429,7 +430,7 @@ " 0 3000;nandrbl uboot\0" \ "writeuboot=nandrbl uboot;" \ "nand erase " xstr(CONFIG_SYS_NAND_U_BOOT_OFFS) " " \ - xstr(CONFIG_SYS_NAND_U_BOOT_SIZE) \ + xstr(CONFIG_SYS_NAND_U_BOOT_ERA_SIZE) \ ";nand write " xstr(DVN4XX_UBOOT_ADDR_R_UBOOT) \ " " xstr(CONFIG_SYS_NAND_U_BOOT_OFFS) " " \ xstr(CONFIG_SYS_NAND_U_BOOT_SIZE) "\0" \ @@ -466,14 +467,14 @@ "nand write ${img_addr_r} 0 3000;nandrbl uboot\0" \ "img_writeuboot=nandrbl uboot;" \ "nand erase " xstr(CONFIG_SYS_NAND_U_BOOT_OFFS) " " \ - xstr(CONFIG_SYS_NAND_U_BOOT_SIZE) \ + xstr(CONFIG_SYS_NAND_U_BOOT_ERA_SIZE) \ ";nand write ${img_addr_r} " \ xstr(CONFIG_SYS_NAND_U_BOOT_OFFS) " " \ xstr(CONFIG_SYS_NAND_U_BOOT_SIZE) "\0" \ "img_writedfenv=ubi part ubi 2048;" \ "ubi write ${img_addr_r} default ${filesize}\0" \ "img_volume=rootfs1\0" \ - "img_writeramdisk=ubi part ubi 2048;ubifsmount ${img_volume};" \ + "img_writeramdisk=ubi part ubi 2048;" \ "ubi write ${img_addr_r} ${img_volume} ${filesize}\0" \ "load_img=tftp ${fit_addr_r} ${img_file}\0" \ "net_nfs=run load_kernel; " \ -- cgit From 7b81649a053826dc31804d3260a44ff599a9542a Mon Sep 17 00:00:00 2001 From: Rob Herring Date: Wed, 1 Feb 2012 16:57:53 +0000 Subject: ARM: highbank: change TEXT_BASE to 0x8000 Make some space at the beginning of RAM so the FDT can be loaded to a known fixed address at 0x1000. Signed-off-by: Rob Herring --- include/configs/highbank.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'include') diff --git a/include/configs/highbank.h b/include/configs/highbank.h index 5604733036..e717273491 100644 --- a/include/configs/highbank.h +++ b/include/configs/highbank.h @@ -120,7 +120,7 @@ #define CONFIG_ENV_IS_NOWHERE #define CONFIG_SYS_SDRAM_BASE 0x00000000 -#define CONFIG_SYS_TEXT_BASE 0x00001000 +#define CONFIG_SYS_TEXT_BASE 0x00008000 #define CONFIG_SYS_INIT_SP_ADDR 0x01000000 #define CONFIG_SKIP_LOWLEVEL_INIT -- cgit From 877012df309329a9264e6e9558d4f71bfa0cddbe Mon Sep 17 00:00:00 2001 From: Rob Herring Date: Wed, 1 Feb 2012 16:57:54 +0000 Subject: ARM: highbank: Add boot counter support Add boot counter support using an sysreg which is persistent across reset. Signed-off-by: Rob Herring --- include/configs/highbank.h | 3 +++ 1 file changed, 3 insertions(+) (limited to 'include') diff --git a/include/configs/highbank.h b/include/configs/highbank.h index e717273491..801f4ae67c 100644 --- a/include/configs/highbank.h +++ b/include/configs/highbank.h @@ -41,6 +41,9 @@ #define CONFIG_BAUDRATE 38400 #define CONFIG_SYS_BAUDRATE_TABLE { 9600, 19200, 38400, 57600, 115200 } +#define CONFIG_BOOTCOUNT_LIMIT +#define CONFIG_SYS_BOOTCOUNT_ADDR 0xfff3cf0c + #define CONFIG_MISC_INIT_R #define CONFIG_SCSI_AHCI #define CONFIG_SCSI_AHCI_PLAT -- cgit From a34e8549480c41057aa47cea50c0785fd9ce4f4a Mon Sep 17 00:00:00 2001 From: Jason Hobbs Date: Wed, 1 Feb 2012 16:57:56 +0000 Subject: ARM: highbank: change env config to use nvram Update the highbank config to use env from NVRAM. Also remove extra env settings as they are not used unless the default env is used. Signed-off-by: Jason Hobbs Signed-off-by: Rob Herring --- include/configs/highbank.h | 16 +++++++--------- 1 file changed, 7 insertions(+), 9 deletions(-) (limited to 'include') diff --git a/include/configs/highbank.h b/include/configs/highbank.h index 801f4ae67c..520fa4cc9e 100644 --- a/include/configs/highbank.h +++ b/include/configs/highbank.h @@ -93,12 +93,6 @@ #define CONFIG_SYS_LOAD_ADDR 0x800000 -#define CONFIG_EXTRA_ENV_SETTINGS \ - "fdtaddr_r=0x600000\0" \ - "pxefile_addr_r=0x700000\0" \ - "kernel_addr_r=0x800000\0" \ - "ramdisk_addr_r=0x01000000\0" \ - /*----------------------------------------------------------------------- * Stack sizes * @@ -118,9 +112,13 @@ #define CONFIG_SYS_MEMTEST_START 0x100000 #define CONFIG_SYS_MEMTEST_END (PHYS_SDRAM_1_SIZE - 0x100000) -/* Room required on the stack for the environment data */ -#define CONFIG_ENV_SIZE 0x2000 -#define CONFIG_ENV_IS_NOWHERE +/* Environment data setup +*/ +#define CONFIG_ENV_IS_IN_NVRAM +#define CONFIG_SYS_NVRAM_BASE_ADDR 0xfff88000 /* NVRAM base address */ +#define CONFIG_SYS_NVRAM_SIZE 0x8000 /* NVRAM size */ +#define CONFIG_ENV_SIZE 0x2000 /* Size of Environ */ +#define CONFIG_ENV_ADDR CONFIG_SYS_NVRAM_BASE_ADDR #define CONFIG_SYS_SDRAM_BASE 0x00000000 #define CONFIG_SYS_TEXT_BASE 0x00008000 -- cgit From b3541c1ac93d4e4b786d28ef2f6dc5976a580af5 Mon Sep 17 00:00:00 2001 From: Marek Vasut Date: Thu, 15 Mar 2012 18:33:22 +0000 Subject: i.MX28: Make use of the bounce buffer This allows i.MX28 MMC host to fully utilize DMA transfers and caches, greatly improving speed. Signed-off-by: Marek Vasut Cc: Fabio Estevam --- include/configs/m28evk.h | 1 + include/configs/mx28evk.h | 1 + 2 files changed, 2 insertions(+) (limited to 'include') diff --git a/include/configs/m28evk.h b/include/configs/m28evk.h index 4b97c7140d..8b83180da8 100644 --- a/include/configs/m28evk.h +++ b/include/configs/m28evk.h @@ -140,6 +140,7 @@ */ #ifdef CONFIG_CMD_MMC #define CONFIG_MMC +#define CONFIG_MMC_BOUNCE_BUFFER #define CONFIG_GENERIC_MMC #define CONFIG_MXS_MMC #endif diff --git a/include/configs/mx28evk.h b/include/configs/mx28evk.h index 30814c6c0c..cdcc6e0eab 100644 --- a/include/configs/mx28evk.h +++ b/include/configs/mx28evk.h @@ -138,6 +138,7 @@ #ifdef CONFIG_CMD_MMC #define CONFIG_MMC #define CONFIG_GENERIC_MMC +#define CONFIG_MMC_BOUNCE_BUFFER #define CONFIG_MXS_MMC #endif -- cgit From 2c4b3c19a1fe1c4e9ef1ec457cf34821368288d7 Mon Sep 17 00:00:00 2001 From: Eric Nelson Date: Thu, 15 Mar 2012 18:33:24 +0000 Subject: net: force PKTALIGN to ARCH_DMA_MINALIGN This will prevent the need for architectures whose DMA alignment is greater than 32 to have bounce buffers. Signed-off-by: Eric Nelson --- include/net.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'include') diff --git a/include/net.h b/include/net.h index 556078518b..ee11f82ccc 100644 --- a/include/net.h +++ b/include/net.h @@ -16,6 +16,7 @@ #include #endif /* CONFIG_8xx */ +#include #include /* for nton* / ntoh* stuff */ @@ -31,7 +32,7 @@ # define PKTBUFSRX 4 #endif -#define PKTALIGN 32 +#define PKTALIGN ARCH_DMA_MINALIGN /* IPv4 addresses are always 32 bits in size */ typedef u32 IPaddr_t; -- cgit From a53f4a29ac62a2e83d35a4a7b6d6969cf95a5902 Mon Sep 17 00:00:00 2001 From: Simon Glass Date: Tue, 17 Jan 2012 08:20:50 +0000 Subject: fdt: Add fdtdec_find_aliases() to deal with alias nodes Stephen Warren pointed out that we should use nodes whether or not they have an alias in the /aliases section. The aliases section specifies the order so far as it can, but is not essential. Operating without alisses is useful when the enumerated order of nodes does not matter (admittedly rare in U-Boot). This is considerably more complex, and it is important to keep this complexity out of driver code. This patch creates a function fdtdec_find_aliases() which returns an ordered list of node offsets for a particular compatible ID, taking account of alias nodes. Signed-off-by: Simon Glass Signed-off-by: Tom Warren --- include/fdtdec.h | 47 +++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 47 insertions(+) (limited to 'include') diff --git a/include/fdtdec.h b/include/fdtdec.h index d871cdd1c1..492431c69b 100644 --- a/include/fdtdec.h +++ b/include/fdtdec.h @@ -126,3 +126,50 @@ int fdtdec_get_is_enabled(const void *blob, int node, int default_val); * if not. */ int fdtdec_check_fdt(void); + +/** + * Find the nodes for a peripheral and return a list of them in the correct + * order. This is used to enumerate all the peripherals of a certain type. + * + * To use this, optionally set up a /aliases node with alias properties for + * a peripheral. For example, for usb you could have: + * + * aliases { + * usb0 = "/ehci@c5008000"; + * usb1 = "/ehci@c5000000"; + * }; + * + * Pass "usb" as the name to this function and will return a list of two + * nodes offsets: /ehci@c5008000 and ehci@c5000000. + * + * All nodes returned will match the compatible ID, as it is assumed that + * all peripherals use the same driver. + * + * If no alias node is found, then the node list will be returned in the + * order found in the fdt. If the aliases mention a node which doesn't + * exist, then this will be ignored. If nodes are found with no aliases, + * they will be added in any order. + * + * If there is a gap in the aliases, then this function return a 0 node at + * that position. The return value will also count these gaps. + * + * This function checks node properties and will not return nodes which are + * marked disabled (status = "disabled"). + * + * @param blob FDT blob to use + * @param name Root name of alias to search for + * @param id Compatible ID to look for + * @param node_list Place to put list of found nodes + * @param maxcount Maximum number of nodes to find + * @return number of nodes found on success, FTD_ERR_... on error + */ +int fdtdec_find_aliases_for_id(const void *blob, const char *name, + enum fdt_compat_id id, int *node_list, int maxcount); + +/* + * Get the name for a compatible ID + * + * @param id Compatible ID to look for + * @return compatible string for that id + */ +const char *fdtdec_get_compatible(enum fdt_compat_id id); -- cgit From f88fe2ded4acd035826018f33c6a67033a8f5d07 Mon Sep 17 00:00:00 2001 From: Simon Glass Date: Mon, 27 Feb 2012 10:52:34 +0000 Subject: fdt: Tidy up a few fdtdec problems This fixes five trivial issues in fdtdec.c: 1. fdtdec_get_is_enabled() doesn't really need a default value 2. The fdt must be word-aligned, since otherwise it will fail on ARM 3. The compat_names[] array is missing its first element. This is needed only because the first fdt_compat_id is defined to be invalid. 4. Added a header prototype for fdtdec_next_compatible() 5. Change fdtdec_next_alias() to only increment its 'upto' parameter on success, to make the display error messages in the caller easier. Signed-off-by: Simon Glass Acked-by: Gerald Van Baren Acked-by: Stephen Warren Signed-off-by: Tom Warren --- include/fdtdec.h | 23 +++++++++++++++++++---- 1 file changed, 19 insertions(+), 4 deletions(-) (limited to 'include') diff --git a/include/fdtdec.h b/include/fdtdec.h index 492431c69b..5469c16abd 100644 --- a/include/fdtdec.h +++ b/include/fdtdec.h @@ -81,6 +81,21 @@ enum fdt_compat_id { int fdtdec_next_alias(const void *blob, const char *name, enum fdt_compat_id id, int *upto); +/** + * Find the next compatible node for a peripheral. + * + * Do the first call with node = 0. This function will return a pointer to + * the next compatible node. Next time you call this function, pass the + * value returned, and the next node will be provided. + * + * @param blob FDT blob to use + * @param node Start node for search + * @param id Compatible ID to look for (enum fdt_compat_id) + * @return offset of next compatible node, or -FDT_ERR_NOTFOUND if no more + */ +int fdtdec_next_compatible(const void *blob, int node, + enum fdt_compat_id id); + /** * Look up an address property in a node and return it as an address. * The property must hold either one address with no trailing data or @@ -112,14 +127,14 @@ s32 fdtdec_get_int(const void *blob, int node, const char *prop_name, * Checks whether a node is enabled. * This looks for a 'status' property. If this exists, then returns 1 if * the status is 'ok' and 0 otherwise. If there is no status property, - * it returns the default value. + * it returns 1 on the assumption that anything mentioned should be enabled + * by default. * * @param blob FDT blob * @param node node to examine - * @param default_val default value to return if no 'status' property exists - * @return integer value 0/1, if found, or default_val if not + * @return integer value 0 (not enabled) or 1 (enabled) */ -int fdtdec_get_is_enabled(const void *blob, int node, int default_val); +int fdtdec_get_is_enabled(const void *blob, int node); /** * Checks whether we have a valid fdt available to control U-Boot, and panic -- cgit From d17da65560f15f74f8efe321044b9cdf45e24c9b Mon Sep 17 00:00:00 2001 From: Simon Glass Date: Mon, 27 Feb 2012 10:52:35 +0000 Subject: fdt: Add functions to access phandles, arrays and bools Add a function to look up a property which is a phandle in a node, and another to read a fixed-length integer array from an fdt property. Also add a function to read boolean properties, although there is no actual boolean type in U-Boot. Signed-off-by: Simon Glass Acked-by: Gerald Van Baren Acked-by: Stephen Warren Signed-off-by: Tom Warren --- include/fdtdec.h | 39 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 39 insertions(+) (limited to 'include') diff --git a/include/fdtdec.h b/include/fdtdec.h index 5469c16abd..a4467000b7 100644 --- a/include/fdtdec.h +++ b/include/fdtdec.h @@ -188,3 +188,42 @@ int fdtdec_find_aliases_for_id(const void *blob, const char *name, * @return compatible string for that id */ const char *fdtdec_get_compatible(enum fdt_compat_id id); + +/* Look up a phandle and follow it to its node. Then return the offset + * of that node. + * + * @param blob FDT blob + * @param node node to examine + * @param prop_name name of property to find + * @return node offset if found, -ve error code on error + */ +int fdtdec_lookup_phandle(const void *blob, int node, const char *prop_name); + +/** + * Look up a property in a node and return its contents in an integer + * array of given length. The property must have at least enough data for + * the array (4*count bytes). It may have more, but this will be ignored. + * + * @param blob FDT blob + * @param node node to examine + * @param prop_name name of property to find + * @param array array to fill with data + * @param count number of array elements + * @return 0 if ok, or -FDT_ERR_NOTFOUND if the property is not found, + * or -FDT_ERR_BADLAYOUT if not enough data + */ +int fdtdec_get_int_array(const void *blob, int node, const char *prop_name, + u32 *array, int count); + +/** + * Look up a boolean property in a node and return it. + * + * A boolean properly is true if present in the device tree and false if not + * present, regardless of its value. + * + * @param blob FDT blob + * @param node node to examine + * @param prop_name name of property to find + * @return 1 if the properly is present; 0 if it isn't present + */ +int fdtdec_get_bool(const void *blob, int node, const char *prop_name); -- cgit From ed3ee5cd0640979a200710b9eefa210a617b19ff Mon Sep 17 00:00:00 2001 From: Simon Glass Date: Mon, 27 Feb 2012 10:52:36 +0000 Subject: fdt: Add basic support for decoding GPIO definitions This adds some support into fdtdec for reading GPIO definitions from the fdt. We permit up to FDT_GPIO_MAX GPIOs in the system. Each GPIO is of the form: gpio-function-name = ; where: phandle is a pointer to the GPIO node gpio_num is the number of the GPIO (0 to 223) flags is a flag, as follows: bit meaning 0 0=polarity normal, 1=active low (inverted) An example is: enable-propounder-gpios = <&gpio 43 0>; which means that GPIO 43 is used to enable the propounder (setting the GPIO high), or that you can detect that the propounder is enabled by checking if the GPIO is high (the fdt does not indicate input/output). Two main functions are provided: fdtdec_decode_gpio() reads a GPIO property from an fdt node and decodes it into a structure. fdtdec_setup_gpio() sets up the GPIO by calling gpio_request for you. Both functions can cope with the property being missing, which is taken to mean that that GPIO function is not available or is not needed. [For reference, from Stephen Warren . It may be that we add this extra complexity later if needed: The correct way to parse such a GPIO property in general is: * Read the first cell. * Find the node referenced by the phandle (the controller). * Ensure property gpio-controller is present in the controller node. * Read property #gpio-cells from the controller node. * Extract #gpio-cells from the original property. * Keep processing more cells from the original property; there may be multiple GPIOs listed. According to the binding documentation in the Linux kernel, Samsung Exynos4 doesn't use this format, and while all other chips do have a flags cell, about 50% of the controllers indicate the cell is unused. ] Signed-off-by: Simon Glass Signed-off-by: Tom Warren --- include/fdtdec.h | 45 +++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 45 insertions(+) (limited to 'include') diff --git a/include/fdtdec.h b/include/fdtdec.h index a4467000b7..2f3842d9a3 100644 --- a/include/fdtdec.h +++ b/include/fdtdec.h @@ -61,6 +61,23 @@ enum fdt_compat_id { COMPAT_COUNT, }; +/* GPIOs are numbered from 0 */ +enum { + FDT_GPIO_NONE = -1U, /* an invalid GPIO used to end our list */ + + FDT_GPIO_ACTIVE_LOW = 1 << 0, /* input is active low (else high) */ +}; + +/* This is the state of a GPIO pin as defined by the fdt */ +struct fdt_gpio_state { + const char *name; /* name of the fdt property defining this */ + uint gpio; /* GPIO number, or FDT_GPIO_NONE if none */ + u8 flags; /* FDT_GPIO_... flags */ +}; + +/* This tells us whether a fdt_gpio_state record is valid or not */ +#define fdt_gpio_isvalid(x) ((x)->gpio != FDT_GPIO_NONE) + /** * Find the next numbered alias for a peripheral. This is used to enumerate * all the peripherals of a certain type. @@ -227,3 +244,31 @@ int fdtdec_get_int_array(const void *blob, int node, const char *prop_name, * @return 1 if the properly is present; 0 if it isn't present */ int fdtdec_get_bool(const void *blob, int node, const char *prop_name); + +/** + * Decode a single GPIOs from an FDT. + * + * If the property is not found, then the GPIO structure will still be + * initialised, with gpio set to FDT_GPIO_NONE. This makes it easy to + * provide optional GPIOs. + * + * @param blob FDT blob to use + * @param node Node to look at + * @param prop_name Node property name + * @param gpio gpio elements to fill from FDT + * @return 0 if ok, -FDT_ERR_NOTFOUND if the property is missing. + */ +int fdtdec_decode_gpio(const void *blob, int node, const char *prop_name, + struct fdt_gpio_state *gpio); + +/** + * Set up a GPIO pin according to the provided gpio information. At present this + * just requests the GPIO. + * + * If the gpio is FDT_GPIO_NONE, no action is taken. This makes it easy to + * deal with optional GPIOs. + * + * @param gpio GPIO info to use for set up + * @return 0 if all ok or gpio was FDT_GPIO_NONE; -1 on error + */ +int fdtdec_setup_gpio(struct fdt_gpio_state *gpio); -- cgit From 87f938c9f7372f587a43fe7babcb171ee0a0672f Mon Sep 17 00:00:00 2001 From: Simon Glass Date: Mon, 27 Feb 2012 10:52:49 +0000 Subject: tegra: usb: Add support for Tegra USB peripheral This adds basic support for the Tegra2 USB controller. Board files should call board_usb_init() to set things up. Configuration is performed through the FDT, with aliases used to set the order of the ports, like this fragment: aliases { /* This defines the order of our USB ports */ usb0 = "/usb@0xc5008000"; usb1 = "/usb@0xc5000000"; }; drivers/usb/host files ONLY: Acked-by: Remy Bohmer Signed-off-by: Simon Glass Signed-off-by: Tom Warren --- include/fdtdec.h | 1 + 1 file changed, 1 insertion(+) (limited to 'include') diff --git a/include/fdtdec.h b/include/fdtdec.h index 2f3842d9a3..bde9873656 100644 --- a/include/fdtdec.h +++ b/include/fdtdec.h @@ -57,6 +57,7 @@ struct fdt_memory { */ enum fdt_compat_id { COMPAT_UNKNOWN, + COMPAT_NVIDIA_TEGRA20_USB, /* Tegra2 USB port */ COMPAT_COUNT, }; -- cgit From 9a263e55dc00f3277d8e82c906ee5c7a1dca0ba5 Mon Sep 17 00:00:00 2001 From: Simon Glass Date: Wed, 28 Mar 2012 10:08:24 +0000 Subject: fdt: Avoid early panic() when there is no FDT present CONFIG_OF_CONTROL requires a valid device tree. However, we cannot call panic() before the console is set up since the message does not appear, and we get a silent failure. Remove the panic from fdtdec_check_fdt() and provide a new function to prepare the fdt for use. This will be called after the console is ready. Signed-off-by: Simon Glass Signed-off-by: Tom Warren --- include/fdtdec.h | 17 +++++++++++++++-- 1 file changed, 15 insertions(+), 2 deletions(-) (limited to 'include') diff --git a/include/fdtdec.h b/include/fdtdec.h index bde9873656..6249f22e81 100644 --- a/include/fdtdec.h +++ b/include/fdtdec.h @@ -155,8 +155,21 @@ s32 fdtdec_get_int(const void *blob, int node, const char *prop_name, int fdtdec_get_is_enabled(const void *blob, int node); /** - * Checks whether we have a valid fdt available to control U-Boot, and panic - * if not. + * Make sure we have a valid fdt available to control U-Boot. + * + * If not, a message is printed to the console if the console is ready. + * + * @return 0 if all ok, -1 if not + */ +int fdtdec_prepare_fdt(void); + +/** + * Checks that we have a valid fdt available to control U-Boot. + + * However, if not then for the moment nothing is done, since this function + * is called too early to panic(). + * + * @returns 0 */ int fdtdec_check_fdt(void); -- cgit From 0291091c9e4dffce1f278d6b87ac123f389595df Mon Sep 17 00:00:00 2001 From: Simon Glass Date: Mon, 27 Feb 2012 10:52:51 +0000 Subject: tegra: usb: Add common USB defines for tegra2 boards All Tegra2 boards should include tegra2-common. This adds the required USB config to that file. Signed-off-by: Simon Glass Signed-off-by: Tom Warren --- include/configs/tegra2-common.h | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'include') diff --git a/include/configs/tegra2-common.h b/include/configs/tegra2-common.h index e6f385fac3..266d0e5880 100644 --- a/include/configs/tegra2-common.h +++ b/include/configs/tegra2-common.h @@ -84,6 +84,16 @@ #define CONFIG_SYS_BAUDRATE_TABLE {4800, 9600, 19200, 38400, 57600,\ 115200} +/* + * This parameter affects a TXFILLTUNING field that controls how much data is + * sent to the latency fifo before it is sent to the wire. Without this + * parameter, the default (2) causes occasional Data Buffer Errors in OUT + * packets depending on the buffer address and size. + */ +#define CONFIG_USB_EHCI_TXFIFO_THRESH 10 +#define CONFIG_EHCI_IS_TDI +#define CONFIG_EHCI_DCACHE + /* include default commands */ #include -- cgit From db44ebdb5cf7a82ce19d639cad27d9eac13c3a2f Mon Sep 17 00:00:00 2001 From: Simon Glass Date: Mon, 27 Feb 2012 10:52:52 +0000 Subject: tegra: usb: Enable USB on Seaboard Seaboard has a top port which is USB host or device, and a side port which is host only. Signed-off-by: Simon Glass Signed-off-by: Tom Warren --- include/configs/seaboard.h | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'include') diff --git a/include/configs/seaboard.h b/include/configs/seaboard.h index 261f9521ad..b6d9f7a88f 100644 --- a/include/configs/seaboard.h +++ b/include/configs/seaboard.h @@ -72,4 +72,11 @@ #define CONFIG_ENV_SECT_SIZE CONFIG_ENV_SIZE #define CONFIG_ENV_OFFSET (CONFIG_SPI_FLASH_SIZE - CONFIG_ENV_SECT_SIZE) + +/* USB Host support */ +#define CONFIG_USB_EHCI +#define CONFIG_USB_EHCI_TEGRA +#define CONFIG_USB_STORAGE +#define CONFIG_CMD_USB + #endif /* __CONFIG_H */ -- cgit From d9fdfe0aa598978054f108ba42ca928aceb8c090 Mon Sep 17 00:00:00 2001 From: Simon Glass Date: Mon, 27 Feb 2012 10:52:53 +0000 Subject: tegra: fdt: Enable FDT support for Seaboard This switches Seaboard over to use FDT for run-time config instead of CONFIG options. USB is the only user at present. Signed-off-by: Simon Glass Signed-off-by: Tom Warren --- include/configs/seaboard.h | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'include') diff --git a/include/configs/seaboard.h b/include/configs/seaboard.h index b6d9f7a88f..1dc775a52f 100644 --- a/include/configs/seaboard.h +++ b/include/configs/seaboard.h @@ -27,6 +27,11 @@ #include #include "tegra2-common.h" +/* Enable fdt support for Seaboard. Flash the image in u-boot-dtb.bin */ +#define CONFIG_DEFAULT_DEVICE_TREE tegra2-seaboard +#define CONFIG_OF_CONTROL +#define CONFIG_OF_SEPARATE + /* High-level configuration options */ #define TEGRA2_SYSMEM "mem=384M@0M nvmem=128M@384M mem=512M@512M" #define V_PROMPT "Tegra2 (SeaBoard) # " -- cgit From 66d6a91dc2aa6554c0ad0cdf8b13b18abead8155 Mon Sep 17 00:00:00 2001 From: Tom Warren Date: Tue, 6 Mar 2012 17:10:33 +0000 Subject: tegra: fdt: Enable FDT support for Ventana This switches Ventana over to use FDT for run-time config instead of CONFIG options. At present Ventana does not have its own device tree file - it just uses the Seaboard one. Signed-off-by: Tom Warren Signed-off-by: Simon Glass Acked-by: Simon Glass Signed-off-by: Tom Warren --- include/configs/ventana.h | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'include') diff --git a/include/configs/ventana.h b/include/configs/ventana.h index acc9b434bb..3e55fe5d1a 100644 --- a/include/configs/ventana.h +++ b/include/configs/ventana.h @@ -27,6 +27,11 @@ #include #include "tegra2-common.h" +/* Enable fdt support for Ventana. Flash the image in u-boot-dtb.bin */ +#define CONFIG_DEFAULT_DEVICE_TREE tegra2-seaboard +#define CONFIG_OF_CONTROL +#define CONFIG_OF_SEPARATE + /* High-level configuration options */ #define TEGRA2_SYSMEM "mem=384M@0M nvmem=128M@384M mem=512M@512M" #define V_PROMPT "Tegra2 (Ventana) # " -- cgit From c67822704b73dcfb86debf4c25151e43309af844 Mon Sep 17 00:00:00 2001 From: Simon Glass Date: Fri, 3 Feb 2012 15:13:53 +0000 Subject: fdt: Add function to allow aliases to refer to multiple nodes Some devices can deal with multiple compatible properties. The devices need to know which nodes to bind to which features. For example an I2C driver which supports two different controller types will want to know which type it is dealing with in each case. The new fdtdec_add_aliases_for_id() function deals with this by allowing the driver to search for additional compatible nodes for a different ID. It can then detect the new ones and perform appropriate processing. Another option considered was to return a tuple (node offset, compat id) and have the function be passed a list of compatible IDs. This is more overhead for the common case though. We may add such a function later if more drivers in U-Boot require it. Signed-off-by: Simon Glass Signed-off-by: Tom Warren --- include/fdtdec.h | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) (limited to 'include') diff --git a/include/fdtdec.h b/include/fdtdec.h index 6249f22e81..1e198f8c63 100644 --- a/include/fdtdec.h +++ b/include/fdtdec.h @@ -212,6 +212,29 @@ int fdtdec_check_fdt(void); int fdtdec_find_aliases_for_id(const void *blob, const char *name, enum fdt_compat_id id, int *node_list, int maxcount); +/* + * This function is similar to fdtdec_find_aliases_for_id() except that it + * adds to the node_list that is passed in. Any 0 elements are considered + * available for allocation - others are considered already used and are + * skipped. + * + * You can use this by calling fdtdec_find_aliases_for_id() with an + * uninitialised array, then setting the elements that are returned to -1, + * say, then calling this function, perhaps with a different compat id. + * Any elements you get back that are >0 are new nodes added by the call + * to this function. + * + * Note that if you have some nodes with aliases and some without, you are + * sailing close to the wind. The call to fdtdec_find_aliases_for_id() with + * one compat_id may fill in positions for which you have aliases defined + * for another compat_id. When you later call *this* function with the second + * compat_id, the alias positions may already be used. A debug warning may + * be generated in this case, but it is safest to define aliases for all + * nodes when you care about the ordering. + */ +int fdtdec_add_aliases_for_id(const void *blob, const char *name, + enum fdt_compat_id id, int *node_list, int maxcount); + /* * Get the name for a compatible ID * -- cgit From c360033ffb3b15d64405c9a3aa5216fbf188ff0a Mon Sep 17 00:00:00 2001 From: Simon Glass Date: Fri, 3 Feb 2012 15:13:59 +0000 Subject: tegra: i2c: Select number of controllers for Tegra2 boards The Tegra 2x SOC has four ports, so define TEGRA_I2C_NUM_CONTROLLERS in the shared config file. Signed-off-by: Simon Glass Acked-by: Heiko Schocher Signed-off-by: Tom Warren --- include/configs/tegra2-common.h | 3 +++ 1 file changed, 3 insertions(+) (limited to 'include') diff --git a/include/configs/tegra2-common.h b/include/configs/tegra2-common.h index 266d0e5880..837f859c7c 100644 --- a/include/configs/tegra2-common.h +++ b/include/configs/tegra2-common.h @@ -94,6 +94,9 @@ #define CONFIG_EHCI_IS_TDI #define CONFIG_EHCI_DCACHE +/* Total I2C ports on Tegra2 */ +#define TEGRA_I2C_NUM_CONTROLLERS 4 + /* include default commands */ #include -- cgit From 905fe99b9f7f63f33cb4e669708d29f83ba9676f Mon Sep 17 00:00:00 2001 From: Simon Glass Date: Fri, 3 Feb 2012 15:14:00 +0000 Subject: tegra: i2c: Enable I2C on Seaboard This enables I2C on Seaboard. Signed-off-by: Simon Glass Acked-by: Heiko Schocher Signed-off-by: Tom Warren --- include/configs/seaboard.h | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'include') diff --git a/include/configs/seaboard.h b/include/configs/seaboard.h index 1dc775a52f..ae075e786e 100644 --- a/include/configs/seaboard.h +++ b/include/configs/seaboard.h @@ -59,6 +59,14 @@ #define CONFIG_CMD_SF #define CONFIG_SPI_FLASH_SIZE (4 << 20) +/* I2C */ +#define CONFIG_TEGRA_I2C +#define CONFIG_SYS_I2C_INIT_BOARD +#define CONFIG_I2C_MULTI_BUS +#define CONFIG_SYS_MAX_I2C_BUS 4 +#define CONFIG_SYS_I2C_SPEED 100000 +#define CONFIG_CMD_I2C + /* SD/MMC */ #define CONFIG_MMC #define CONFIG_GENERIC_MMC -- cgit From 96a78ac0c445999ce21fb42ecab061479b4d7056 Mon Sep 17 00:00:00 2001 From: Yen Lin Date: Tue, 6 Mar 2012 19:00:23 +0000 Subject: tegra: i2c: Add I2C driver Add basic i2c driver for Tegra2 with 8- and 16-bit address support. The driver requires CONFIG_OF_CONTROL to obtain its configuration from the device tree. (Simon Glass: sjg@chromium.org modified for upstream) Signed-off-by: Simon Glass Acked-by: Heiko Schocher Acked-by: Stephen Warren Signed-off-by: Tom Warren --- include/fdtdec.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'include') diff --git a/include/fdtdec.h b/include/fdtdec.h index 1e198f8c63..171c628485 100644 --- a/include/fdtdec.h +++ b/include/fdtdec.h @@ -58,6 +58,8 @@ struct fdt_memory { enum fdt_compat_id { COMPAT_UNKNOWN, COMPAT_NVIDIA_TEGRA20_USB, /* Tegra2 USB port */ + COMPAT_NVIDIA_TEGRA20_I2C, /* Tegra2 i2c */ + COMPAT_NVIDIA_TEGRA20_DVC, /* Tegra2 dvc (really just i2c) */ COMPAT_COUNT, }; -- cgit From 76e2c169a525159d48dd005a371fb05e1943c64b Mon Sep 17 00:00:00 2001 From: Tom Rini Date: Wed, 28 Mar 2012 06:26:18 +0000 Subject: OMAP: Remove omap1610inn-based boards The CS_AUTOBOOT configurations have been broken for a long time. Kshitij Gupta is no longer at TI making these broken and orphaned boards, so remove. Signed-off-by: Tom Rini --- include/configs/omap1610h2.h | 197 ---------------------------------------- include/configs/omap1610inn.h | 202 ------------------------------------------ 2 files changed, 399 deletions(-) delete mode 100644 include/configs/omap1610h2.h delete mode 100644 include/configs/omap1610inn.h (limited to 'include') diff --git a/include/configs/omap1610h2.h b/include/configs/omap1610h2.h deleted file mode 100644 index d57e1a79bc..0000000000 --- a/include/configs/omap1610h2.h +++ /dev/null @@ -1,197 +0,0 @@ -/* - * (C) Copyright 2004 - * Texas Instruments. - * Kshitij Gupta - * Configuration settings for the TI OMAP 1610 H2 board. - * - * 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 - */ - -#ifndef __CONFIG_H -#define __CONFIG_H - -/* - * High Level Configuration Options - * (easy to change) - */ -#define CONFIG_ARM926EJS 1 /* This is an arm926ejs CPU core */ -#define CONFIG_OMAP 1 /* in a TI OMAP core */ -#define CONFIG_OMAP1610 1 /* which is in a 1610 */ -#define CONFIG_H2_OMAP1610 1 /* on an H2 Board */ - -#define CONFIG_MACH_TYPE MACH_TYPE_OMAP_H2 - -/* input clock of PLL */ -/* the OMAP1610 H2 has 12MHz input clock */ -#define CONFIG_SYS_CLK_FREQ 12000000 - -#undef CONFIG_USE_IRQ /* we don't need IRQ/FIQ stuff */ - -#define CONFIG_MISC_INIT_R - -#define CONFIG_CMDLINE_TAG 1 /* enable passing of ATAGs */ -#define CONFIG_SETUP_MEMORY_TAGS 1 -#define CONFIG_INITRD_TAG 1 - -/* - * Size of malloc() pool - */ -#define CONFIG_SYS_MALLOC_LEN (CONFIG_ENV_SIZE + 128*1024) - -/* - * Hardware drivers - */ -#define CONFIG_LAN91C96 -#define CONFIG_LAN91C96_BASE 0x04000300 -#define CONFIG_LAN91C96_EXT_PHY - -/* - * NS16550 Configuration - */ -#define CONFIG_SYS_NS16550 -#define CONFIG_SYS_NS16550_SERIAL -#define CONFIG_SYS_NS16550_REG_SIZE (-4) -#define CONFIG_SYS_NS16550_CLK (48000000) /* can be 12M/32Khz or 48Mhz */ -#define CONFIG_SYS_NS16550_COM1 0xfffb0000 /* uart1, bluetooth uart */ - -/* - * select serial console configuration - */ -#define CONFIG_SERIAL1 1 /* we use SERIAL 1 on OMAP1610 H2 */ - -/* allow to overwrite serial and ethaddr */ -#define CONFIG_ENV_OVERWRITE -#define CONFIG_CONS_INDEX 1 -#define CONFIG_BAUDRATE 115200 -#define CONFIG_SYS_BAUDRATE_TABLE { 9600, 19200, 38400, 57600, 115200 } - - -/* - * Command line configuration. - */ -#include - -#define CONFIG_CMD_DHCP - - -/* - * BOOTP options - */ -#define CONFIG_BOOTP_SUBNETMASK -#define CONFIG_BOOTP_GATEWAY -#define CONFIG_BOOTP_HOSTNAME -#define CONFIG_BOOTP_BOOTPATH - - -#include - -#define CONFIG_BOOTDELAY 3 -#define CONFIG_BOOTARGS "console=ttyS0,115200n8 noinitrd root=/dev/nfs ip=dhcp" -#define CONFIG_BOOTCOMMAND "bootp;tftp;bootm" -#define CONFIG_SYS_AUTOLOAD "n" /* No autoload */ - -#if defined(CONFIG_CMD_KGDB) -#define CONFIG_KGDB_BAUDRATE 115200 /* speed to run kgdb serial port */ -#define CONFIG_KGDB_SER_INDEX 1 /* which serial port to use */ -#endif - -/* - * Miscellaneous configurable options - */ -#define CONFIG_SYS_LONGHELP /* undef to save memory */ -#define CONFIG_SYS_PROMPT "OMAP1610 H2 # " /* Monitor Command Prompt */ -#define CONFIG_SYS_CBSIZE 256 /* Console I/O Buffer Size */ -/* Print Buffer Size */ -#define CONFIG_SYS_PBSIZE (CONFIG_SYS_CBSIZE+sizeof(CONFIG_SYS_PROMPT)+16) -#define CONFIG_SYS_MAXARGS 16 /* max number of command args */ -#define CONFIG_SYS_BARGSIZE CONFIG_SYS_CBSIZE /* Boot Argument Buffer Size */ - -#define CONFIG_SYS_MEMTEST_START 0x10000000 /* memtest works on */ -#define CONFIG_SYS_MEMTEST_END 0x12000000 /* 32 MB in DRAM */ - -#define CONFIG_SYS_LOAD_ADDR 0x10000000 /* default load address */ - -/* The 1610 has 6 timers, they can be driven by the RefClk (12Mhz) or by - * DPLL1. This time is further subdivided by a local divisor. - */ -#define CONFIG_SYS_TIMERBASE 0xFFFEC500 /* use timer 1 */ -#define CONFIG_SYS_PTV 7 /* 2^(PTV+1), divide by 256 */ -#define CONFIG_SYS_HZ ((CONFIG_SYS_CLK_FREQ)/(2 << CONFIG_SYS_PTV)) - -/*----------------------------------------------------------------------- - * Stack sizes - * - * The stack sizes are set up in start.S using the settings below - */ -#define CONFIG_STACKSIZE (128*1024) /* regular stack */ -#ifdef CONFIG_USE_IRQ -#define CONFIG_STACKSIZE_IRQ (4*1024) /* IRQ stack */ -#define CONFIG_STACKSIZE_FIQ (4*1024) /* FIQ stack */ -#endif - -/*----------------------------------------------------------------------- - * Physical Memory Map - */ -#define CONFIG_NR_DRAM_BANKS 1 /* we have 1 bank of DRAM */ -#define PHYS_SDRAM_1 0x10000000 /* SDRAM Bank #1 */ -#define PHYS_SDRAM_1_SIZE 0x02000000 /* 32 MB */ - -#define PHYS_FLASH_1_BM1 0x00000000 /* Flash Bank #1 if booting from flash */ -#define PHYS_FLASH_1_BM0 0x0C000000 /* Flash Bank #1 if booting from RAM */ - -#ifdef CONFIG_CS_AUTOBOOT /* Determine CS assignment in runtime */ - -#ifndef __ASSEMBLY__ -extern unsigned long omap_flash_base; /* set in flash__init */ -#endif -#define CONFIG_SYS_FLASH_BASE omap_flash_base - -#elif defined(CONFIG_CS0_BOOT) - -#define CONFIG_SYS_FLASH_BASE PHYS_FLASH_1_BM0 - -#else - -#define CONFIG_SYS_FLASH_BASE PHYS_FLASH_1_BM1 - -#endif - -#define PHYS_SRAM 0x20000000 - -/*----------------------------------------------------------------------- - * FLASH and environment organization - */ -#define CONFIG_SYS_MAX_FLASH_BANKS 1 /* max number of memory banks */ -#define PHYS_FLASH_SIZE 0x02000000 /* 32MB */ -#define CONFIG_SYS_MAX_FLASH_SECT (259) /* max number of sectors on one chip */ -/* addr of environment */ -#define CONFIG_ENV_ADDR (CONFIG_SYS_FLASH_BASE + 0x020000) - -/* timeout values are in ticks */ -#define CONFIG_SYS_FLASH_ERASE_TOUT (20*CONFIG_SYS_HZ) /* Timeout for Flash Erase */ -#define CONFIG_SYS_FLASH_WRITE_TOUT (20*CONFIG_SYS_HZ) /* Timeout for Flash Write */ - -#define CONFIG_ENV_IS_IN_FLASH 1 -#define CONFIG_ENV_SIZE 0x20000 /* Total Size of Environment Sector */ -#define CONFIG_ENV_OFFSET 0x20000 /* environment starts here */ - -#define CONFIG_SYS_SDRAM_BASE PHYS_SDRAM_1 -#define CONFIG_SYS_INIT_SP_ADDR PHYS_SRAM - -#endif /* __CONFIG_H */ diff --git a/include/configs/omap1610inn.h b/include/configs/omap1610inn.h deleted file mode 100644 index 7901b6c94e..0000000000 --- a/include/configs/omap1610inn.h +++ /dev/null @@ -1,202 +0,0 @@ -/* - * (C) Copyright 2003 - * Texas Instruments. - * Kshitij Gupta - * Configuation settings for the TI OMAP Innovator board. - * - * 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 - */ - -#ifndef __CONFIG_H -#define __CONFIG_H - -/* - * High Level Configuration Options - * (easy to change) - */ -#define CONFIG_ARM926EJS 1 /* This is an arm926ejs CPU core */ -#define CONFIG_OMAP 1 /* in a TI OMAP core */ -#define CONFIG_OMAP1610 1 /* which is in a 1610 */ -#define CONFIG_INNOVATOROMAP1610 1 /* a Innovator Board */ - -#define CONFIG_MACH_TYPE MACH_TYPE_OMAP_INNOVATOR - -/* input clock of PLL */ -/* the OMAP1610 Innovator has 12MHz input clock */ -#define CONFIG_SYS_CLK_FREQ 12000000 - -#undef CONFIG_USE_IRQ /* we don't need IRQ/FIQ stuff */ - -#define CONFIG_MISC_INIT_R - -#define CONFIG_CMDLINE_TAG 1 /* enable passing of ATAGs */ -#define CONFIG_SETUP_MEMORY_TAGS 1 - -/* - * Size of malloc() pool - */ -#define CONFIG_SYS_MALLOC_LEN (CONFIG_ENV_SIZE + 128*1024) - -/* - * Hardware drivers - */ -/* -*/ -#define CONFIG_LAN91C96 -#define CONFIG_LAN91C96_BASE 0x04000300 -#define CONFIG_LAN91C96_EXT_PHY - -/* - * NS16550 Configuration - */ -#define CONFIG_SYS_NS16550 -#define CONFIG_SYS_NS16550_SERIAL -#define CONFIG_SYS_NS16550_REG_SIZE (-4) -#define CONFIG_SYS_NS16550_CLK (48000000) /* can be 12M/32Khz or 48Mhz */ -#define CONFIG_SYS_NS16550_COM1 0xfffb0000 /* uart1, bluetooth uart on helen */ - -/* - * select serial console configuration - */ -#define CONFIG_SERIAL1 1 /* we use SERIAL 1 on OMAP1610 Innovator */ - -/* allow to overwrite serial and ethaddr */ -#define CONFIG_ENV_OVERWRITE -#define CONFIG_CONS_INDEX 1 -#define CONFIG_BAUDRATE 115200 -#define CONFIG_SYS_BAUDRATE_TABLE { 9600, 19200, 38400, 57600, 115200 } - - -/* - * Command line configuration. - */ -#include - -#define CONFIG_CMD_DHCP - - -/* - * BOOTP options - */ -#define CONFIG_BOOTP_SUBNETMASK -#define CONFIG_BOOTP_GATEWAY -#define CONFIG_BOOTP_HOSTNAME -#define CONFIG_BOOTP_BOOTPATH - - -#include - -#define CONFIG_BOOTDELAY 3 -#define CONFIG_BOOTARGS "mem=32M console=ttyS0,115200n8 noinitrd \ - root=/dev/nfs rw nfsroot=157.87.82.48:\ - /home/a0875451/mwd/myfs/target ip=dhcp" -#define CONFIG_NETMASK 255.255.254.0 /* talk on MY local net */ -#define CONFIG_IPADDR 156.117.97.156 /* static IP I currently own */ -#define CONFIG_SERVERIP 156.117.97.139 /* current IP of my dev pc */ -#define CONFIG_BOOTFILE "uImage" /* file to load */ - -#if defined(CONFIG_CMD_KGDB) -#define CONFIG_KGDB_BAUDRATE 115200 /* speed to run kgdb serial port */ -#define CONFIG_KGDB_SER_INDEX 1 /* which serial port to use */ -#endif - -/* - * Miscellaneous configurable options - */ -#define CONFIG_SYS_LONGHELP /* undef to save memory */ -#define CONFIG_SYS_PROMPT "OMAP1610 Innovator # " /* Monitor Command Prompt */ -#define CONFIG_SYS_CBSIZE 256 /* Console I/O Buffer Size */ -/* Print Buffer Size */ -#define CONFIG_SYS_PBSIZE (CONFIG_SYS_CBSIZE+sizeof(CONFIG_SYS_PROMPT)+16) -#define CONFIG_SYS_MAXARGS 16 /* max number of command args */ -#define CONFIG_SYS_BARGSIZE CONFIG_SYS_CBSIZE /* Boot Argument Buffer Size */ - -#define CONFIG_SYS_MEMTEST_START 0x10000000 /* memtest works on */ -#define CONFIG_SYS_MEMTEST_END 0x12000000 /* 32 MB in DRAM */ - -#define CONFIG_SYS_LOAD_ADDR 0x10000000 /* default load address */ - -/* The 1610 has 6 timers, they can be driven by the RefClk (12Mhz) or by - * DPLL1. This time is further subdivided by a local divisor. - */ -#define CONFIG_SYS_TIMERBASE 0xFFFEC500 /* use timer 1 */ -#define CONFIG_SYS_PTV 7 /* 2^(PTV+1), divide by 256 */ -#define CONFIG_SYS_HZ ((CONFIG_SYS_CLK_FREQ)/(2 << CONFIG_SYS_PTV)) - -/*----------------------------------------------------------------------- - * Stack sizes - * - * The stack sizes are set up in start.S using the settings below - */ -#define CONFIG_STACKSIZE (128*1024) /* regular stack */ -#ifdef CONFIG_USE_IRQ -#define CONFIG_STACKSIZE_IRQ (4*1024) /* IRQ stack */ -#define CONFIG_STACKSIZE_FIQ (4*1024) /* FIQ stack */ -#endif - -/*----------------------------------------------------------------------- - * Physical Memory Map - */ -#define CONFIG_NR_DRAM_BANKS 1 /* we have 1 bank of DRAM */ -#define PHYS_SDRAM_1 0x10000000 /* SDRAM Bank #1 */ -#define PHYS_SDRAM_1_SIZE 0x02000000 /* 32 MB */ - -#define PHYS_FLASH_1_BM1 0x00000000 /* Flash Bank #1 if booting from flash */ -#define PHYS_FLASH_1_BM0 0x0C000000 /* Flash Bank #1 if booting from RAM */ - -#ifdef CONFIG_CS_AUTOBOOT /* Determine CS assignment in runtime */ - -#ifndef __ASSEMBLY__ -extern unsigned long omap_flash_base; /* set in flash__init */ -#endif -#define CONFIG_SYS_FLASH_BASE omap_flash_base - -#elif defined(CONFIG_CS0_BOOT) - -#define CONFIG_SYS_FLASH_BASE PHYS_FLASH_1_BM0 - -#else - -#define CONFIG_SYS_FLASH_BASE PHYS_FLASH_1_BM1 - -#endif - -#define PHYS_SRAM 0x20000000 - -/*----------------------------------------------------------------------- - * FLASH and environment organization - */ -#define CONFIG_SYS_MAX_FLASH_BANKS 1 /* max number of memory banks */ -#define PHYS_FLASH_SIZE 0x02000000 /* 32MB */ -#define CONFIG_SYS_MAX_FLASH_SECT (259) /* max number of sectors on one chip */ -/* addr of environment */ -#define CONFIG_ENV_ADDR (CONFIG_SYS_FLASH_BASE + 0x020000) - -/* timeout values are in ticks */ -#define CONFIG_SYS_FLASH_ERASE_TOUT (20*CONFIG_SYS_HZ) /* Timeout for Flash Erase */ -#define CONFIG_SYS_FLASH_WRITE_TOUT (20*CONFIG_SYS_HZ) /* Timeout for Flash Write */ - -#define CONFIG_ENV_IS_IN_FLASH 1 -#define CONFIG_ENV_SIZE 0x20000 /* Total Size of Environment Sector */ -#define CONFIG_ENV_OFFSET 0x20000 /* environment starts here */ - -#define CONFIG_SYS_SDRAM_BASE PHYS_SDRAM_1 -#define CONFIG_SYS_INIT_SP_ADDR PHYS_SRAM - -#endif /* __CONFIG_H */ -- cgit