From: Eric Lammerts <eric@lammerts.org>
To: Paul Stoeber <paul.stoeber@stud.tu-ilmenau.de>
Cc: linux-kernel@vger.kernel.org
Subject: Re: patch to have root fs on USB device (please CC)
Date: Mon, 3 Jun 2002 17:05:52 +0200 [thread overview]
Message-ID: <20020603150552.GA28494@ally.lammerts.org> (raw)
In-Reply-To: <20020602201322.GA85820@gogh.RZ.TU-Ilmenau.DE>
On Sun, Jun 02, 2002 at 10:13:22PM +0200, Paul Stoeber wrote:
> It simply sleeps 10 seconds before mount_block_root().
>
> I get an 'Unable to mount root' panic if I don't apply it,
> because the attached device rolls in too late.
A while ago I made the patch below. I retries every second until the root
device appears. Advantages:
- no delay when the device is already there
- it also works if it takes longer than 10s to find the harddisk
(for example, if you plug it in later)
I don't know if it applies cleanly to current kernels.
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);
prev parent reply other threads:[~2002-06-03 15:05 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2002-06-02 20:13 Paul Stoeber
2002-06-02 20:46 ` Thunder from the hill
2002-06-03 15:05 ` Eric Lammerts [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20020603150552.GA28494@ally.lammerts.org \
--to=eric@lammerts.org \
--cc=linux-kernel@vger.kernel.org \
--cc=paul.stoeber@stud.tu-ilmenau.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®