Skip to content

Commit 50dcc2e

Browse files
ardbiesheuvelIngo Molnar
authored andcommitted
x86/boot: efistub: Assign global boot_params variable
Now that the x86 EFI stub calls into some APIs exposed by the decompressor (e.g., kaslr_get_random_long()), it is necessary to ensure that the global boot_params variable is set correctly before doing so. Signed-off-by: Ard Biesheuvel <[email protected]> Signed-off-by: Ingo Molnar <[email protected]> Cc: [email protected]
1 parent d55d5bc commit 50dcc2e

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

drivers/firmware/efi/libstub/x86-stub.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -818,6 +818,8 @@ void __noreturn efi_stub_entry(efi_handle_t handle,
818818
unsigned long kernel_entry;
819819
efi_status_t status;
820820

821+
boot_params_ptr = boot_params;
822+
821823
efi_system_table = sys_table_arg;
822824
/* Check if we were booted by the EFI firmware */
823825
if (efi_system_table->hdr.signature != EFI_SYSTEM_TABLE_SIGNATURE)

0 commit comments

Comments
 (0)