Lines Matching refs:efi

3  * efi.c - EFI subsystem
9 * This code registers /sys/firmware/efi{,/efivars} when EFI is supported,
11 * The existance of /sys/firmware/efi may also be used by userspace to
22 #include <linux/efi.h>
39 struct efi __read_mostly efi = {
58 EXPORT_SYMBOL(efi);
106 set_bit(EFI_DBG, &efi.flags);
115 set_bit(EFI_MEM_NO_SOFT_RESERVE, &efi.flags);
119 early_param("efi", parse_efi_cmdline);
137 if (efi.acpi20 != EFI_INVALID_TABLE_ADDR)
138 str += sprintf(str, "ACPI20=0x%lx\n", efi.acpi20);
139 if (efi.acpi != EFI_INVALID_TABLE_ADDR)
140 str += sprintf(str, "ACPI=0x%lx\n", efi.acpi);
146 if (efi.smbios3 != EFI_INVALID_TABLE_ADDR)
147 str += sprintf(str, "SMBIOS3=0x%lx\n", efi.smbios3);
148 if (efi.smbios != EFI_INVALID_TABLE_ADDR)
149 str += sprintf(str, "SMBIOS=0x%lx\n", efi.smbios);
206 if (!efi.get_next_variable)
208 status = efi.get_next_variable(&name_size, &name, &guid);
220 generic_ops.get_variable = efi.get_variable;
221 generic_ops.get_next_variable = efi.get_next_variable;
223 generic_ops.query_variable_info = efi.query_variable_info;
226 generic_ops.set_variable = efi.set_variable;
227 generic_ops.set_variable_nonblocking = efi.set_variable_nonblocking;
290 status = efi.get_next_variable(&name_size, name, &guid);
311 status = efi.get_variable(name, &guid, NULL, &data_size, NULL);
319 status = efi.get_variable(name, &guid, NULL, &data_size, data);
351 efi_debugfs = debugfs_create_dir("efi", NULL);
391 * We register the efi subsystem with the firmware subsystem and the
392 * efivars subsystem with the efi subsystem, if the system was booted with
400 efi.runtime_supported_mask = 0;
405 if (efi.runtime_supported_mask) {
414 clear_bit(EFI_RUNTIME_SERVICES, &efi.flags);
415 efi.runtime_supported_mask = 0;
421 platform_device_register_simple("rtc-efi", 0, NULL, 0);
423 /* We register the efi directory at /sys/firmware/efi */
424 efi_kobj = kobject_create_and_add("efi", firmware_kobj);
426 pr_err("efi: Firmware registration failed.\n");
444 pr_err("efi: Sysfs attribute export failed with error %d.\n",
460 if (efi.coco_secret != EFI_INVALID_TABLE_ADDR)
508 * Find the efi memory descriptor for a given physical address. Given a
551 * Calculate the highest address of an efi memory descriptor.
594 {ACPI_20_TABLE_GUID, &efi.acpi20, "ACPI 2.0" },
595 {ACPI_TABLE_GUID, &efi.acpi, "ACPI" },
596 {SMBIOS_TABLE_GUID, &efi.smbios, "SMBIOS" },
597 {SMBIOS3_TABLE_GUID, &efi.smbios3, "SMBIOS 3.0" },
598 {EFI_SYSTEM_RESOURCE_TABLE_GUID, &efi.esrt, "ESRT" },
601 {LINUX_EFI_TPM_EVENT_LOG_GUID, &efi.tpm_log, "TPMEventLog" },
602 {EFI_TCG2_FINAL_EVENTS_TABLE_GUID, &efi.tpm_final_log, "TPMFinalLog" },
603 {EFI_CC_FINAL_EVENTS_TABLE_GUID, &efi.tpm_final_log, "CCFinalLog" },
611 {LINUX_EFI_MOK_VARIABLE_TABLE_GUID, &efi.mokvar_table, "MOKvar" },
614 {LINUX_EFI_COCO_SECRET_AREA_GUID, &efi.coco_secret, "CocoSecret" },
617 {LINUX_EFI_UNACCEPTED_MEM_TABLE_GUID, &efi.unaccepted, "Unaccepted" },
672 start = PAGE_ALIGN_DOWN(efi.unaccepted);
713 set_bit(EFI_CONFIG_TABLES, &efi.flags);
784 efi.runtime_supported_mask &= tbl->runtime_services_supported;
802 efi.unaccepted != EFI_INVALID_TABLE_ADDR) {
805 unaccepted = early_memremap(efi.unaccepted, sizeof(*unaccepted));
811 efi.unaccepted = EFI_INVALID_TABLE_ADDR;
877 efi.runtime_version = EFI_1_10_SYSTEM_TABLE_REVISION;