]> git.ipfire.org Git - thirdparty/grub.git/commitdiff
Fixes the situation with i386-pc where grub-probe & grub-setup are searching
authorjerone <jerone@localhost>
Tue, 10 Apr 2007 22:00:24 +0000 (22:00 +0000)
committerjerone <jerone@localhost>
Tue, 10 Apr 2007 22:00:24 +0000 (22:00 +0000)
for the root fs for grub files  and they happen to be on the same file system
as the root ("/") filesystem.

ChangeLog
util/i386/pc/getroot.c

index 3dd34ad50b9e1892860a0f075e5836a07fff2ab6..89e0a318aa0adabfbedd8033fdcc2dac26ec9460 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,7 @@
+2007-04-10  Jerone Young  <jerone@gmail.com>
+       * util/i386/pc/getroot.c: Update so that if root device is /dev/root ,
+       continue on and look for device node with real device name.
+
 2007-04-10  Jerone Young  <jerone@gmail.com>
        
        * configure.ac: Add argument for autoconf to use tranformation
index 343f9655a88585273a4bfb521c3ebc6c288793bd..211ce4c18f90ffaa17d5d33075ac769d4ad686a2 100644 (file)
@@ -192,6 +192,13 @@ find_root_device (const char *dir, dev_t dev)
          strip_extra_slashes (res);
          free (cwd);
 
+         /* /dev/root is not a real block device keep looking, takes care
+            of situation where root filesystem is on the same partition as
+            grub files */
+
+         if (strcmp(res, "/dev/root") == 0)
+               continue;
+
          if (chdir (saved_cwd) < 0)
            grub_util_error ("Cannot restore the original directory");