diff options
Diffstat (limited to 'arch')
-rw-r--r-- | arch/arm/cpu/armv7/omap4/board.c | 30 | ||||
-rw-r--r-- | arch/arm/cpu/ixp/npe/IxNpeDlNpeMgr.c | 5 | ||||
-rw-r--r-- | arch/arm/include/asm/arch-omap4/omap4.h | 10 | ||||
-rw-r--r-- | arch/blackfin/include/asm/config-pre.h | 3 | ||||
-rw-r--r-- | arch/blackfin/lib/Makefile | 2 | ||||
-rw-r--r-- | arch/blackfin/lib/board.c | 1 | ||||
-rw-r--r-- | arch/blackfin/lib/post.c | 421 | ||||
-rw-r--r-- | arch/powerpc/cpu/mpc512x/Makefile | 1 | ||||
-rw-r--r-- | arch/powerpc/cpu/mpc512x/common.c | 25 | ||||
-rw-r--r-- | arch/powerpc/cpu/mpc8260/commproc.c | 20 | ||||
-rw-r--r-- | arch/powerpc/cpu/mpc85xx/commproc.c | 20 | ||||
-rw-r--r-- | arch/powerpc/cpu/mpc8xx/commproc.c | 20 | ||||
-rw-r--r-- | arch/powerpc/cpu/ppc4xx/Makefile | 1 | ||||
-rw-r--r-- | arch/powerpc/cpu/ppc4xx/commproc.c | 53 | ||||
-rw-r--r-- | arch/powerpc/cpu/ppc4xx/fdt.c | 10 |
15 files changed, 48 insertions, 574 deletions
diff --git a/arch/arm/cpu/armv7/omap4/board.c b/arch/arm/cpu/armv7/omap4/board.c index 195be6eea13..8c1f3953edd 100644 --- a/arch/arm/cpu/armv7/omap4/board.c +++ b/arch/arm/cpu/armv7/omap4/board.c @@ -30,6 +30,7 @@ #include <common.h> #include <asm/arch/cpu.h> #include <asm/arch/sys_proto.h> +#include <asm/sizes.h> /* * Routine: s_init @@ -66,6 +67,33 @@ void watchdog_init(void) writel(WD_UNLOCK2, &wd2_base->wspr); } + +/* + * This function finds the SDRAM size available in the system + * based on DMM section configurations + * This is needed because the size of memory installed may be + * different on different versions of the board + */ +u32 sdram_size(void) +{ + u32 section, i, total_size = 0, size, addr; + for (i = 0; i < 4; i++) { + section = __raw_readl(DMM_LISA_MAP_BASE + i*4); + addr = section & DMM_LISA_MAP_SYS_ADDR_MASK; + /* See if the address is valid */ + if ((addr >= OMAP44XX_DRAM_ADDR_SPACE_START) && + (addr < OMAP44XX_DRAM_ADDR_SPACE_END)) { + size = ((section & DMM_LISA_MAP_SYS_SIZE_MASK) >> + DMM_LISA_MAP_SYS_SIZE_SHIFT); + size = 1 << size; + size *= SZ_16M; + total_size += size; + } + } + return total_size; +} + + /* * Routine: dram_init * Description: sets uboots idea of sdram size @@ -75,7 +103,7 @@ int dram_init(void) DECLARE_GLOBAL_DATA_PTR; gd->bd->bi_dram[0].start = 0x80000000; - gd->bd->bi_dram[0].size = 512 << 20; + gd->bd->bi_dram[0].size = sdram_size(); return 0; } diff --git a/arch/arm/cpu/ixp/npe/IxNpeDlNpeMgr.c b/arch/arm/cpu/ixp/npe/IxNpeDlNpeMgr.c index f5a4c5f508f..a9ea8bc103f 100644 --- a/arch/arm/cpu/ixp/npe/IxNpeDlNpeMgr.c +++ b/arch/arm/cpu/ixp/npe/IxNpeDlNpeMgr.c @@ -51,11 +51,6 @@ /* * Put the user defined include files required. */ - - -/* - * Put the user defined include files required. - */ #include "IxOsal.h" #include "IxNpeDl.h" #include "IxNpeDlNpeMgr_p.h" diff --git a/arch/arm/include/asm/arch-omap4/omap4.h b/arch/arm/include/asm/arch-omap4/omap4.h index d0c808d1217..a30bb332e8b 100644 --- a/arch/arm/include/asm/arch-omap4/omap4.h +++ b/arch/arm/include/asm/arch-omap4/omap4.h @@ -42,6 +42,10 @@ #define OMAP44XX_L4_WKUP_BASE 0x4A300000 #define OMAP44XX_L4_PER_BASE 0x48000000 +#define OMAP44XX_DRAM_ADDR_SPACE_START 0x80000000 +#define OMAP44XX_DRAM_ADDR_SPACE_END 0xD0000000 + + /* CONTROL */ #define CTRL_BASE (OMAP44XX_L4_CORE_BASE + 0x2000) #define CONTROL_PADCONF_CORE (OMAP44XX_L4_CORE_BASE + 0x100000) @@ -66,6 +70,12 @@ /* GPMC */ #define OMAP44XX_GPMC_BASE 0x50000000 +/* DMM */ +#define OMAP44XX_DMM_BASE 0x4E000000 +#define DMM_LISA_MAP_BASE (OMAP44XX_DMM_BASE + 0x40) +#define DMM_LISA_MAP_SYS_SIZE_MASK (7 << 20) +#define DMM_LISA_MAP_SYS_SIZE_SHIFT 20 +#define DMM_LISA_MAP_SYS_ADDR_MASK (0xFF << 24) /* * Hardware Register Details */ diff --git a/arch/blackfin/include/asm/config-pre.h b/arch/blackfin/include/asm/config-pre.h index 4531519d918..4ce67d4cd01 100644 --- a/arch/blackfin/include/asm/config-pre.h +++ b/arch/blackfin/include/asm/config-pre.h @@ -71,6 +71,9 @@ static inline const char *get_bfin_boot_mode(int bfin_boot) # define BFIN_BOOT_SPI_SSEL 1 #endif +/* Define to get a GPIO CS with the Blackfin SPI controller */ +#define MAX_CTRL_CS 8 + /* There is no Blackfin/NetBSD port */ #undef CONFIG_BOOTM_NETBSD diff --git a/arch/blackfin/lib/Makefile b/arch/blackfin/lib/Makefile index 3bdba754db1..a18bbd63e9a 100644 --- a/arch/blackfin/lib/Makefile +++ b/arch/blackfin/lib/Makefile @@ -46,7 +46,7 @@ COBJS-y += clocks.o COBJS-$(CONFIG_CMD_CACHE_DUMP) += cmd_cache_dump.o COBJS-$(CONFIG_CMD_KGDB) += kgdb.o COBJS-y += muldi3.o -COBJS-$(CONFIG_POST) += post.o tests.o +COBJS-$(CONFIG_POST_ALT_LIST) += tests.o COBJS-y += string.o SRCS := $(SOBJS-y:.o=.S) $(COBJS-y:.o=.c) diff --git a/arch/blackfin/lib/board.c b/arch/blackfin/lib/board.c index 46e36c8904c..7643250da37 100644 --- a/arch/blackfin/lib/board.c +++ b/arch/blackfin/lib/board.c @@ -322,7 +322,6 @@ void board_init_r(gd_t * id, ulong dest_addr) #if defined(CONFIG_POST) post_output_backlog(); - post_reloc(); #endif /* initialize malloc() area */ diff --git a/arch/blackfin/lib/post.c b/arch/blackfin/lib/post.c deleted file mode 100644 index bd6aaf5d4d7..00000000000 --- a/arch/blackfin/lib/post.c +++ /dev/null @@ -1,421 +0,0 @@ -/* - * (C) Copyright 2002 - * Wolfgang Denk, DENX Software Engineering, wd@denx.de. - * - * See file CREDITS for list of people who contributed to this - * project. - * - * This program is free software; you can redistribute it and/or - * modify it under the terms of the GNU General Public License as - * published by the Free Software Foundation; either version 2 of - * the License, or (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, - * MA 02111-1307 USA - */ - -#include <common.h> -#include <stdio_dev.h> -#include <watchdog.h> -#include <post.h> - -#ifdef CONFIG_LOGBUFFER -#include <logbuff.h> -#endif - -DECLARE_GLOBAL_DATA_PTR; - -#define POST_MAX_NUMBER 32 - -#define BOOTMODE_MAGIC 0xDEAD0000 - -int post_init_f(void) -{ - int res = 0; - unsigned int i; - - for (i = 0; i < post_list_size; i++) { - struct post_test *test = post_list + i; - - if (test->init_f && test->init_f()) { - res = -1; - } - } - - gd->post_init_f_time = post_time_ms(0); - if (!gd->post_init_f_time) { - printf - ("post/post.c: post_time_ms seems not to be implemented\n"); - } - - return res; -} - -void post_bootmode_init(void) -{ - int bootmode = post_bootmode_get(0); - int newword; - - if (post_hotkeys_pressed() && !(bootmode & POST_POWERTEST)) { - newword = BOOTMODE_MAGIC | POST_SLOWTEST; - } else if (bootmode == 0) { - newword = BOOTMODE_MAGIC | POST_POWERON; - } else if (bootmode == POST_POWERON || bootmode == POST_SLOWTEST) { - newword = BOOTMODE_MAGIC | POST_NORMAL; - } else { - /* Use old value */ - newword = post_word_load() & ~POST_COLDBOOT; - } - - if (bootmode == 0) { - /* We are booting after power-on */ - newword |= POST_COLDBOOT; - } - - post_word_store(newword); - - /* Reset activity record */ - gd->post_log_word = 0; -} - -int post_bootmode_get(unsigned int *last_test) -{ - unsigned long word = post_word_load(); - int bootmode; - - if ((word & 0xFFFF0000) != BOOTMODE_MAGIC) { - return 0; - } - - bootmode = word & 0x7F; - - if (last_test && (bootmode & POST_POWERTEST)) { - *last_test = (word >> 8) & 0xFF; - } - - return bootmode; -} - -/* POST tests run before relocation only mark status bits .... */ -static void post_log_mark_start(unsigned long testid) -{ - gd->post_log_word |= (testid) << 16; -} - -static void post_log_mark_succ(unsigned long testid) -{ - gd->post_log_word |= testid; -} - -/* ... and the messages are output once we are relocated */ -void post_output_backlog(void) -{ - int j; - - for (j = 0; j < post_list_size; j++) { - if (gd->post_log_word & (post_list[j].testid << 16)) { - post_log("POST %s ", post_list[j].cmd); - if (gd->post_log_word & post_list[j].testid) - post_log("PASSED\n"); - else { - post_log("FAILED\n"); - show_boot_progress (-31); - } - } - } -} - -static void post_bootmode_test_on(unsigned int last_test) -{ - unsigned long word = post_word_load(); - - word |= POST_POWERTEST; - - word |= (last_test & 0xFF) << 8; - - post_word_store(word); -} - -static void post_bootmode_test_off(void) -{ - unsigned long word = post_word_load(); - - word &= ~POST_POWERTEST; - - post_word_store(word); -} - -static void post_get_flags(int *test_flags) -{ - int flag[] = { POST_POWERON, POST_NORMAL, POST_SLOWTEST }; - char *var[] = { "post_poweron", "post_normal", "post_slowtest" }; - int varnum = sizeof(var) / sizeof(var[0]); - char list[128]; /* long enough for POST list */ - char *name; - char *s; - int last; - int i, j; - - for (j = 0; j < post_list_size; j++) { - test_flags[j] = post_list[j].flags; - } - - for (i = 0; i < varnum; i++) { - if (getenv_f(var[i], list, sizeof(list)) <= 0) - continue; - - for (j = 0; j < post_list_size; j++) { - test_flags[j] &= ~flag[i]; - } - - last = 0; - name = list; - while (!last) { - while (*name && *name == ' ') - name++; - if (*name == 0) - break; - s = name + 1; - while (*s && *s != ' ') - s++; - if (*s == 0) - last = 1; - else - *s = 0; - - for (j = 0; j < post_list_size; j++) { - if (strcmp(post_list[j].cmd, name) == 0) { - test_flags[j] |= flag[i]; - break; - } - } - - if (j == post_list_size) { - printf("No such test: %s\n", name); - } - - name = s + 1; - } - } - - for (j = 0; j < post_list_size; j++) { - if (test_flags[j] & POST_POWERON) { - test_flags[j] |= POST_SLOWTEST; - } - } -} - -static int post_run_single(struct post_test *test, - int test_flags, int flags, unsigned int i) -{ - if ((flags & test_flags & POST_ALWAYS) && - (flags & test_flags & POST_MEM)) { - WATCHDOG_RESET(); - - if (!(flags & POST_REBOOT)) { - if ((test_flags & POST_REBOOT) - && !(flags & POST_MANUAL)) { - post_bootmode_test_on(i); - } - - if (test_flags & POST_PREREL) - post_log_mark_start(test->testid); - else - post_log("POST %s ", test->cmd); - } - - if (test_flags & POST_PREREL) { - if ((*test->test) (flags) == 0) - post_log_mark_succ(test->testid); - } else { - if ((*test->test) (flags) != 0) { - post_log("FAILED\n"); - show_boot_progress (-32); - } else - post_log("PASSED\n"); - } - - if ((test_flags & POST_REBOOT) && !(flags & POST_MANUAL)) { - post_bootmode_test_off(); - } - - return 0; - } else { - return -1; - } -} - -int post_run(char *name, int flags) -{ - unsigned int i; - int test_flags[POST_MAX_NUMBER]; - - post_get_flags(test_flags); - - if (name == NULL) { - unsigned int last; - - if (post_bootmode_get(&last) & POST_POWERTEST) { - if (last < post_list_size && - (flags & test_flags[last] & POST_ALWAYS) && - (flags & test_flags[last] & POST_MEM)) { - - post_run_single(post_list + last, - test_flags[last], - flags | POST_REBOOT, last); - - for (i = last + 1; i < post_list_size; i++) { - post_run_single(post_list + i, - test_flags[i], - flags, i); - } - } - } else { - for (i = 0; i < post_list_size; i++) { - post_run_single(post_list + i, - test_flags[i], flags, i); - } - } - - return 0; - } else { - for (i = 0; i < post_list_size; i++) { - if (strcmp(post_list[i].cmd, name) == 0) - break; - } - - if (i < post_list_size) { - return post_run_single(post_list + i, - test_flags[i], flags, i); - } else { - return -1; - } - } -} - -static int post_info_single(struct post_test *test, int full) -{ - if (test->flags & POST_MANUAL) { - if (full) - printf("%s - %s\n" - " %s\n", test->cmd, test->name, test->desc); - else - printf(" %-15s - %s\n", test->cmd, test->name); - - return 0; - } else { - return -1; - } -} - -int post_info(char *name) -{ - unsigned int i; - - if (name == NULL) { - for (i = 0; i < post_list_size; i++) { - post_info_single(post_list + i, 0); - } - - return 0; - } else { - for (i = 0; i < post_list_size; i++) { - if (strcmp(post_list[i].cmd, name) == 0) - break; - } - - if (i < post_list_size) { - return post_info_single(post_list + i, 1); - } else { - return -1; - } - } -} - -int post_log(char *format, ...) -{ - va_list args; - uint i; - char printbuffer[CONFIG_SYS_PBSIZE]; - - va_start(args, format); - - /* For this to work, printbuffer must be larger than - * anything we ever want to print. - */ - i = vsprintf(printbuffer, format, args); - va_end(args); - -#ifdef CONFIG_LOGBUFFER - /* Send to the logbuffer */ - logbuff_log(printbuffer); -#else - /* Send to the stdout file */ - puts(printbuffer); -#endif - - return 0; -} - -void post_reloc(void) -{ - unsigned int i; - - /* - * We have to relocate the test table manually - */ - for (i = 0; i < post_list_size; i++) { - ulong addr; - struct post_test *test = post_list + i; - - if (test->name) { - addr = (ulong) (test->name) + gd->reloc_off; - test->name = (char *)addr; - } - - if (test->cmd) { - addr = (ulong) (test->cmd) + gd->reloc_off; - test->cmd = (char *)addr; - } - - if (test->desc) { - addr = (ulong) (test->desc) + gd->reloc_off; - test->desc = (char *)addr; - } - - if (test->test) { - addr = (ulong) (test->test) + gd->reloc_off; - test->test = (int (*)(int flags))addr; - } - - if (test->init_f) { - addr = (ulong) (test->init_f) + gd->reloc_off; - test->init_f = (int (*)(void))addr; - } - - if (test->reloc) { - addr = (ulong) (test->reloc) + gd->reloc_off; - test->reloc = (void (*)(void))addr; - - test->reloc(); - } - } -} - -/* - * Some tests (e.g. SYSMON) need the time when post_init_f started, - * but we cannot use get_timer() at this point. - * - * On PowerPC we implement it using the timebase register. - */ -unsigned long post_time_ms(unsigned long base) -{ - return (unsigned long)get_ticks() / (get_tbclk() / CONFIG_SYS_HZ) - base; -} diff --git a/arch/powerpc/cpu/mpc512x/Makefile b/arch/powerpc/cpu/mpc512x/Makefile index d1b6946be90..37b06f346ed 100644 --- a/arch/powerpc/cpu/mpc512x/Makefile +++ b/arch/powerpc/cpu/mpc512x/Makefile @@ -29,7 +29,6 @@ LIB = $(obj)lib$(CPU).a START = start.o COBJS-y := cpu.o COBJS-y += traps.o -COBJS-y += common.o COBJS-y += cpu_init.o COBJS-y += fixed_sdram.o COBJS-y += i2c.o diff --git a/arch/powerpc/cpu/mpc512x/common.c b/arch/powerpc/cpu/mpc512x/common.c deleted file mode 100644 index 180d323cf94..00000000000 --- a/arch/powerpc/cpu/mpc512x/common.c +++ /dev/null @@ -1,25 +0,0 @@ -#include <common.h> -#include <asm/io.h> - -#if defined(CONFIG_POST) || defined(CONFIG_LOGBUFFER) - -#if defined(CONFIG_SYS_POST_WORD_ADDR) -# define _POST_ADDR (CONFIG_SYS_POST_WORD_ADDR) -#else -#error echo "No POST word address defined" -#endif - -void post_word_store(ulong a) -{ - volatile void *save_addr = (volatile void *)(_POST_ADDR); - - out_be32(save_addr, a); -} - -ulong post_word_load(void) -{ - volatile void *save_addr = (volatile void *)(_POST_ADDR); - - return in_be32(save_addr); -} -#endif /* CONFIG_POST || CONFIG_LOGBUFFER */ diff --git a/arch/powerpc/cpu/mpc8260/commproc.c b/arch/powerpc/cpu/mpc8260/commproc.c index c522bc5c078..082957ee08e 100644 --- a/arch/powerpc/cpu/mpc8260/commproc.c +++ b/arch/powerpc/cpu/mpc8260/commproc.c @@ -175,23 +175,3 @@ m8260_cpm_extcbrg(uint brg, uint rate, uint extclk, int pinsel) else *bp |= CPM_BRG_EXTC_CLK5_15; } - -#if defined(CONFIG_POST) || defined(CONFIG_LOGBUFFER) - -void post_word_store (ulong a) -{ - volatile ulong *save_addr = - (volatile ulong *)(CONFIG_SYS_IMMR + CPM_POST_WORD_ADDR); - - *save_addr = a; -} - -ulong post_word_load (void) -{ - volatile ulong *save_addr = - (volatile ulong *)(CONFIG_SYS_IMMR + CPM_POST_WORD_ADDR); - - return *save_addr; -} - -#endif /* CONFIG_POST || CONFIG_LOGBUFFER*/ diff --git a/arch/powerpc/cpu/mpc85xx/commproc.c b/arch/powerpc/cpu/mpc85xx/commproc.c index f0fd1cbc38d..292b723dcdd 100644 --- a/arch/powerpc/cpu/mpc85xx/commproc.c +++ b/arch/powerpc/cpu/mpc85xx/commproc.c @@ -183,23 +183,3 @@ m8560_cpm_extcbrg(uint brg, uint rate, uint extclk, int pinsel) else *bp |= CPM_BRG_EXTC_CLK5_15; } - -#ifdef CONFIG_POST - -void post_word_store (ulong a) -{ - volatile ulong *save_addr = - (volatile ulong *)(CONFIG_SYS_IMMR + CPM_POST_WORD_ADDR); - - *save_addr = a; -} - -ulong post_word_load (void) -{ - volatile ulong *save_addr = - (volatile ulong *)(CONFIG_SYS_IMMR + CPM_POST_WORD_ADDR); - - return *save_addr; -} - -#endif /* CONFIG_POST */ diff --git a/arch/powerpc/cpu/mpc8xx/commproc.c b/arch/powerpc/cpu/mpc8xx/commproc.c index 2c853777620..5fe01fffae2 100644 --- a/arch/powerpc/cpu/mpc8xx/commproc.c +++ b/arch/powerpc/cpu/mpc8xx/commproc.c @@ -83,23 +83,3 @@ uint dpram_base_align (uint align) return (gd->dp_alloc_base + mask) & ~mask; } #endif /* CONFIG_SYS_ALLOC_DPRAM */ - -#if defined(CONFIG_POST) || defined(CONFIG_LOGBUFFER) - -void post_word_store (ulong a) -{ - volatile void *save_addr = - ((immap_t *) CONFIG_SYS_IMMR)->im_cpm.cp_dpmem + CPM_POST_WORD_ADDR; - - *(volatile ulong *) save_addr = a; -} - -ulong post_word_load (void) -{ - volatile void *save_addr = - ((immap_t *) CONFIG_SYS_IMMR)->im_cpm.cp_dpmem + CPM_POST_WORD_ADDR; - - return *(volatile ulong *) save_addr; -} - -#endif /* CONFIG_POST || CONFIG_LOGBUFFER*/ diff --git a/arch/powerpc/cpu/ppc4xx/Makefile b/arch/powerpc/cpu/ppc4xx/Makefile index c9c1a331ff4..fa8d10c627c 100644 --- a/arch/powerpc/cpu/ppc4xx/Makefile +++ b/arch/powerpc/cpu/ppc4xx/Makefile @@ -45,7 +45,6 @@ COBJS += bedbug_405.o ifdef CONFIG_CMD_CHIP_CONFIG COBJS += cmd_chip_config.o endif -COBJS += commproc.o COBJS += cpu.o COBJS += cpu_init.o COBJS += denali_data_eye.o diff --git a/arch/powerpc/cpu/ppc4xx/commproc.c b/arch/powerpc/cpu/ppc4xx/commproc.c deleted file mode 100644 index 6bf95e67b26..00000000000 --- a/arch/powerpc/cpu/ppc4xx/commproc.c +++ /dev/null @@ -1,53 +0,0 @@ -/* - * (C) Copyright 2000-2004 - * Wolfgang Denk, DENX Software Engineering, wd@denx.de. - * - * See file CREDITS for list of people who contributed to this - * project. - * - * This program is free software; you can redistribute it and/or - * modify it under the terms of the GNU General Public License as - * published by the Free Software Foundation; either version 2 of - * the License, or (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, - * MA 02111-1307 USA - * - * - * Atapted for ppc4XX by Denis Peter - */ - -#include <common.h> -#include <commproc.h> -#include <asm/io.h> - -#if defined(CONFIG_POST) || defined(CONFIG_LOGBUFFER) - -#if defined(CONFIG_SYS_POST_WORD_ADDR) -# define _POST_ADDR ((CONFIG_SYS_OCM_DATA_ADDR) + (CONFIG_SYS_POST_WORD_ADDR)) -#elif defined(CONFIG_SYS_POST_ALT_WORD_ADDR) -# define _POST_ADDR (CONFIG_SYS_POST_ALT_WORD_ADDR) -#endif - -void post_word_store (ulong a) -{ - volatile void *save_addr = (volatile void *)(_POST_ADDR); - - out_be32(save_addr, a); -} - -ulong post_word_load (void) -{ - volatile void *save_addr = (volatile void *)(_POST_ADDR); - - return in_be32(save_addr); -} - -#endif /* CONFIG_POST || CONFIG_LOGBUFFER*/ diff --git a/arch/powerpc/cpu/ppc4xx/fdt.c b/arch/powerpc/cpu/ppc4xx/fdt.c index 90c7e1905ea..5ddb8802417 100644 --- a/arch/powerpc/cpu/ppc4xx/fdt.c +++ b/arch/powerpc/cpu/ppc4xx/fdt.c @@ -59,14 +59,14 @@ void __ft_board_setup(void *blob, bd_t *bd) *p++ = 0; *p++ = bxcr & EBC_BXCR_BAS_MASK; *p++ = EBC_BXCR_BANK_SIZE(bxcr); + } + } + #ifdef CONFIG_FDT_FIXUP_NOR_FLASH_SIZE - /* Try to update reg property in nor flash node too */ - fdt_fixup_nor_flash_size(blob, i, - EBC_BXCR_BANK_SIZE(bxcr)); + /* Update reg property in all nor flash nodes too */ + fdt_fixup_nor_flash_size(blob); #endif - } - } /* Some 405 PPC's have EBC as direct PLB child in the dts */ if (fdt_path_offset(blob, ebc_path) < 0) |