[U-Boot] [PATCH V2] Don't inline weak symbols
Jean-Christophe PLAGNIOL-VILLARD
plagnioj at jcrosoft.com
Fri Aug 7 22:06:53 CEST 2009
From: Ron Lee <ron at debian.org>
use the same dummy weak functions too
it will save 200 bytes
Signed-off-by: Ron Lee <ron at debian.org>
update the implementation
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj at jcrosoft.com>
---
lib_arm/board.c | 28 ++++++++++------------------
1 files changed, 10 insertions(+), 18 deletions(-)
diff --git a/lib_arm/board.c b/lib_arm/board.c
index a44d308..37e4cc9 100644
--- a/lib_arm/board.c
+++ b/lib_arm/board.c
@@ -123,24 +123,16 @@ void *sbrk (ptrdiff_t increment)
************************************************************************
* May be supplied by boards if desired
*/
-void inline __coloured_LED_init (void) {}
-void inline coloured_LED_init (void) __attribute__((weak, alias("__coloured_LED_init")));
-void inline __red_LED_on (void) {}
-void inline red_LED_on (void) __attribute__((weak, alias("__red_LED_on")));
-void inline __red_LED_off(void) {}
-void inline red_LED_off(void) __attribute__((weak, alias("__red_LED_off")));
-void inline __green_LED_on(void) {}
-void inline green_LED_on(void) __attribute__((weak, alias("__green_LED_on")));
-void inline __green_LED_off(void) {}
-void inline green_LED_off(void)__attribute__((weak, alias("__green_LED_off")));
-void inline __yellow_LED_on(void) {}
-void inline yellow_LED_on(void)__attribute__((weak, alias("__yellow_LED_on")));
-void inline __yellow_LED_off(void) {}
-void inline yellow_LED_off(void)__attribute__((weak, alias("__yellow_LED_off")));
-void inline __blue_LED_on(void) {}
-void inline blue_LED_on(void)__attribute__((weak, alias("__blue_LED_on")));
-void inline __blue_LED_off(void) {}
-void inline blue_LED_off(void)__attribute__((weak, alias("__blue_LED_off")));
+void __coloured_dummy(void) {}
+void coloured_LED_init(void) __attribute__((weak, alias("__coloured_dummy")));
+void red_LED_on(void) __attribute__((weak, alias("__coloured_dummy")));
+void red_LED_off(void) __attribute__((weak, alias("__coloured_dummy")));
+void green_LED_on(void) __attribute__((weak, alias("__coloured_dummy")));
+void green_LED_off(void) __attribute__((weak, alias("__coloured_dummy")));
+void yellow_LED_on(void) __attribute__((weak, alias("__coloured_dummy")));
+void yellow_LED_off(void) __attribute__((weak, alias("__coloured_dummy")));
+void blue_LED_on(void) __attribute__((weak, alias("__coloured_dummy")));
+void blue_LED_off(void) __attribute__((weak, alias("__coloured_dummy")));
/************************************************************************
* Init Utilities *
--
1.6.3.1
More information about the U-Boot
mailing list