<feed xmlns='http://www.w3.org/2005/Atom'>
<title>u-boot.git/lib/efi_loader/efi_var_sf.c, branch main</title>
<subtitle>Unnamed repository; edit this file 'description' to name the repository.</subtitle>
<id>http://cgit.235523.xyz/u-boot.git/atom/lib/efi_loader/efi_var_sf.c?h=main</id>
<link rel='self' href='http://cgit.235523.xyz/u-boot.git/atom/lib/efi_loader/efi_var_sf.c?h=main'/>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/'/>
<updated>2026-04-17T05:40:17Z</updated>
<entry>
<title>efi_loader: efi_var_sf: Do not fail on blank SPI Flash</title>
<updated>2026-04-17T05:40:17Z</updated>
<author>
<name>Michal Simek</name>
<email>michal.simek@amd.com</email>
</author>
<published>2026-03-19T07:15:07Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=57eae396ec91729d5655c26456f8ac3bac439202'/>
<id>urn:sha1:57eae396ec91729d5655c26456f8ac3bac439202</id>
<content type='text'>
When SPI Flash is blank (first boot or erased), efi_var_from_storage()
returns EFI_DEVICE_ERROR because efi_var_restore() fails on invalid
magic/CRC. This prevents the EFI subsystem from initializing.

Check the magic value before attempting to restore variables. If
the magic does not match EFI_VAR_FILE_MAGIC, treat it as an empty
store and return EFI_SUCCESS, matching the behavior of the file-based
efi_var_file.c which deliberately returns EFI_SUCCESS on missing or
corrupted variable files to avoid blocking the boot process.

Similarly, if the magic matches but efi_var_restore() fails (e.g.
corrupted CRC), log the error but still return EFI_SUCCESS.

Suggested-by: John Toomey &lt;john.toomey@amd.com&gt;
Signed-off-by: Michal Simek &lt;michal.simek@amd.com&gt;
Reviewed-by: Ilias Apalodimas &lt;ilias.apalodimas@linaro.org&gt;
Reviewed-by: Heinrich Schuchardt &lt;heinrich.schuchardt@canonical.com&gt;
</content>
</entry>
<entry>
<title>efi_vars: Implement SPI Flash store</title>
<updated>2026-03-14T07:15:09Z</updated>
<author>
<name>Shantur Rathore</name>
<email>i@shantur.com</email>
</author>
<published>2026-03-13T15:45:27Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=5c83372fa6ed78e63d087c423281799758323335'/>
<id>urn:sha1:5c83372fa6ed78e63d087c423281799758323335</id>
<content type='text'>
Currently U-Boot uses ESP as storage for EFI variables.
Devices with SPI Flash are used for storing environment with this
commit we allow EFI variables to be stored on SPI Flash.

Signed-off-by: Shantur Rathore &lt;i@shantur.com&gt;
Signed-off-by: Michal Simek &lt;michal.simek@amd.com&gt;
Tested-by: Neil Armstrong &lt;neil.armstrong@linaro.org&gt; # on AML-S905D3-CC
Acked-by: Ilias Apalodimas &lt;ilias.apalodimas@linaro.org&gt;
</content>
</entry>
</feed>
