diff options
author | Steve Kipisz <s-kipisz2@ti.com> | 2013-07-18 15:13:03 -0400 |
---|---|---|
committer | Tom Rini <trini@ti.com> | 2013-07-30 09:21:41 -0400 |
commit | cd8845d7a49687e9e7f727c9d821accf22854dd3 (patch) | |
tree | a45912edaf22760b46f43ca03f8f7e10a81af7b7 /board/ti/am335x/board.c | |
parent | 392bba4ad0049832f50eb368a04992f9719744b0 (diff) | |
download | u-boot-imx-cd8845d7a49687e9e7f727c9d821accf22854dd3.zip u-boot-imx-cd8845d7a49687e9e7f727c9d821accf22854dd3.tar.gz u-boot-imx-cd8845d7a49687e9e7f727c9d821accf22854dd3.tar.bz2 |
am335x_evm: Add support for the NOR module on the memory cape
This patch adds support for the NOR module that attaches
to the memory cape for a Beaglebone board. This does not
add booting support; only support so that you can boot from
SD/MMC and see the NOR module so that it can be programmed.
Signed-off-by: Steve Kipisz <s-kipisz2@ti.com>
[trini: Clean up config changes slightly]
Signed-off-by: Tom Rini <trini@ti.com>
Diffstat (limited to 'board/ti/am335x/board.c')
-rw-r--r-- | board/ti/am335x/board.c | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/board/ti/am335x/board.c b/board/ti/am335x/board.c index 00802b6..b12341d 100644 --- a/board/ti/am335x/board.c +++ b/board/ti/am335x/board.c @@ -19,6 +19,7 @@ #include <asm/arch/gpio.h> #include <asm/arch/mmc_host_def.h> #include <asm/arch/sys_proto.h> +#include <asm/arch/mem.h> #include <asm/io.h> #include <asm/emif.h> #include <asm/gpio.h> @@ -339,10 +340,22 @@ void s_init(void) */ int board_init(void) { +#ifdef CONFIG_NOR + const u32 gpmc_nor[GPMC_MAX_REG] = { STNOR_GPMC_CONFIG1, + STNOR_GPMC_CONFIG2, STNOR_GPMC_CONFIG3, STNOR_GPMC_CONFIG4, + STNOR_GPMC_CONFIG5, STNOR_GPMC_CONFIG6, STNOR_GPMC_CONFIG7 }; +#endif + gd->bd->bi_boot_params = PHYS_DRAM_1 + 0x100; gpmc_init(); +#ifdef CONFIG_NOR + /* Reconfigure CS0 for NOR instead of NAND. */ + enable_gpmc_cs_config(gpmc_nor, &gpmc_cfg->cs[0], + CONFIG_SYS_FLASH_BASE, GPMC_SIZE_16M); +#endif + return 0; } |