From 9d475bf6de63f4e05bba39e4771e0d32c07c0c9b Mon Sep 17 00:00:00 2001 From: Maximilian Brune Date: Fri, 5 May 2023 15:10:24 +0200 Subject: libpayload/arch/x86: Update API handling of CBTABLE handoff The payload API of coreboot described in https://www.coreboot.org/Payload_API does not reflect the current handoff mechanism to hand the coreboot tables off. Therefore the arguments supplied by coreboot (cbtable) will currently never be parsed correctly and libpayload has to search for the coreboot tables by iterating through memory. This patch removes the old payload API implementation and just takes the coreboot table pointer from the first argument on the stack. Tested: started prodrive/atlas with coreinfo payload Signed-off-by: Maximilian Brune Change-Id: I51fb0cfc81043cbfe3fc9c8ea0776add2d6a42b2 Reviewed-on: https://review.coreboot.org/c/coreboot/+/74965 Reviewed-by: Julius Werner Tested-by: build bot (Jenkins) --- payloads/libpayload/arch/arm64/main.c | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) (limited to 'payloads/libpayload/arch/arm64') diff --git a/payloads/libpayload/arch/arm64/main.c b/payloads/libpayload/arch/arm64/main.c index 374c8b18e2..2d599f8ef6 100644 --- a/payloads/libpayload/arch/arm64/main.c +++ b/payloads/libpayload/arch/arm64/main.c @@ -30,11 +30,6 @@ #include #include -int main_argc; /**< The argc value to pass to main() */ - -/** The argv value to pass to main() */ -char *main_argv[MAX_ARGC_COUNT]; - /* * Func: pre_sysinfo_scan_mmu_setup * Desc: We need to setup and enable MMU before we can go to scan coreboot @@ -125,7 +120,7 @@ void start_main(void) * In the future we may care about the return value. */ - (void) main(main_argc, (main_argc != 0) ? main_argv : NULL); + (void) main(0, NULL); /* * Returning here will go to the _leave function to return -- cgit v1.2.3