]> git.ipfire.org Git - thirdparty/dracut.git/commitdiff
merge 95rootfs-block-udev and 95rootfs-block
authorHarald Hoyer <harald@redhat.com>
Mon, 18 May 2009 12:05:36 +0000 (14:05 +0200)
committerHarald Hoyer <harald@redhat.com>
Mon, 18 May 2009 12:05:36 +0000 (14:05 +0200)
modules.d/95rootfs-block-udev/genrules.sh [deleted file]
modules.d/95rootfs-block-udev/install [deleted file]
modules.d/95rootfs-block-udev/parse-root-opts.sh [deleted file]
modules.d/95rootfs-block/install
modules.d/95rootfs-block/parse-root-opts.sh

diff --git a/modules.d/95rootfs-block-udev/genrules.sh b/modules.d/95rootfs-block-udev/genrules.sh
deleted file mode 100755 (executable)
index 0b42483..0000000
+++ /dev/null
@@ -1,14 +0,0 @@
-
-resume=$(getarg resume=) && ! getarg noresume && [ -b "$resume" ] && {
-    (
-       /bin/echo -e 'KERNEL=="'${resume#/dev/}'", RUN+="/bin/echo %M:%m > /sys/power/resume"'
-       /bin/echo -e 'SYMLINK=="'${resume#/dev/}'", RUN+="/bin/echo %M:%m > /sys/power/resume"'
-    ) >> /etc/udev/rules.d/99-resume.rules
-}
-
-(
- echo 'KERNEL=="'${root#/dev/}'", RUN+="/bin/mount '$fstype' -o '$rflags' '$root' '$NEWROOT'" '
- echo 'SYMLINK=="'${root#/dev/}'", RUN+="/bin/mount '$fstype' -o '$rflags' '$root' '$NEWROOT'" '
-) >> /etc/udev/rules.d/99-mount.rules
-
-
diff --git a/modules.d/95rootfs-block-udev/install b/modules.d/95rootfs-block-udev/install
deleted file mode 100755 (executable)
index 3b02232..0000000
+++ /dev/null
@@ -1,4 +0,0 @@
-#!/bin/sh
-dracut_install echo
-inst_hook pre-udev 10 "$moddir/parse-root-opts.sh"
-inst_hook pre-udev 20 "$moddir/genrules.sh"
diff --git a/modules.d/95rootfs-block-udev/parse-root-opts.sh b/modules.d/95rootfs-block-udev/parse-root-opts.sh
deleted file mode 100755 (executable)
index 77aed55..0000000
+++ /dev/null
@@ -1,27 +0,0 @@
-#!/bin/sh
-if resume=$(getarg resume=) && ! getarg noresume; then 
-    export resume
-    echo "$resume" >/.resume
-else
-    unset resume
-fi
-
-root=$(getarg root=)
-case $root in
-    LABEL=*) root=${root#LABEL=}
-    root="$(echo $root |sed 's,/,\\x2f,g')"
-    root="/dev/disk/by-label/${root}" ;;
-    UUID=*) root="/dev/disk/by-uuid/${root#UUID=}" ;;
-    '') echo "Warning: no root specified"
-        root="/dev/sda1" ;;
-esac
-
-if rflags="$(getarg rootflags=)"; then
-    getarg rw && rflags="${rflags},rw" || rflags="${rflags},ro"
-else
-    getarg rw && rflags=rw || rflags=ro
-fi
-
-fstype="$(getarg rootfstype=)" && fstype="-t ${fstype}" || fstype="-t auto"
-
-export fstype rflags root
index 8782fb5bc93ea57ed9e0a6264e9154867ac4d618..3b0dc46122e78873c1074b1fd6c0728fd2303cfb 100755 (executable)
@@ -1,3 +1,5 @@
 #!/bin/sh
+dracut_install echo
 inst_hook pre-udev 10 "$moddir/parse-root-opts.sh"
-inst_hook mount 99 "$moddir/mount-root.sh"
+inst_hook pre-udev 20 "$moddir/genrules.sh"
+#inst_hook mount 99 "$moddir/mount-root.sh"
index 473c34dc1e6d9ff1f5a8bcfad0081589890726f6..77aed558a13551d5ffe608a1ae0a4da29e8b9ebc 100755 (executable)
@@ -22,6 +22,6 @@ else
     getarg rw && rflags=rw || rflags=ro
 fi
 
-fstype="$(getarg rootfstype=)" && fstype="-t ${fstype}"
+fstype="$(getarg rootfstype=)" && fstype="-t ${fstype}" || fstype="-t auto"
 
 export fstype rflags root