]> git.proxmox.com Git - proxmox-kernel-helper.git/commitdiff
proxmox-boot: esp config: avoid leading whitespace in initrd/linux options
authorOguz Bektas <o.bektas@proxmox.com>
Wed, 10 Nov 2021 13:07:46 +0000 (14:07 +0100)
committerThomas Lamprecht <t.lamprecht@proxmox.com>
Thu, 11 Nov 2021 10:18:13 +0000 (11:18 +0100)
Not an actual issue, the systemd parser just skips those
whitespaces[0], but it may confuse people and lead to false-positive
conclusions about a culprit for loader issues, so fix that up.

[0]: https://github.com/systemd/systemd/blob/main/src/boot/efi/boot.c#L1064

diff before -> after:
 version  5.11.22-7-pve
 options   root=ZFS=rpool/ROOT/pve-1 boot=zfs iommu=pt
-    linux    /EFI/proxmox/5.11.22-7-pve/vmlinuz-5.11.22-7-pve
-    initrd   /EFI/proxmox/5.11.22-7-pve/initrd.img-5.11.22-7-pve
+linux    /EFI/proxmox/5.11.22-7-pve/vmlinuz-5.11.22-7-pve
+initrd   /EFI/proxmox/5.11.22-7-pve/initrd.img-5.11.22-7-pve

Fixes: 2a8a4b5 ("proxmox-boot: fix #3632 copy kernel+initrd unconditionally")
Signed-off-by: Oguz Bektas <o.bektas@proxmox.com>
[ Thomas: Clarify that the commit does not fix anything but is still
  good to have ]
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
proxmox-boot/zz-proxmox-boot

index 4bd63a6d4b726ccab928b376c7d852b3776c2638..52171b2368cf29c78c2cbda5611ac9b531226765 100755 (executable)
@@ -140,8 +140,8 @@ copy_and_config_kernels() {
                                title    ${LOADER_TITLE}
                                version  ${kver}
                                options   ${CMDLINE}
-                           linux    /${KERNEL_ESP_DIR}/vmlinuz-${kver}
-                           initrd   /${KERNEL_ESP_DIR}/initrd.img-${kver}
+                               linux    /${KERNEL_ESP_DIR}/vmlinuz-${kver}
+                               initrd   /${KERNEL_ESP_DIR}/initrd.img-${kver}
                        EOF
                else
                        warn "  Copying kernel ${kver}"