diff options
-rw-r--r-- | arch/arm/lib/barebox.lds.S | 5 | ||||
-rw-r--r-- | arch/arm/mach-ep93xx/Makefile | 2 | ||||
-rw-r--r-- | arch/arm/mach-ep93xx/header.c | 8 | ||||
-rw-r--r-- | arch/arm/mach-ep93xx/include/mach/barebox.lds.h | 9 | ||||
-rw-r--r-- | include/asm-generic/barebox.lds.h | 3 |
5 files changed, 20 insertions, 7 deletions
diff --git a/arch/arm/lib/barebox.lds.S b/arch/arm/lib/barebox.lds.S index 736e5f02ea..e0bae70f4f 100644 --- a/arch/arm/lib/barebox.lds.S +++ b/arch/arm/lib/barebox.lds.S @@ -41,11 +41,6 @@ SECTIONS *(.text_entry*) __ll_return = .; *(.text_ll_return*) -#ifdef CONFIG_ARCH_EP93XX - /* the EP93xx expects to find the pattern 'CRUS' at 0x1000 */ - . = 0x1000; - LONG(0x53555243) /* 'CRUS' */ -#endif __bare_init_start = .; *(.text_bare_init*) __bare_init_end = .; diff --git a/arch/arm/mach-ep93xx/Makefile b/arch/arm/mach-ep93xx/Makefile index dac657178a..d401164e4a 100644 --- a/arch/arm/mach-ep93xx/Makefile +++ b/arch/arm/mach-ep93xx/Makefile @@ -1,3 +1,3 @@ -obj-y += clocksource.o gpio.o led.o +obj-y += clocksource.o gpio.o led.o header.o obj-$(CONFIG_MACH_DO_LOWLEVEL_INIT) += lowlevel_init.o diff --git a/arch/arm/mach-ep93xx/header.c b/arch/arm/mach-ep93xx/header.c new file mode 100644 index 0000000000..4e6a2e57c8 --- /dev/null +++ b/arch/arm/mach-ep93xx/header.c @@ -0,0 +1,8 @@ +#include <common.h> +#include <linux/compiler.h> +#include <asm/barebox-arm-head.h> + +void __naked __section(.flash_header_start) go(void) +{ + barebox_arm_head(); +} diff --git a/arch/arm/mach-ep93xx/include/mach/barebox.lds.h b/arch/arm/mach-ep93xx/include/mach/barebox.lds.h new file mode 100644 index 0000000000..74c4662a57 --- /dev/null +++ b/arch/arm/mach-ep93xx/include/mach/barebox.lds.h @@ -0,0 +1,9 @@ + +/* the EP93xx expects to find the pattern 'CRUS' at 0x1000 */ + +#define PRE_IMAGE \ + .pre_image : { \ + KEEP(*(.flash_header_start*)) \ + . = 0x1000; \ + LONG(0x53555243) /* 'CRUS' */ \ + } diff --git a/include/asm-generic/barebox.lds.h b/include/asm-generic/barebox.lds.h index e853ca1ca3..b2bd19ef22 100644 --- a/include/asm-generic/barebox.lds.h +++ b/include/asm-generic/barebox.lds.h @@ -4,7 +4,8 @@ defined CONFIG_ARCH_IMX51 || \ defined CONFIG_ARCH_IMX53 || \ defined CONFIG_ARCH_IMX6 || \ - defined CONFIG_X86 + defined CONFIG_X86 || \ + defined CONFIG_ARCH_EP93XX #include <mach/barebox.lds.h> #endif |