0001 .. SPDX-License-Identifier: GPL-2.0
0002
0003 =======================================
0004 efivarfs - a (U)EFI variable filesystem
0005 =======================================
0006
0007 The efivarfs filesystem was created to address the shortcomings of
0008 using entries in sysfs to maintain EFI variables. The old sysfs EFI
0009 variables code only supported variables of up to 1024 bytes. This
0010 limitation existed in version 0.99 of the EFI specification, but was
0011 removed before any full releases. Since variables can now be larger
0012 than a single page, sysfs isn't the best interface for this.
0013
0014 Variables can be created, deleted and modified with the efivarfs
0015 filesystem.
0016
0017 efivarfs is typically mounted like this::
0018
0019 mount -t efivarfs none /sys/firmware/efi/efivars
0020
0021 Due to the presence of numerous firmware bugs where removing non-standard
0022 UEFI variables causes the system firmware to fail to POST, efivarfs
0023 files that are not well-known standardized variables are created
0024 as immutable files. This doesn't prevent removal - "chattr -i" will work -
0025 but it does prevent this kind of failure from being accomplished
0026 accidentally.
0027
0028 .. warning ::
0029 When a content of an UEFI variable in /sys/firmware/efi/efivars is
0030 displayed, for example using "hexdump", pay attention that the first
0031 4 bytes of the output represent the UEFI variable attributes,
0032 in little-endian format.
0033
0034 Practically the output of each efivar is composed of:
0035
0036 +-----------------------------------+
0037 |4_bytes_of_attributes + efivar_data|
0038 +-----------------------------------+
0039
0040 *See also:*
0041
0042 - Documentation/admin-guide/acpi/ssdt-overlays.rst
0043 - Documentation/ABI/stable/sysfs-firmware-efi-vars