diff options
Diffstat (limited to 'board/freescale/mpc8313erdb')
-rw-r--r-- | board/freescale/mpc8313erdb/mpc8313erdb.c | 4 | ||||
-rw-r--r-- | board/freescale/mpc8313erdb/sdram.c | 8 |
2 files changed, 7 insertions, 5 deletions
diff --git a/board/freescale/mpc8313erdb/mpc8313erdb.c b/board/freescale/mpc8313erdb/mpc8313erdb.c index eac193e817..8974378326 100644 --- a/board/freescale/mpc8313erdb/mpc8313erdb.c +++ b/board/freescale/mpc8313erdb/mpc8313erdb.c @@ -133,8 +133,8 @@ void board_init_f(ulong bootflag) NS16550_init((NS16550_t)(CONFIG_SYS_IMMR + 0x4500), CONFIG_SYS_NS16550_CLK / 16 / CONFIG_BAUDRATE); puts("NAND boot... "); - init_timebase(); - initdram(0); + timer_init(); + dram_init(); relocate_code(CONFIG_SYS_NAND_U_BOOT_RELOC_SP, (gd_t *)gd, CONFIG_SYS_NAND_U_BOOT_RELOC); } diff --git a/board/freescale/mpc8313erdb/sdram.c b/board/freescale/mpc8313erdb/sdram.c index 6282c3d920..a4128cbd11 100644 --- a/board/freescale/mpc8313erdb/sdram.c +++ b/board/freescale/mpc8313erdb/sdram.c @@ -97,14 +97,14 @@ static long fixed_sdram(void) return msize; } -phys_size_t initdram(int board_type) +int dram_init(void) { volatile immap_t *im = (volatile immap_t *)CONFIG_SYS_IMMR; volatile fsl_lbc_t *lbc = &im->im_lbc; u32 msize; if ((im->sysconf.immrbar & IMMRBAR_BASE_ADDR) != (u32)im) - return -1; + return -ENXIO; /* DDR SDRAM - Main SODIMM */ msize = fixed_sdram(); @@ -120,5 +120,7 @@ phys_size_t initdram(int board_type) #endif /* return total bus SDRAM size(bytes) -- DDR */ - return msize; + gd->ram_size = msize; + + return 0; } |