[PATCH] efi: Fix missing `efi_handover_entry` prototype
From: Zhou Ding
Date: Fri Dec 13 2024 - 04:49:08 EST
We get 1 error when building kernel withW=1:
drivers/firmware/efi/libstub/x86-stub.c:1068:6: error: no previous prototype for ‘efi_handover_entry’ [-Werror=missing-prototypes]
1068 | void efi_handover_entry(efi_handle_t handle, efi_system_table_t *sys_table_arg,
| ^~~~~~~~~~~~~~~~~~
As this function is only used in the file, mark it as 'static'.
Signed-off-by: Zhou Ding <zhouding@xxxxxxxxxxxxxxxxxxxx>
---
drivers/firmware/efi/libstub/x86-stub.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/firmware/efi/libstub/x86-stub.c b/drivers/firmware/efi/libstub/x86-stub.c
index 188c8000d245..4d152b0df59d 100644
--- a/drivers/firmware/efi/libstub/x86-stub.c
+++ b/drivers/firmware/efi/libstub/x86-stub.c
@@ -1065,7 +1065,7 @@ void __noreturn efi_stub_entry(efi_handle_t handle,
}
#ifdef CONFIG_EFI_HANDOVER_PROTOCOL
-void efi_handover_entry(efi_handle_t handle, efi_system_table_t *sys_table_arg,
+static void efi_handover_entry(efi_handle_t handle, efi_system_table_t *sys_table_arg,
struct boot_params *boot_params)
{
memset(_bss, 0, _ebss - _bss);
--
2.33.0