arch/ppc64: Pass cbmem_top to ramstage via calling argument
This avoids the need for a platform specific implementation of cbmem_top. HOW TO TEST? There is no serial console for the qemu target... Change-Id: I68aa09a46786eba37c009c5f08642445805b08eb Signed-off-by: Arthur Heymans <arthur@aheymans.xyz> Reviewed-on: https://review.coreboot.org/c/coreboot/+/36276 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Marty E. Plummer <hanetzer@startmail.com> Reviewed-by: Nico Huber <nico.h@gmx.de> Reviewed-by: Angel Pons <th3fanbus@gmail.com>
This commit is contained in:
parent
bc78e014c5
commit
a09d33ec88
|
@ -1,5 +1,6 @@
|
||||||
config ARCH_PPC64
|
config ARCH_PPC64
|
||||||
bool
|
bool
|
||||||
|
select RAMSTAGE_CBMEM_TOP_ARG
|
||||||
|
|
||||||
config ARCH_BOOTBLOCK_PPC64
|
config ARCH_BOOTBLOCK_PPC64
|
||||||
bool
|
bool
|
||||||
|
|
|
@ -16,6 +16,6 @@
|
||||||
|
|
||||||
#include <main_decl.h>
|
#include <main_decl.h>
|
||||||
|
|
||||||
void stage_entry(void) __attribute__((section(".text.stage_entry")));
|
void stage_entry(uintptr_t stage_arg) __attribute__((section(".text.stage_entry")));
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
|
@ -22,9 +22,12 @@
|
||||||
* linker script.
|
* linker script.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
#include <cbmem.h>
|
||||||
#include <arch/stages.h>
|
#include <arch/stages.h>
|
||||||
|
|
||||||
void stage_entry(void)
|
void stage_entry(uintptr_t stage_arg)
|
||||||
{
|
{
|
||||||
|
if (!ENV_ROMSTAGE_OR_BEFORE)
|
||||||
|
_cbmem_top_ptr = stage_arg;
|
||||||
main();
|
main();
|
||||||
}
|
}
|
||||||
|
|
|
@ -15,7 +15,6 @@
|
||||||
bootblock-y += bootblock.c
|
bootblock-y += bootblock.c
|
||||||
bootblock-y += uart.c
|
bootblock-y += uart.c
|
||||||
romstage-y += cbmem.c
|
romstage-y += cbmem.c
|
||||||
ramstage-y += cbmem.c
|
|
||||||
romstage-y += romstage.c
|
romstage-y += romstage.c
|
||||||
ramstage-y += timer.c
|
ramstage-y += timer.c
|
||||||
romstage-y += uart.c
|
romstage-y += uart.c
|
||||||
|
|
Loading…
Reference in New Issue