[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Error 25: Disk read error

From: John Kelly
Subject: Re: Error 25: Disk read error
Date: Mon, 24 Oct 2005 16:17:30 -0400

On Sun, 23 Oct 2005 16:40:35 -0400, John Kelly <address@hidden>

>I start grub from a floppy, with two menu entries; the 1st looks for
>grub on the hard drive, and the 2nd is a fallback in case grub is not
>found on the hard drive.
>Works great using a floppy, but now I need to use a CD instead of a
>floppy, and the fallback does not work when using the CD.
>After reporting the first error because grub is not found on the hard
>drive, it tries to run the fallback entry, but fails, reporting:
>  Error 25: Disk read error
>and will not run the fallback entry.
>It looks as though some variable is not getting reset

The variable is cur_part_addr in disk_io.c

It's defined as static, so the old value is still there after
attempting to boot grub from the hard drive.  And that causes
set_bootdev to wrongly execute

   if ((saved_drive & 0x80) && cur_part_addr) {

when trying to start the fallback menu entry from the CD.

Thus it seems the fix will be to reset cur_part_addr when starting a
new menu entry.  That would be easier if it was defined external like
most of the other global variables.  Makes you wonder why it was made
static instead of external ...

reply via email to

[Prev in Thread] Current Thread [Next in Thread]