summaryrefslogtreecommitdiff
path: root/arch/arm
diff options
context:
space:
mode:
authorMasahiro Yamada <yamada.m@jp.panasonic.com>2014-02-13 18:30:26 +0900
committerTom Rini <trini@ti.com>2014-02-19 11:10:05 -0500
commit365475e6d14bc1ea9d218c0fd1fe96878a9db94e (patch)
treed4730d8b64f9ce6437353cf23009645d030446c3 /arch/arm
parent2f13363b0913afe910c22c0f9c12946c6603b1c2 (diff)
downloadu-boot-imx-365475e6d14bc1ea9d218c0fd1fe96878a9db94e.zip
u-boot-imx-365475e6d14bc1ea9d218c0fd1fe96878a9db94e.tar.gz
u-boot-imx-365475e6d14bc1ea9d218c0fd1fe96878a9db94e.tar.bz2
Move #ifdef(CONFIG_DISPLAY_CPUINFO) from caller to callee
- When CONFIG_DISPLAY_CPUINFO is not enabled, print_cpuinfo() should be defined as an empty function in a header, include/common.h - Remove #ifdef CONFIG_DISPLAY_CPUINFO .. #endif from caller, common/board_f.c and arch/arm/lib/board.c - Remove redundant prototypes in arch/arm/lib/board.c, arch/arm/include/asm/arch-am33x/sys_proto.h and board/nokia/rx51/rx51.h, keeping the one in include/common.h - Add #ifdef CONFIG_DISPLAY_CPUINFO to the func definition where it is missing Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
Diffstat (limited to 'arch/arm')
-rw-r--r--arch/arm/cpu/armv7/omap-common/hwinit-common.c3
-rw-r--r--arch/arm/include/asm/arch-am33xx/sys_proto.h4
-rw-r--r--arch/arm/lib/board.c4
3 files changed, 3 insertions, 8 deletions
diff --git a/arch/arm/cpu/armv7/omap-common/hwinit-common.c b/arch/arm/cpu/armv7/omap-common/hwinit-common.c
index bf29510..ade744e 100644
--- a/arch/arm/cpu/armv7/omap-common/hwinit-common.c
+++ b/arch/arm/cpu/armv7/omap-common/hwinit-common.c
@@ -248,6 +248,7 @@ u32 get_device_type(void)
(DEVICE_TYPE_MASK)) >> DEVICE_TYPE_SHIFT;
}
+#if defined(CONFIG_DISPLAY_CPUINFO)
/*
* Print CPU information
*/
@@ -258,6 +259,8 @@ int print_cpuinfo(void)
return 0;
}
+#endif
+
#ifndef CONFIG_SYS_DCACHE_OFF
void enable_caches(void)
{
diff --git a/arch/arm/include/asm/arch-am33xx/sys_proto.h b/arch/arm/include/asm/arch-am33xx/sys_proto.h
index 87b7d36..2e5c356 100644
--- a/arch/arm/include/asm/arch-am33xx/sys_proto.h
+++ b/arch/arm/include/asm/arch-am33xx/sys_proto.h
@@ -17,10 +17,6 @@
u32 get_cpu_rev(void);
u32 get_sysboot_value(void);
-#ifdef CONFIG_DISPLAY_CPUINFO
-int print_cpuinfo(void);
-#endif
-
extern struct ctrl_stat *cstat;
u32 get_device_type(void);
void save_omap_boot_params(void);
diff --git a/arch/arm/lib/board.c b/arch/arm/lib/board.c
index 38b9c7d..c320a35 100644
--- a/arch/arm/lib/board.c
+++ b/arch/arm/lib/board.c
@@ -197,8 +197,6 @@ static int arm_pci_init(void)
*/
typedef int (init_fnc_t) (void);
-int print_cpuinfo(void);
-
void __dram_init_banksize(void)
{
gd->bd->bi_dram[0].start = CONFIG_SYS_SDRAM_BASE;
@@ -250,9 +248,7 @@ init_fnc_t *init_sequence[] = {
serial_init, /* serial communications setup */
console_init_f, /* stage 1 init of console */
display_banner, /* say that we are here */
-#if defined(CONFIG_DISPLAY_CPUINFO)
print_cpuinfo, /* display cpu info (and speed) */
-#endif
#if defined(CONFIG_DISPLAY_BOARDINFO)
checkboard, /* display board info */
#endif