[PATCH 1/1] ARM: i.MX31: Add support for mx31moboard board
Sascha Hauer
s.hauer at pengutronix.de
Fri Feb 28 08:37:30 EST 2014
On Fri, Feb 28, 2014 at 02:10:59PM +0100, Philippe Rétornaz wrote:
> Le 28/02/2014 09:37, Sascha Hauer a écrit :
> >This may happen because the function gets too complex and gcc starts
> >using the stack in this case.
> >
> >Try rewriting the lowlevel stuff as:
> >
> >static void __noinline mx31_moboard_startup(void)
> >{
> > /* Put setup here */
> >}
> >
> >void __bare_init __naked barebox_arm_reset_vector(void)
> >{
> > arm_cpu_lowlevel_init();
> >
> > arm_setup_stack(MX31_IRAM_BASE_ADDR + MX31_IRAM_SIZE - 12);
> >
> > mx31_moboard_startup();
> >}
> >
> >With this you can use the stack and should be on the safe side.
>
> Ok, I tried and it works fine so I will do this.
> BTW, any reason for the -12, why not -8 ?
Probably historic reasons. I don't know exactly.
Sascha
--
Pengutronix e.K. | |
Industrial Linux Solutions | http://www.pengutronix.de/ |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 |
Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 |
More information about the barebox
mailing list