]> git.ipfire.org Git - thirdparty/systemd.git/commit - src/shared/dissect-image.c
dissect: when mounting an image mount the XBOOTLDR partition to /boot
authorLennart Poettering <lennart@poettering.net>
Wed, 23 Jan 2019 10:53:28 +0000 (11:53 +0100)
committerLennart Poettering <lennart@poettering.net>
Fri, 1 Mar 2019 11:41:32 +0000 (12:41 +0100)
commitd9223c07f5540ce9fa61a07a2cbd5757e2b8f5ca
treeca58e0fb767cdcab218cad714b51c128abd0144b
parenta8c47660bbbcc2ffc483beaa17d5c806f73849b3
dissect: when mounting an image mount the XBOOTLDR partition to /boot

Previously, we'd mount the ESP to /efi if that existed and was empty,
falling back to /boot if that existed and was empty.

With this change, the XBOOTLDR partition is mounted to /boot
unconditionally. And the EFI is mounted to /efi if that exists (but it
doesn't have to be empty — after all the name is very indicative of what
this is supposed to be), and to /boot as a fallback but only if it
exists and is empty (we insist on emptiness for that, since it might be
used differently than what we assume).

The net effect is that $BOOT should be reliably found under /boot, and
the ESP is either /efi or /boot.

(Note that this commit only is relevant for nspawn and suchlike, i.e.
the codepaths that mount an image without involving udev during boot.)
src/shared/dissect-image.c