Debian Patches
Status for efivar/39-2
Patch | Description | Author | Forwarded | Bugs | Origin | Last update |
---|---|---|---|---|---|---|
0001_no_host_march.patch | Don't use -march=native *ever*, stick to the defined compiler defaults. =================================================================== |
no | ||||
0002-efivarfs-Update-a-file-variable-store-On-SetVariable.patch | [PATCH] efivarfs: Update a file variable store On SetVariable RT Embedded boards have hardware limitations when storing and managing EFI variables. Some hardware comes with an eMMC & an RPMB partition which they use to store the EFI variables securely. However, the vast majority of boards (using U-Boot), stores the EFI variables in a file in the ESP. This has a few limitations - UEFI secure boot cannot be enabled as it can be very easily overridden - SetVariable at runtime is impossible to support Distros and capsule updates on-disk do rely on the that service though and U-Boot does implement a workaround. U-Boot enables SetVariableRT in the RTPROP table and creates a memory backend, so the linux kernel can naturally read and write variables via the efivarfs filesystem. Those reads and writes end up in memory though. So they are visible while the OS is live and are lost in the event of a reboot. At the same time it also creates two EFI RO variables. RTStorageVolatile -- Holds the filename the variables are stored relative to the ESP VarToFile -- Holds a binary dump of all the EFI variables that should be preserved (BS, NV, RT). By using these two variables we can persist the changes after reboots by doing dd if=/sys/firmware/efi/efivars/VarToFile-b2ac5fc9-92b7-4acd-aeac-11e818c3130c of=/boot/efi/ubootefi.var skip=4 bs=1 So let's plug this functionality into the efivafs backend and enable it automatically if those variables are detected. |
Ilias Apalodimas <ilias.apalodimas@linaro.org> | no | 2025-06-18 |