]> git.pld-linux.org Git - projects/geninitrd.git/commitdiff
- nfsroot patch from wolverine
authorElan Ruusamäe <glen@pld-linux.org>
Sat, 19 Jan 2008 19:47:58 +0000 (19:47 +0000)
committerElan Ruusamäe <glen@pld-linux.org>
Sat, 19 Jan 2008 19:47:58 +0000 (19:47 +0000)
svn-id: @9184

functions
geninitrd

index 0db38e6c0f5d047a45e2df2293c48c2d42d2de8a..14ccefc0eaf50a15f058ebdb8f928f433d5c376d 100644 (file)
--- a/functions
+++ b/functions
@@ -73,6 +73,11 @@ find_root() {
                ;;
        esac
 
+       if [ "$rootFs" = "nfs" ]; then
+               rootdev="/dev/nfs"
+               return 0
+       fi
+
        if [ ! -r "$rootdev" ]; then
                echo >&2 "$function: can't find real device for $rootdev"
                return 1
index cdc8a01c4358147edebd54e6637c51367271bb7d..476f349c02546d6d9eee3b380adf7eea0e1b9d9b 100755 (executable)
--- a/geninitrd
+++ b/geninitrd
@@ -1953,7 +1953,11 @@ fi
 
 if [ "$INITRDFS" = "initramfs" ]; then
        inst_d /newroot
-       [ ! -e "$DESTDIR/$rootdev" ] && inst $rootdev /dev
+       if [ "$rootdev" = "/dev/nfs" ]; then
+               echo "rootfs on NFS root=/dev/nfs"
+       else
+               [ ! -e "$DESTDIR/$rootdev" ] && inst $rootdev /dev
+       fi
        # Parsing root parameter
        # We support passing root as hda3 /dev/hda3 0303 0x0303 and 303
        add_linuxrc <<-'EOF'
This page took 0.378989 seconds and 4 git commands to generate.