summaryrefslogtreecommitdiff
path: root/board/BuR
diff options
context:
space:
mode:
Diffstat (limited to 'board/BuR')
-rw-r--r--board/BuR/common/common.c15
-rw-r--r--board/BuR/tseries/board.c3
-rw-r--r--board/BuR/tseries/mux.c2
3 files changed, 15 insertions, 5 deletions
diff --git a/board/BuR/common/common.c b/board/BuR/common/common.c
index e85064a677..23a98e4fdf 100644
--- a/board/BuR/common/common.c
+++ b/board/BuR/common/common.c
@@ -33,6 +33,7 @@
#endif
#include "bur_common.h"
#include "../../../drivers/video/am335x-fb.h"
+#include <nand.h>
static struct ctrl_dev *cdev = (struct ctrl_dev *)CTRL_DEVICE_BASE;
@@ -159,17 +160,22 @@ int load_lcdtiming(struct am335x_lcdpanel *panel)
#ifdef CONFIG_USE_FDT
static int load_devicetree(void)
{
- char *dtbname = getenv("dtb");
- char *dtbdev = getenv("dtbdev");
- char *dtppart = getenv("dtbpart");
- u32 dtbaddr = getenv_ulong("dtbaddr", 16, 0UL);
int rc;
loff_t dtbsize;
+ u32 dtbaddr = getenv_ulong("dtbaddr", 16, 0UL);
if (dtbaddr == 0) {
printf("%s: don't have a valid <dtbaddr> in env!\n", __func__);
return -1;
}
+#ifdef CONFIG_NAND
+ dtbsize = 0x20000;
+ rc = nand_read_skip_bad(&nand_info[0], 0x40000, (size_t *)&dtbsize,
+ NULL, 0x20000, (u_char *)dtbaddr);
+#else
+ char *dtbname = getenv("dtb");
+ char *dtbdev = getenv("dtbdev");
+ char *dtppart = getenv("dtbpart");
if (!dtbdev || !dtbdev || !dtbname) {
printf("%s: <dtbdev>/<dtbpart>/<dtb> missing.\n", __func__);
return -1;
@@ -180,6 +186,7 @@ static int load_devicetree(void)
return -1;
}
rc = fs_read(dtbname, (u32)dtbaddr, 0, 0, &dtbsize);
+#endif
if (rc == 0) {
gd->fdt_blob = (void *)dtbaddr;
gd->fdt_size = dtbsize;
diff --git a/board/BuR/tseries/board.c b/board/BuR/tseries/board.c
index 89e989f246..d1d698e7d2 100644
--- a/board/BuR/tseries/board.c
+++ b/board/BuR/tseries/board.c
@@ -128,6 +128,9 @@ void am33xx_spl_board_init(void)
i2c_set_bus_num(0);
i2c_init(CONFIG_SYS_OMAP24_I2C_SPEED, CONFIG_SYS_OMAP24_I2C_SLAVE);
pmicsetup(0);
+
+ gpio_direction_output(64+29, 1); /* switch NAND_RnB to GPMC_WAIT1 */
+ gpio_direction_output(64+28, 1); /* switch MII2_CRS to GPMC_WAIT0 */
}
const struct dpll_params *get_dpll_ddr_params(void)
diff --git a/board/BuR/tseries/mux.c b/board/BuR/tseries/mux.c
index ac7e885f61..caedf009a3 100644
--- a/board/BuR/tseries/mux.c
+++ b/board/BuR/tseries/mux.c
@@ -123,7 +123,7 @@ static struct module_pin_mux nand_pin_mux[] = {
{OFFSET(gpmc_ad5), (MODE(0) | PULLUP_EN | RXACTIVE)}, /* NAND AD5 */
{OFFSET(gpmc_ad6), (MODE(0) | PULLUP_EN | RXACTIVE)}, /* NAND AD6 */
{OFFSET(gpmc_ad7), (MODE(0) | PULLUP_EN | RXACTIVE)}, /* NAND AD7 */
- {OFFSET(gpmc_wait0), (MODE(0) | RXACTIVE | PULLUP_EN)}, /* NAND WAIT */
+ {OFFSET(gpmc_clk), (MODE(2) | RXACTIVE | PULLUP_EN)}, /* NAND WAIT */
{OFFSET(gpmc_wpn), (MODE(7) | PULLUP_EN | RXACTIVE)}, /* NAND_WPN */
{OFFSET(gpmc_csn0), (MODE(0) | PULLUDEN)}, /* NAND_CS0 */
{OFFSET(gpmc_advn_ale), (MODE(0) | PULLUDEN)}, /* NAND_ADV_ALE */