[U-Boot] [PATCH 12/26 v2][NEXT] ARM: add relocation support

Albert ARIBAUD albert.aribaud at free.fr
Fri Sep 17 15:07:47 CEST 2010


Hi Heiko,

Le 17/09/2010 13:10, Heiko Schocher a écrit :

> diff --git a/arch/arm/lib/board.c b/arch/arm/lib/board.c
> index 54519b0..88c6427 100644
> --- a/arch/arm/lib/board.c
> +++ b/arch/arm/lib/board.c

> @@ -234,6 +246,7 @@ typedef int (init_fnc_t) (void);
>
>   int print_cpuinfo (void);
>
> +#if defined(CONFIG_SYS_ARM_WITHOUT_RELOC)
>   init_fnc_t *init_sequence[] = {

init_sequence is a constant, not an initialized variable, and thus 
should have the 'const' qualifier.

> @@ -444,6 +457,459 @@ extern void davinci_eth_set_mac_addr (const u_int8_t *addr);
>
>   	/* NOTREACHED - no way out of command loop except booting */
>   }
> +#else
> +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")));
> +
> +init_fnc_t *init_sequence[] = {

Ditto.

Amicalement,
-- 
Albert.


More information about the U-Boot mailing list