]> git.kernelconcepts.de Git - karo-tx-uboot.git/blobdiff - arch/nds32/lib/board.c
Replace __bss_end__ with __bss_end
[karo-tx-uboot.git] / arch / nds32 / lib / board.c
index 2164a505f6e7a9b4677290ba4931aba28af33ec4..a7d27fc7f8e78ec43ef635f181e84e5209cf16e1 100644 (file)
@@ -192,7 +192,7 @@ void board_init_f(ulong bootflag)
 
        memset((void *)gd, 0, GENERATED_GBL_DATA_SIZE);
 
-       gd->mon_len = (unsigned int)(&__bss_end__) - (unsigned int)(&_start);
+       gd->mon_len = (unsigned int)(&__bss_end) - (unsigned int)(&_start);
 
        for (init_fnc_ptr = init_sequence; *init_fnc_ptr; ++init_fnc_ptr) {
                if ((*init_fnc_ptr)() != 0)
@@ -207,17 +207,6 @@ void board_init_f(ulong bootflag)
 
        addr = CONFIG_SYS_SDRAM_BASE + gd->ram_size;
 
-#if !(defined(CONFIG_SYS_ICACHE_OFF) && defined(CONFIG_SYS_DCACHE_OFF))
-       /* reserve TLB table */
-       addr -= (4096 * 4);
-
-       /* round down to next 64 kB limit */
-       addr &= ~(0x10000 - 1);
-
-       gd->tlb_addr = addr;
-       debug("TLB table at: %08lx\n", addr);
-#endif
-
        /* round down to next 4 kB limit */
        addr &= ~(4096 - 1);
        debug("Top of RAM usable for U-Boot at: %08lx\n", addr);
@@ -306,8 +295,6 @@ void board_init_r(gd_t *id, ulong dest_addr)
        bd_t *bd;
        ulong malloc_start;
 
-       extern void malloc_bin_reloc(void);
-
        gd = id;
        bd = gd->bd;
 
@@ -322,20 +309,17 @@ void board_init_r(gd_t *id, ulong dest_addr)
        /*
         * We have to relocate the command table manually
         */
-       fixup_cmdtable(&__u_boot_cmd_start,
-               (ulong)(&__u_boot_cmd_end - &__u_boot_cmd_start));
+       fixup_cmdtable(ll_entry_start(cmd_tbl_t, cmd),
+                       ll_entry_count(cmd_tbl_t, cmd));
 #endif /* defined(CONFIG_NEEDS_MANUAL_RELOC) */
 
-#ifdef CONFIG_SERIAL_MULTI
        serial_initialize();
-#endif
 
        debug("Now running in RAM - U-Boot at: %08lx\n", dest_addr);
 
        /* The Malloc area is immediately below the monitor copy in DRAM */
        malloc_start = dest_addr - TOTAL_MALLOC_LEN;
        mem_malloc_init(malloc_start, TOTAL_MALLOC_LEN);
-       malloc_bin_reloc();
 
 #ifndef CONFIG_SYS_NO_FLASH
        /* configure available FLASH banks */
@@ -400,7 +384,7 @@ void board_init_r(gd_t *id, ulong dest_addr)
        /* Initialize from environment */
        load_addr = getenv_ulong("loadaddr", 16, load_addr);
 
-#ifdef BOARD_LATE_INIT
+#ifdef CONFIG_BOARD_LATE_INIT
        board_late_init();
 #endif