From: Claudius Heine <ch@denx.de>
To: cip-dev@lists.cip-project.org,
Jan Kiszka <jan.kiszka@siemens.com>,
Quirin Gylstorff <quirin.gylstorff@siemens.com>
Cc: Claudius Heine <ch@denx.de>
Subject: [PATCH v2 1/4] initramfs-crypt-hook: make sure that mount path exists
Date: Thu, 27 Feb 2025 15:30:19 +0100 [thread overview]
Message-ID: <20250227143022.323950-2-ch@denx.de> (raw)
In-Reply-To: <20250227143022.323950-1-ch@denx.de>
Wherever or not the mount directory (and their parents) gets created
seem to be inconsistent; mentioning a missing mount point in the
`/etc/fstab` might cause the boot to fail, while using systemd `.mount`
units will just create the mount point.
Wic creates missing mount points that where mentioned in the `.wks`
file; so moving from such a setup to letting `initramfs-crypt-hook`
mount the file system at boot inside the ramdisk, the mount would
suddenly fail.
Therefore creating the mount point for your, if it doesn't exists seem to
provide a smoother transition.
Signed-off-by: Claudius Heine <ch@denx.de>
---
.../initramfs-crypt-hook/files/local-bottom-complete | 1 +
1 file changed, 1 insertion(+)
diff --git a/recipes-initramfs/initramfs-crypt-hook/files/local-bottom-complete b/recipes-initramfs/initramfs-crypt-hook/files/local-bottom-complete
index b991cb4..80553d1 100644
--- a/recipes-initramfs/initramfs-crypt-hook/files/local-bottom-complete
+++ b/recipes-initramfs/initramfs-crypt-hook/files/local-bottom-complete
@@ -41,6 +41,7 @@ mount_partition() {
partition_mountpoint=$2
[ "$debug" = "y" ] && echo "mount device: '$partition_dev_path' to '$partition_mountpoint'"
if ! mountpoint -q "${partition_mountpoint}"; then
+ mkdir -p "${partition_mountpoint}"
if ! mount -t "$(get_fstype "${partition_dev_path}")" "${partition_dev_path}" \
"${partition_mountpoint}"; then
panic "Can't mount partition '${partition_dev_path}'!"
--
2.47.2
next prev parent reply other threads:[~2025-02-27 14:30 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-02-27 14:30 [PATCH v2 0/4] initramfs-crypt-hook patch Claudius Heine
2025-02-27 14:30 ` Claudius Heine [this message]
2025-02-27 14:30 ` [PATCH v2 2/4] initramfs-crypt-hook: implement 'noencrypt' option Claudius Heine
2025-02-27 14:42 ` Quirin Gylstorff
2025-02-27 14:49 ` Claudius Heine
2025-02-27 16:07 ` Quirin Gylstorff
2025-02-27 16:46 ` Jan Kiszka
2025-02-27 16:51 ` Claudius Heine
2025-02-27 14:30 ` [PATCH v2 3/4] initramfs-crypt-hook: add 'format-if-empty' feature Claudius Heine
2025-02-27 14:30 ` [PATCH v2 4/4] initramfs-crypt-hook: add re-encryption recovery Claudius Heine
2025-02-27 14:37 ` Quirin Gylstorff
2025-02-27 14:46 ` Claudius Heine
2025-02-27 14:56 ` Quirin Gylstorff
2025-02-27 15:03 ` Claudius Heine
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20250227143022.323950-2-ch@denx.de \
--to=ch@denx.de \
--cc=cip-dev@lists.cip-project.org \
--cc=jan.kiszka@siemens.com \
--cc=quirin.gylstorff@siemens.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox