Fix board init code to respect the C runtime environment
authorAlbert ARIBAUD <albert.u.boot@aribaud.net>
Wed, 25 Nov 2015 16:56:32 +0000 (17:56 +0100)
committerTom Rini <trini@konsulko.com>
Thu, 14 Jan 2016 02:05:17 +0000 (21:05 -0500)
commitecc306639e83c9019a5093b77a48685ea40eedc2
tree7785c9d7358ccd22ddabe52489aae8a8c7035ffe
parent20d08f59fa7cdde0da1eb7aca7915c91dbdeaf51
Fix board init code to respect the C runtime environment

board_init_f_mem() alters the C runtime environment's
stack it is actually already using. This is not a valid
behaviour within a C runtime environment.

Split board_init_f_mem into C functions which do not alter
their own stack and always behave properly with respect to
their C runtime environment.

Signed-off-by: Albert ARIBAUD <albert.u.boot@aribaud.net>
Acked-by: Thomas Chou <thomas@wytron.com.tw>
arch/arc/lib/start.S
arch/arm/lib/crt0.S
arch/arm/lib/crt0_64.S
arch/microblaze/cpu/start.S
arch/nios2/cpu/start.S
arch/powerpc/cpu/ppc4xx/start.S
arch/x86/cpu/start.S
arch/x86/lib/fsp/fsp_common.c
common/init/board_init.c
include/common.h