summaryrefslogtreecommitdiff
path: root/libre/uboot-mx6_cubox-i/arm_board_use_weak.patch
diff options
context:
space:
mode:
authorAndré Fabian Silva Delgado <emulatorman@parabola.nu>2016-03-02 02:22:04 -0300
committerAndré Fabian Silva Delgado <emulatorman@parabola.nu>2016-03-02 02:22:04 -0300
commitf303ce805abe78bcbab81704bc0d4ad4d0fb8d61 (patch)
treeae5fa1f9264cd94456e9c272633ead6a8eeb9e0f /libre/uboot-mx6_cubox-i/arm_board_use_weak.patch
parent7545468778b501c3a5a805dc33bc8ae20019020e (diff)
downloadabslibre-f303ce805abe78bcbab81704bc0d4ad4d0fb8d61.tar.gz
abslibre-f303ce805abe78bcbab81704bc0d4ad4d0fb8d61.tar.bz2
abslibre-f303ce805abe78bcbab81704bc0d4ad4d0fb8d61.zip
uboot-mx6_cubox-i: add new package to [libre]
Diffstat (limited to 'libre/uboot-mx6_cubox-i/arm_board_use_weak.patch')
-rw-r--r--libre/uboot-mx6_cubox-i/arm_board_use_weak.patch81
1 files changed, 81 insertions, 0 deletions
diff --git a/libre/uboot-mx6_cubox-i/arm_board_use_weak.patch b/libre/uboot-mx6_cubox-i/arm_board_use_weak.patch
new file mode 100644
index 000000000..58ab1d045
--- /dev/null
+++ b/libre/uboot-mx6_cubox-i/arm_board_use_weak.patch
@@ -0,0 +1,81 @@
+From 8590c800ee60e46f15d6085e3c1fed0d6881fc62 Mon Sep 17 00:00:00 2001
+From: Jeroen Hofstee <jeroen@myspectrum.nl>
+Date: Wed, 8 Oct 2014 22:57:21 +0200
+Subject: [PATCH] arm: board: use __weak
+
+Signed-off-by: Jeroen Hofstee <jeroen@myspectrum.nl>
+Acked-by: Albert ARIBAUD <albert.u.boot@aribaud.net>
+---
+ arch/arm/lib/board.c | 40 ++++++++++++----------------------------
+ 1 file changed, 12 insertions(+), 28 deletions(-)
+
+diff --git a/arch/arm/lib/board.c b/arch/arm/lib/board.c
+index 76adaf3..98782ca 100644
+--- a/arch/arm/lib/board.c
++++ b/arch/arm/lib/board.c
+@@ -63,25 +63,15 @@ extern void dataflash_print_info(void);
+ ************************************************************************
+ * May be supplied by boards if desired
+ */
+-inline void __coloured_LED_init(void) {}
+-void coloured_LED_init(void)
+- __attribute__((weak, alias("__coloured_LED_init")));
+-inline void __red_led_on(void) {}
+-void red_led_on(void) __attribute__((weak, alias("__red_led_on")));
+-inline void __red_led_off(void) {}
+-void red_led_off(void) __attribute__((weak, alias("__red_led_off")));
+-inline void __green_led_on(void) {}
+-void green_led_on(void) __attribute__((weak, alias("__green_led_on")));
+-inline void __green_led_off(void) {}
+-void green_led_off(void) __attribute__((weak, alias("__green_led_off")));
+-inline void __yellow_led_on(void) {}
+-void yellow_led_on(void) __attribute__((weak, alias("__yellow_led_on")));
+-inline void __yellow_led_off(void) {}
+-void yellow_led_off(void) __attribute__((weak, alias("__yellow_led_off")));
+-inline void __blue_led_on(void) {}
+-void blue_led_on(void) __attribute__((weak, alias("__blue_led_on")));
+-inline void __blue_led_off(void) {}
+-void blue_led_off(void) __attribute__((weak, alias("__blue_led_off")));
++__weak void coloured_LED_init(void) {}
++__weak void red_led_on(void) {}
++__weak void red_led_off(void) {}
++__weak void green_led_on(void) {}
++__weak void green_led_off(void) {}
++__weak void yellow_led_on(void) {}
++__weak void yellow_led_off(void) {}
++__weak void blue_led_on(void) {}
++__weak void blue_led_off(void) {}
+
+ /*
+ ************************************************************************
+@@ -198,27 +188,21 @@ static int arm_pci_init(void)
+ */
+ typedef int (init_fnc_t) (void);
+
+-void __dram_init_banksize(void)
++__weak void dram_init_banksize(void)
+ {
+ gd->bd->bi_dram[0].start = CONFIG_SYS_SDRAM_BASE;
+ gd->bd->bi_dram[0].size = gd->ram_size;
+ }
+-void dram_init_banksize(void)
+- __attribute__((weak, alias("__dram_init_banksize")));
+
+-int __arch_cpu_init(void)
++__weak int arch_cpu_init(void)
+ {
+ return 0;
+ }
+-int arch_cpu_init(void)
+- __attribute__((weak, alias("__arch_cpu_init")));
+
+-int __power_init_board(void)
++__weak int power_init_board(void)
+ {
+ return 0;
+ }
+-int power_init_board(void)
+- __attribute__((weak, alias("__power_init_board")));
+
+ /* Record the board_init_f() bootstage (after arch_cpu_init()) */
+ static int mark_bootstage(void)