summaryrefslogtreecommitdiffstats
path: root/meta/recipes-core/initrdscripts/initramfs-framework/finish
diff options
context:
space:
mode:
Diffstat (limited to 'meta/recipes-core/initrdscripts/initramfs-framework/finish')
-rwxr-xr-xmeta/recipes-core/initrdscripts/initramfs-framework/finish9
1 files changed, 9 insertions, 0 deletions
diff --git a/meta/recipes-core/initrdscripts/initramfs-framework/finish b/meta/recipes-core/initrdscripts/initramfs-framework/finish
index 717383ebac..dee3ab3387 100755
--- a/meta/recipes-core/initrdscripts/initramfs-framework/finish
+++ b/meta/recipes-core/initrdscripts/initramfs-framework/finish
@@ -14,6 +14,15 @@ finish_run() {
14 14
15 info "Switching root to '$ROOTFS_DIR'..." 15 info "Switching root to '$ROOTFS_DIR'..."
16 16
17 debug "Moving basic mounts onto rootfs"
18 for dir in `awk '/\/dev.* \/run\/media/{print $2}' /proc/mounts`; do
19 # Parse any OCT or HEX encoded chars such as spaces
20 # in the mount points to actual ASCII chars
21 dir=`printf $dir`
22 mkdir -p "${ROOTFS_DIR}/media/${dir##*/}"
23 mount -n --move "$dir" "${ROOTFS_DIR}/media/${dir##*/}"
24 done
25
17 debug "Moving /dev, /proc and /sys onto rootfs..." 26 debug "Moving /dev, /proc and /sys onto rootfs..."
18 mount --move /dev $ROOTFS_DIR/dev 27 mount --move /dev $ROOTFS_DIR/dev
19 mount --move /proc $ROOTFS_DIR/proc 28 mount --move /proc $ROOTFS_DIR/proc