History

efi/x86: Drop 'systab' member from struct efi

The systab member in struct efi has outlived its usefulness, now that we have better ways to access the only piece of information we are interested in after init, which is the EFI runtime services table address. So instead of instantiating a doctored copy at early boot with lots of mangled values, and switching the pointer when switching into virtual mode, let's grab the values we need directly, and get rid of the systab pointer entirely.

Ard Biesheuvel committed 6 years ago

Commit fd268301 parent 8819ba32 files · +41 −98Browse files

Showing the changes to include/linux (1 of 2 files). Show all

Unified · Split

include/linux/efi.h+27−25
@@ -530,31 +530,33 @@ typedef struct { · 529 unmodified lines
530 */530 */
531extern struct efi {531extern struct efi {
532 const efi_runtime_services_t *runtime; /* EFI runtime services table */532 const efi_runtime_services_t *runtime; /* EFI runtime services table */
533 efi_system_table_t *systab; /* EFI system table */533 unsigned int runtime_version; /* Runtime services version */
534 unsigned int runtime_version; /* Runtime services version */534
535 unsigned long acpi; /* ACPI table (IA64 ext 0.71) */535 unsigned long acpi; /* ACPI table (IA64 ext 0.71) */
536 unsigned long acpi20; /* ACPI table (ACPI 2.0) */536 unsigned long acpi20; /* ACPI table (ACPI 2.0) */
537 unsigned long smbios; /* SMBIOS table (32 bit entry point) */537 unsigned long smbios; /* SMBIOS table (32 bit entry point) */
538 unsigned long smbios3; /* SMBIOS table (64 bit entry point) */538 unsigned long smbios3; /* SMBIOS table (64 bit entry point) */
539 unsigned long esrt; /* ESRT table */539 unsigned long esrt; /* ESRT table */
540 unsigned long tpm_log; /* TPM2 Event Log table */540 unsigned long tpm_log; /* TPM2 Event Log table */
541 unsigned long tpm_final_log; /* TPM2 Final Events Log table */541 unsigned long tpm_final_log; /* TPM2 Final Events Log table */
542 efi_get_time_t *get_time;542
543 efi_set_time_t *set_time;543 efi_get_time_t *get_time;
544 efi_get_wakeup_time_t *get_wakeup_time;544 efi_set_time_t *set_time;
545 efi_set_wakeup_time_t *set_wakeup_time;545 efi_get_wakeup_time_t *get_wakeup_time;
546 efi_get_variable_t *get_variable;546 efi_set_wakeup_time_t *set_wakeup_time;
547 efi_get_next_variable_t *get_next_variable;547 efi_get_variable_t *get_variable;
548 efi_set_variable_t *set_variable;548 efi_get_next_variable_t *get_next_variable;
549 efi_set_variable_t *set_variable_nonblocking;549 efi_set_variable_t *set_variable;
550 efi_query_variable_info_t *query_variable_info;550 efi_set_variable_t *set_variable_nonblocking;
551 efi_query_variable_info_t *query_variable_info_nonblocking;551 efi_query_variable_info_t *query_variable_info;
552 efi_update_capsule_t *update_capsule;552 efi_query_variable_info_t *query_variable_info_nonblocking;
553 efi_query_capsule_caps_t *query_capsule_caps;553 efi_update_capsule_t *update_capsule;
554 efi_get_next_high_mono_count_t *get_next_high_mono_count;554 efi_query_capsule_caps_t *query_capsule_caps;
555 efi_reset_system_t *reset_system;555 efi_get_next_high_mono_count_t *get_next_high_mono_count;
556 struct efi_memory_map memmap;556 efi_reset_system_t *reset_system;
557 unsigned long flags;557
558 struct efi_memory_map memmap;
559 unsigned long flags;
558} efi;560} efi;
559 561
560extern struct mm_struct efi_mm;562extern struct mm_struct efi_mm;