[PATCH 21/34] ARM AT91: switch remaining boards to barebox_arm_entry

Jean-Christophe PLAGNIOL-VILLARD plagnioj at jcrosoft.com
Sun Jan 27 11:24:16 EST 2013


On 11:46 Sun 27 Jan     , Sascha Hauer wrote:
> For At91 boards which do not have a SDRAM size detection function
> we create a lowlevel reset function which calls barebox_arm_entry
> manually with the known memory size.

I'll send a patch serie to add it

Best Regards,
J.
> 
> Signed-off-by: Sascha Hauer <s.hauer at pengutronix.de>
> ---
>  arch/arm/Kconfig                            |    2 ++
>  arch/arm/boards/at91sam9m10g45ek/Makefile   |    2 ++
>  arch/arm/boards/at91sam9m10g45ek/lowlevel.c |   11 +++++++++++
>  arch/arm/boards/at91sam9m10ihd/Makefile     |    2 ++
>  arch/arm/boards/at91sam9m10ihd/lowlevel.c   |   11 +++++++++++
>  arch/arm/boards/at91sam9n12ek/Makefile      |    2 ++
>  arch/arm/boards/at91sam9n12ek/lowlevel.c    |   11 +++++++++++
>  arch/arm/boards/at91sam9x5ek/Makefile       |    2 ++
>  arch/arm/boards/at91sam9x5ek/lowlevel.c     |   11 +++++++++++
>  arch/arm/boards/pm9g45/Makefile             |    2 ++
>  arch/arm/boards/pm9g45/lowlevel.c           |   11 +++++++++++
>  arch/arm/mach-at91/Kconfig                  |    8 --------
>  12 files changed, 67 insertions(+), 8 deletions(-)
>  create mode 100644 arch/arm/boards/at91sam9m10g45ek/lowlevel.c
>  create mode 100644 arch/arm/boards/at91sam9m10ihd/lowlevel.c
>  create mode 100644 arch/arm/boards/at91sam9n12ek/lowlevel.c
>  create mode 100644 arch/arm/boards/at91sam9x5ek/lowlevel.c
>  create mode 100644 arch/arm/boards/pm9g45/lowlevel.c
> 
> diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig
> index c7daebe..0d5e004 100644
> --- a/arch/arm/Kconfig
> +++ b/arch/arm/Kconfig
> @@ -30,6 +30,8 @@ config ARCH_AT91
>  	select CLKDEV_LOOKUP
>  	select HAS_DEBUG_LL
>  	select HAVE_MACH_ARM_HEAD
> +	select MACH_HAS_LOWLEVEL_INIT
> +	select MACH_DO_LOWLEVEL_INIT
>  
>  config ARCH_BCM2835
>  	bool "Broadcom BCM2835 boards"
> diff --git a/arch/arm/boards/at91sam9m10g45ek/Makefile b/arch/arm/boards/at91sam9m10g45ek/Makefile
> index eb072c0..47ab803 100644
> --- a/arch/arm/boards/at91sam9m10g45ek/Makefile
> +++ b/arch/arm/boards/at91sam9m10g45ek/Makefile
> @@ -1 +1,3 @@
>  obj-y += init.o
> +obj-y += lowlevel.o
> +pbl-y += lowlevel.o
> diff --git a/arch/arm/boards/at91sam9m10g45ek/lowlevel.c b/arch/arm/boards/at91sam9m10g45ek/lowlevel.c
> new file mode 100644
> index 0000000..65259bb
> --- /dev/null
> +++ b/arch/arm/boards/at91sam9m10g45ek/lowlevel.c
> @@ -0,0 +1,11 @@
> +#include <common.h>
> +#include <sizes.h>
> +#include <asm/barebox-arm-head.h>
> +#include <asm/barebox-arm.h>
> +#include <mach/hardware.h>
> +
> +void __naked reset(void)
> +{
> +	common_reset();
> +	barebox_arm_entry(AT91_SDRAM_BASE, SZ_128M, 0);
> +}
> diff --git a/arch/arm/boards/at91sam9m10ihd/Makefile b/arch/arm/boards/at91sam9m10ihd/Makefile
> index f2acf20..4ec0b36 100644
> --- a/arch/arm/boards/at91sam9m10ihd/Makefile
> +++ b/arch/arm/boards/at91sam9m10ihd/Makefile
> @@ -1,2 +1,4 @@
>  obj-y += init.o
>  obj-y += hw_version.o
> +obj-y += lowlevel.o
> +pbl-y += lowlevel.o
> diff --git a/arch/arm/boards/at91sam9m10ihd/lowlevel.c b/arch/arm/boards/at91sam9m10ihd/lowlevel.c
> new file mode 100644
> index 0000000..65259bb
> --- /dev/null
> +++ b/arch/arm/boards/at91sam9m10ihd/lowlevel.c
> @@ -0,0 +1,11 @@
> +#include <common.h>
> +#include <sizes.h>
> +#include <asm/barebox-arm-head.h>
> +#include <asm/barebox-arm.h>
> +#include <mach/hardware.h>
> +
> +void __naked reset(void)
> +{
> +	common_reset();
> +	barebox_arm_entry(AT91_SDRAM_BASE, SZ_128M, 0);
> +}
> diff --git a/arch/arm/boards/at91sam9n12ek/Makefile b/arch/arm/boards/at91sam9n12ek/Makefile
> index eb072c0..6c1a61f 100644
> --- a/arch/arm/boards/at91sam9n12ek/Makefile
> +++ b/arch/arm/boards/at91sam9n12ek/Makefile
> @@ -1 +1,3 @@
> +obj-y += lowlevel.o
> +pbl-y += lowlevel.o
>  obj-y += init.o
> diff --git a/arch/arm/boards/at91sam9n12ek/lowlevel.c b/arch/arm/boards/at91sam9n12ek/lowlevel.c
> new file mode 100644
> index 0000000..65259bb
> --- /dev/null
> +++ b/arch/arm/boards/at91sam9n12ek/lowlevel.c
> @@ -0,0 +1,11 @@
> +#include <common.h>
> +#include <sizes.h>
> +#include <asm/barebox-arm-head.h>
> +#include <asm/barebox-arm.h>
> +#include <mach/hardware.h>
> +
> +void __naked reset(void)
> +{
> +	common_reset();
> +	barebox_arm_entry(AT91_SDRAM_BASE, SZ_128M, 0);
> +}
> diff --git a/arch/arm/boards/at91sam9x5ek/Makefile b/arch/arm/boards/at91sam9x5ek/Makefile
> index f2acf20..4ec0b36 100644
> --- a/arch/arm/boards/at91sam9x5ek/Makefile
> +++ b/arch/arm/boards/at91sam9x5ek/Makefile
> @@ -1,2 +1,4 @@
>  obj-y += init.o
>  obj-y += hw_version.o
> +obj-y += lowlevel.o
> +pbl-y += lowlevel.o
> diff --git a/arch/arm/boards/at91sam9x5ek/lowlevel.c b/arch/arm/boards/at91sam9x5ek/lowlevel.c
> new file mode 100644
> index 0000000..65259bb
> --- /dev/null
> +++ b/arch/arm/boards/at91sam9x5ek/lowlevel.c
> @@ -0,0 +1,11 @@
> +#include <common.h>
> +#include <sizes.h>
> +#include <asm/barebox-arm-head.h>
> +#include <asm/barebox-arm.h>
> +#include <mach/hardware.h>
> +
> +void __naked reset(void)
> +{
> +	common_reset();
> +	barebox_arm_entry(AT91_SDRAM_BASE, SZ_128M, 0);
> +}
> diff --git a/arch/arm/boards/pm9g45/Makefile b/arch/arm/boards/pm9g45/Makefile
> index eb072c0..47ab803 100644
> --- a/arch/arm/boards/pm9g45/Makefile
> +++ b/arch/arm/boards/pm9g45/Makefile
> @@ -1 +1,3 @@
>  obj-y += init.o
> +obj-y += lowlevel.o
> +pbl-y += lowlevel.o
> diff --git a/arch/arm/boards/pm9g45/lowlevel.c b/arch/arm/boards/pm9g45/lowlevel.c
> new file mode 100644
> index 0000000..65259bb
> --- /dev/null
> +++ b/arch/arm/boards/pm9g45/lowlevel.c
> @@ -0,0 +1,11 @@
> +#include <common.h>
> +#include <sizes.h>
> +#include <asm/barebox-arm-head.h>
> +#include <asm/barebox-arm.h>
> +#include <mach/hardware.h>
> +
> +void __naked reset(void)
> +{
> +	common_reset();
> +	barebox_arm_entry(AT91_SDRAM_BASE, SZ_128M, 0);
> +}
> diff --git a/arch/arm/mach-at91/Kconfig b/arch/arm/mach-at91/Kconfig
> index ec9e88b..13f4f21 100644
> --- a/arch/arm/mach-at91/Kconfig
> +++ b/arch/arm/mach-at91/Kconfig
> @@ -72,8 +72,6 @@ config SOC_AT91RM9200
>  	select CPU_ARM920T
>  	select HAVE_AT91_DBGU0
>  	select HAS_AT91_ETHER
> -	select MACH_HAS_LOWLEVEL_INIT
> -	select MACH_DO_LOWLEVEL_INIT
>  
>  config SOC_AT91SAM9260
>  	bool
> @@ -81,8 +79,6 @@ config SOC_AT91SAM9260
>  	select HAVE_AT91_DBGU0
>  	select HAS_MACB
>  	select AT91SAM9_RESET
> -	select MACH_HAS_LOWLEVEL_INIT
> -	select MACH_DO_LOWLEVEL_INIT
>  	help
>  	  Select this if you are using one of Atmel's AT91SAM9260, AT91SAM9XE
>  	  or AT91SAM9G20 SoC.
> @@ -92,8 +88,6 @@ config SOC_AT91SAM9261
>  	select SOC_AT91SAM9
>  	select HAVE_AT91_DBGU0
>  	select AT91SAM9_RESET
> -	select MACH_HAS_LOWLEVEL_INIT
> -	select MACH_DO_LOWLEVEL_INIT
>  	help
>  	  Select this if you are using one of Atmel's AT91SAM9261 or AT91SAM9G10 SoC.
>  
> @@ -103,8 +97,6 @@ config SOC_AT91SAM9263
>  	select HAVE_AT91_DBGU1
>  	select HAS_MACB
>  	select AT91SAM9_RESET
> -	select MACH_HAS_LOWLEVEL_INIT
> -	select MACH_DO_LOWLEVEL_INIT
>  
>  config SOC_AT91SAM9G45
>  	bool
> -- 
> 1.7.10.4
> 
> 
> _______________________________________________
> barebox mailing list
> barebox at lists.infradead.org
> http://lists.infradead.org/mailman/listinfo/barebox



More information about the barebox mailing list