diff options
Diffstat (limited to 'board/davinci')
| -rw-r--r-- | board/davinci/da8xxevm/da830evm.c | 63 | ||||
| -rw-r--r-- | board/davinci/da8xxevm/da850evm.c | 23 |
2 files changed, 77 insertions, 9 deletions
diff --git a/board/davinci/da8xxevm/da830evm.c b/board/davinci/da8xxevm/da830evm.c index 06506537b..2021e7324 100644 --- a/board/davinci/da8xxevm/da830evm.c +++ b/board/davinci/da8xxevm/da830evm.c @@ -40,6 +40,8 @@ #include <asm/arch/emif_defs.h> #include <asm/arch/emac_defs.h> #include <asm/io.h> +#include <nand.h> +#include <asm/arch/nand_defs.h> #include <asm/arch/davinci_misc.h> DECLARE_GLOBAL_DATA_PTR; @@ -98,6 +100,56 @@ static const struct pinmux_config i2c_pins[] = { { pinmux(8), 2, 4 } }; +#ifdef CONFIG_USE_NAND +/* NAND pin muxer settings */ +const struct pinmux_config aemif_pins[] = { + { pinmux(13), 1, 6 }, + { pinmux(13), 1, 7 }, + { pinmux(14), 1, 0 }, + { pinmux(14), 1, 1 }, + { pinmux(14), 1, 2 }, + { pinmux(14), 1, 3 }, + { pinmux(14), 1, 4 }, + { pinmux(14), 1, 5 }, + { pinmux(14), 1, 6 }, + { pinmux(14), 1, 7 }, + { pinmux(15), 1, 0 }, + { pinmux(15), 1, 1 }, + { pinmux(15), 1, 2 }, + { pinmux(15), 1, 3 }, + { pinmux(15), 1, 4 }, + { pinmux(15), 1, 5 }, + { pinmux(15), 1, 6 }, + { pinmux(15), 1, 7 }, + { pinmux(16), 1, 0 }, + { pinmux(16), 1, 1 }, + { pinmux(16), 1, 2 }, + { pinmux(16), 1, 3 }, + { pinmux(16), 1, 4 }, + { pinmux(16), 1, 5 }, + { pinmux(16), 1, 6 }, + { pinmux(16), 1, 7 }, + { pinmux(17), 1, 0 }, + { pinmux(17), 1, 1 }, + { pinmux(17), 1, 2 }, + { pinmux(17), 1, 3 }, + { pinmux(17), 1, 4 }, + { pinmux(17), 1, 5 }, + { pinmux(17), 1, 6 }, + { pinmux(17), 1, 7 }, + { pinmux(18), 1, 0 }, + { pinmux(18), 1, 1 }, + { pinmux(18), 1, 2 }, + { pinmux(18), 1, 3 }, + { pinmux(18), 1, 4 }, + { pinmux(18), 1, 5 }, + { pinmux(18), 1, 6 }, + { pinmux(18), 1, 7 }, + { pinmux(10), 1, 0 } +}; +#endif + + /* USB0_DRVVBUS pin muxer settings */ static const struct pinmux_config usb_pins[] = { { pinmux(9), 1, 1 } @@ -114,6 +166,7 @@ static const struct pinmux_resource pinmuxes[] = { #endif #ifdef CONFIG_USE_NAND PINMUX_ITEM(emifa_nand_pins), + PINMUX_ITEM(aemif_pins), #endif #if defined(CONFIG_DRIVER_TI_EMAC) PINMUX_ITEM(emac_pins), @@ -184,6 +237,16 @@ int board_init(void) return(0); } + +#ifdef CONFIG_NAND_DAVINCI +int board_nand_init(struct nand_chip *nand) +{ + davinci_nand_init(nand); + + return 0; +} +#endif + #if defined(CONFIG_DRIVER_TI_EMAC) #define PHY_SW_I2C_ADDR 0x5f /* Address of PHY on i2c bus */ diff --git a/board/davinci/da8xxevm/da850evm.c b/board/davinci/da8xxevm/da850evm.c index 46924d349..e0a3bbefc 100644 --- a/board/davinci/da8xxevm/da850evm.c +++ b/board/davinci/da8xxevm/da850evm.c @@ -278,6 +278,20 @@ u32 get_board_rev(void) return rev; } +int board_early_init_f(void) +{ + /* + * Power on required peripherals + * ARM does not have access by default to PSC0 and PSC1 + * assuming here that the DSP bootloader has set the IOPU + * such that PSC access is available to ARM + */ + if (da8xx_configure_lpsc_items(lpsc, ARRAY_SIZE(lpsc))) + return 1; + + return 0; +} + int board_init(void) { #ifdef CONFIG_USE_NOR @@ -310,15 +324,6 @@ int board_init(void) /* address of boot parameters */ gd->bd->bi_boot_params = LINUX_BOOT_PARAM_ADDR; - /* - * Power on required peripherals - * ARM does not have access by default to PSC0 and PSC1 - * assuming here that the DSP bootloader has set the IOPU - * such that PSC access is available to ARM - */ - if (da8xx_configure_lpsc_items(lpsc, ARRAY_SIZE(lpsc))) - return 1; - /* setup the SUSPSRC for ARM to control emulation suspend */ writel(readl(&davinci_syscfg_regs->suspsrc) & ~(DAVINCI_SYSCFG_SUSPSRC_EMAC | DAVINCI_SYSCFG_SUSPSRC_I2C | |