summaryrefslogtreecommitdiff
path: root/src/kernel-install/90-loaderentry.install.in
diff options
context:
space:
mode:
authorLudwig Nussel <ludwig.nussel@suse.de>2022-12-08 16:27:31 +0100
committerLudwig Nussel <ludwig.nussel@suse.de>2023-01-19 14:24:43 +0100
commit8702496bfb0205764569782a9a2ebd11fd80e5e8 (patch)
tree1b610c546c1ef4fb3422341430edab09bf5873f3 /src/kernel-install/90-loaderentry.install.in
parent1132fd73b32a06c6349f20c0cfb235cc854a1a3a (diff)
downloadsystemd-8702496bfb0205764569782a9a2ebd11fd80e5e8.tar.gz
bootctl: unlink and cleanup functions
The unlink command removes an entry from the ESP including referenced files that are not referenced in other entries. That is useful eg to have multiple entries that use the same kernel with different options. The cleanup command removes all files that are not referenced by any entry.
Diffstat (limited to 'src/kernel-install/90-loaderentry.install.in')
-rwxr-xr-xsrc/kernel-install/90-loaderentry.install.in2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/kernel-install/90-loaderentry.install.in b/src/kernel-install/90-loaderentry.install.in
index 0992c641f0..e8e8cf37c3 100755
--- a/src/kernel-install/90-loaderentry.install.in
+++ b/src/kernel-install/90-loaderentry.install.in
@@ -32,7 +32,7 @@ MACHINE_ID="$KERNEL_INSTALL_MACHINE_ID"
ENTRY_TOKEN="$KERNEL_INSTALL_ENTRY_TOKEN"
BOOT_ROOT="$KERNEL_INSTALL_BOOT_ROOT"
-BOOT_MNT="$(stat -c %m "$BOOT_ROOT")"
+[ -n "$BOOT_MNT" ] || BOOT_MNT="$(stat -c %m "$BOOT_ROOT")"
if [ "$BOOT_MNT" = '/' ]; then
ENTRY_DIR="$ENTRY_DIR_ABS"
else