Re: rootfs on USB storage device

From: Eric Lammerts (eric@lammerts.org)
Date: Fri Nov 16 2001 - 08:21:04 EST


On Thu, 15 Nov 2001, Pete Zaitcev wrote:
> I think khubd needs to run to complete whole process and mdelay()
> locks it out. You need something that calls schedule() for USB
> detection to work. Try to use schedule_timeout() instead of mdelay().

This patch works for me.

Eric

--- linux-2.4.14-pre8-ext3/fs/super.c.orig Fri Nov 16 00:59:18 2001
+++ linux-2.4.14-pre8-ext3/fs/super.c Fri Nov 16 01:07:26 2001
@@ -1009,11 +1009,13 @@
                  * Allow the user to distinguish between failed open
                  * and bad superblock on root device.
                  */
- printk ("VFS: Cannot open root device \"%s\" or %s\n",
+ printk ("VFS: Cannot open root device \"%s\" or %s, retrying in 1s.\n",
                         root_device_name, kdevname (ROOT_DEV));
- printk ("Please append a correct \"root=\" boot option\n");
- panic("VFS: Unable to mount root fs on %s",
- kdevname(ROOT_DEV));
+
+ /* wait 1 second and try again */
+ current->state = TASK_INTERRUPTIBLE;
+ schedule_timeout(HZ);
+ goto retry;
         }

         check_disk_change(ROOT_DEV);

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/



This archive was generated by hypermail 2b29 : Fri Nov 23 2001 - 21:00:13 EST