diff mbox

[U-Boot,02/49] common: board: use __weak

Message ID 1412801889-14400-3-git-send-email-jeroen@myspectrum.nl
State Accepted
Delegated to: Tom Rini
Headers show

Commit Message

Jeroen Hofstee Oct. 8, 2014, 8:57 p.m. UTC
Signed-off-by: Jeroen Hofstee <jeroen@myspectrum.nl>
---
 common/board_f.c | 10 ++--------
 common/board_r.c | 10 ++--------
 2 files changed, 4 insertions(+), 16 deletions(-)

Comments

Tom Rini Oct. 27, 2014, 12:31 a.m. UTC | #1
On Wed, Oct 08, 2014 at 10:57:22PM +0200, Jeroen Hofstee wrote:

> Signed-off-by: Jeroen Hofstee <jeroen@myspectrum.nl>

Applied to u-boot/master, thanks!
diff mbox

Patch

diff --git a/common/board_f.c b/common/board_f.c
index e6aa298..b5bebc9 100644
--- a/common/board_f.c
+++ b/common/board_f.c
@@ -128,14 +128,11 @@  int init_func_watchdog_reset(void)
 }
 #endif /* CONFIG_WATCHDOG */
 
-void __board_add_ram_info(int use_default)
+__weak void board_add_ram_info(int use_default)
 {
 	/* please define platform specific board_add_ram_info() */
 }
 
-void board_add_ram_info(int)
-	__attribute__ ((weak, alias("__board_add_ram_info")));
-
 static int init_baud_rate(void)
 {
 	gd->baudrate = getenv_ulong("baudrate", 10, CONFIG_BAUDRATE);
@@ -221,7 +218,7 @@  static int show_dram_config(void)
 	return 0;
 }
 
-void __dram_init_banksize(void)
+__weak void dram_init_banksize(void)
 {
 #if defined(CONFIG_NR_DRAM_BANKS) && defined(CONFIG_SYS_SDRAM_BASE)
 	gd->bd->bi_dram[0].start = CONFIG_SYS_SDRAM_BASE;
@@ -229,9 +226,6 @@  void __dram_init_banksize(void)
 #endif
 }
 
-void dram_init_banksize(void)
-	__attribute__((weak, alias("__dram_init_banksize")));
-
 #if defined(CONFIG_HARD_I2C) || defined(CONFIG_SYS_I2C)
 static int init_func_i2c(void)
 {
diff --git a/common/board_r.c b/common/board_r.c
index 231c6d6..40eae4e 100644
--- a/common/board_r.c
+++ b/common/board_r.c
@@ -60,7 +60,7 @@  DECLARE_GLOBAL_DATA_PTR;
 
 ulong monitor_flash_len;
 
-int __board_flash_wp_on(void)
+__weak int board_flash_wp_on(void)
 {
 	/*
 	 * Most flashes can't be detected when write protection is enabled,
@@ -70,16 +70,10 @@  int __board_flash_wp_on(void)
 	return 0;
 }
 
-int board_flash_wp_on(void)
-	__attribute__ ((weak, alias("__board_flash_wp_on")));
-
-void __cpu_secondary_init_r(void)
+__weak void cpu_secondary_init_r(void)
 {
 }
 
-void cpu_secondary_init_r(void)
-	__attribute__ ((weak, alias("__cpu_secondary_init_r")));
-
 static int initr_secondary_cpu(void)
 {
 	/*