aboutsummaryrefslogtreecommitdiffstats
path: root/recipes/initrdscripts/files/98-aufs.sh
diff options
context:
space:
mode:
Diffstat (limited to 'recipes/initrdscripts/files/98-aufs.sh')
-rw-r--r--recipes/initrdscripts/files/98-aufs.sh17
1 files changed, 17 insertions, 0 deletions
diff --git a/recipes/initrdscripts/files/98-aufs.sh b/recipes/initrdscripts/files/98-aufs.sh
new file mode 100644
index 0000000000..5f7cc11432
--- /dev/null
+++ b/recipes/initrdscripts/files/98-aufs.sh
@@ -0,0 +1,17 @@
+aufs_mount () {
+ modprobe -q aufs
+
+ mkdir -p $2 /mnt
+ mount -t aufs -o br:$1:$2 none /mnt
+}
+
+for arg in $CMDLINE; do
+ optarg=`expr "x$arg" : 'x[^=]*=\(.*\)'`
+ case $arg in
+ aufs=*)
+ rw=`expr "$optarg" : '\([^:]*\).*'`
+ ro=`expr "$optarg" : '[^:]*:\([^:]*\).*'`
+ aufs_mount $rw $ro
+ BOOT_ROOT=/mnt ;;
+ esac
+done