]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
bootctl: remove all our non-volatile variables on uninstall
authorEmil Velikov <emil.velikov@collabora.com>
Mon, 2 Oct 2023 16:09:29 +0000 (17:09 +0100)
committerEmil Velikov <emil.l.velikov@gmail.com>
Thu, 5 Oct 2023 10:50:48 +0000 (11:50 +0100)
Grepping around showed a few extra entries that are not listed in the
remove_loader_variables() function. Namely:
 - BootNext
 - OsIndications
 - LoaderConfigConsoleMode
 - LoaderEntryLastBooted

Of which the latter two are systemd specific, even though they are
undocumented. Ensure they're removed - follow-up commits will add
documentation references.

Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
src/boot/bootctl-install.c

index ca14564a8e82bfdbae72c94b3118b9abbdd58145..e6f66deeab08396f2a725eab08d184033c93359c 100644 (file)
@@ -972,9 +972,11 @@ static int remove_loader_variables(void) {
         /* Remove all persistent loader variables we define */
 
         FOREACH_STRING(var,
+                       EFI_LOADER_VARIABLE(LoaderConfigConsoleMode),
                        EFI_LOADER_VARIABLE(LoaderConfigTimeout),
                        EFI_LOADER_VARIABLE(LoaderConfigTimeoutOneShot),
                        EFI_LOADER_VARIABLE(LoaderEntryDefault),
+                       EFI_LOADER_VARIABLE(LoaderEntryLastBooted),
                        EFI_LOADER_VARIABLE(LoaderEntryOneShot),
                        EFI_LOADER_VARIABLE(LoaderSystemToken)){