diff options
author | Sam Ravnborg <sam@ravnborg.org> | 2018-01-06 22:11:12 +0100 |
---|---|---|
committer | Sascha Hauer <s.hauer@pengutronix.de> | 2018-01-09 11:34:31 +0100 |
commit | 73851fc963efa2a92755dfe4dcc8a24af8332bbe (patch) | |
tree | 28e2eb89eb4c95a2ff802e51897c6bdb4fe35304 /arch/arm/boards/at91sam9260ek | |
parent | 709559beec0fc093052616a1d4b2e76ff6b8f662 (diff) | |
download | barebox-73851fc963efa2a92755dfe4dcc8a24af8332bbe.tar.gz barebox-73851fc963efa2a92755dfe4dcc8a24af8332bbe.tar.xz |
at91sam9260ek, at91sam9g20ek: move reset vector to board code
Create new lowlevel.c that contains the reset vector.
Drop unused CONFIG symbols
Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
Reviewed-by: Andrey Smirnov <andrew.smirnov@gmail.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Diffstat (limited to 'arch/arm/boards/at91sam9260ek')
-rw-r--r-- | arch/arm/boards/at91sam9260ek/Makefile | 3 | ||||
-rw-r--r-- | arch/arm/boards/at91sam9260ek/lowlevel.c | 26 |
2 files changed, 29 insertions, 0 deletions
diff --git a/arch/arm/boards/at91sam9260ek/Makefile b/arch/arm/boards/at91sam9260ek/Makefile index 6e07f189fa..9cc933a287 100644 --- a/arch/arm/boards/at91sam9260ek/Makefile +++ b/arch/arm/boards/at91sam9260ek/Makefile @@ -1,2 +1,5 @@ obj-y += init.o + +lwl-y += lowlevel.o + bbenv-$(CONFIG_DEFAULT_ENVIRONMENT_GENERIC) += defaultenv-at91sam9260ek diff --git a/arch/arm/boards/at91sam9260ek/lowlevel.c b/arch/arm/boards/at91sam9260ek/lowlevel.c new file mode 100644 index 0000000000..b16ef31bf0 --- /dev/null +++ b/arch/arm/boards/at91sam9260ek/lowlevel.c @@ -0,0 +1,26 @@ +/* + * Copyright (C) 2009-2013 Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com> + * + * Under GPLv2 + */ + +#include <common.h> +#include <init.h> + +#include <asm/barebox-arm-head.h> +#include <asm/barebox-arm.h> + +#include <mach/at91sam9_sdramc.h> +#include <mach/at91sam9260.h> +#include <mach/hardware.h> + +void __naked __bare_init barebox_arm_reset_vector(void) +{ + arm_cpu_lowlevel_init(); + + arm_setup_stack(AT91SAM9260_SRAM_BASE + AT91SAM9260_SRAM_SIZE - 16); + + barebox_arm_entry(AT91_CHIPSELECT_1, + at91_get_sdram_size(IOMEM(AT91SAM9260_BASE_SDRAMC)), + NULL); +} |