[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

[PATCH initramfs-tools 1/2] local: Call local-extra boot scripts to prepare additional block devices



Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
---
 initramfs-tools.8 | 7 +++++++
 scripts/local     | 2 ++
 2 files changed, 9 insertions(+)

diff --git a/initramfs-tools.8 b/initramfs-tools.8
index 1d48e66..dbb430c 100644
--- a/initramfs-tools.8
+++ b/initramfs-tools.8
@@ -415,6 +415,13 @@ present (local) or the network interface is expected to be usable (NFS).
 
 .TP
 \fB\fI
+local-extra
+These scripts are called with the name of a local device other than
+that used for root.  After these scripts have been executed, that
+device node is expected to be present.
+
+.TP
+\fB\fI
 local-premount OR nfs-premount
 are run after the sanity of the root device has been verified (local) or the
 network interface has been brought up (NFS), but before the actual root fs has
diff --git a/scripts/local b/scripts/local
index cb6b0f0..f9e588d 100644
--- a/scripts/local
+++ b/scripts/local
@@ -147,6 +147,8 @@ local_mount_fs()
 	read_fstab_entry "$1"
 	MNT_FSNAME=$(resolve_device "$MNT_FSNAME")
 
+	run_scripts /scripts/local-extra "$MNT_FSNAME"
+
 	local_device_setup "$MNT_FSNAME" "$1"
 
 	local_premount


-- 
Ben Hutchings
The first rule of tautology club is the first rule of tautology club.

Attachment: signature.asc
Description: This is a digitally signed message part


Reply to: