I don't agree with this fix. It removes (valuable) functionality from the
boot code and possibly breaks booting on some machines.
There is no spec for how a machine should boot, and the value passed in DL
is not standard for all BIOSes. It is basically a left over register value
from the MSDOS MBR code. You can't guarantee that it will always be there. I
am in charge of the MBR boot code at my day job and I have seen BIOSes which
do not pass this value in DL.
Could you please revert the change and fix your value to be either 0xFF or
your boot device number (probably 0x80)?
-Brian
-----Original Message-----
From: ros-dev-bounces(a)reactos.com [mailto:ros-dev-bounces@reactos.com] On
Behalf Of Phillip Susi
Sent: Saturday, April 09, 2005 7:51 PM
To: ros-dev(a)reactos.com
Subject: [ros-dev] Freeldr problems resolved
Well, I finally solved my problems with getting freeldr to boot from a
hard drive. The first is a problem with fat.bin itself. Early during
it's execution it checks to see if the boot sector header specifies a
device ID of 0xff, and if so, it uses the device ID the bios passes in
CL when it invokes the boot sector, otherwise it uses the device ID in
the boot sector header. The device ID field of the boot sector is
inherently unreliable and should NEVER be used. In my case mtools was
leaving it as it was in fat.bin, which is 0, so it was trying to access
the floppy instead of the hard disk. I have fixed this by removing the
check to see if the field is 0xff, so the code will always use the
device passed by the bios.
The second problem was far more stupid. mtools was not specifying
O_BINARY when opening the boot sector template file, and as a result,
cygwin was translating newlines, so it clobbered the boot sector.
I'm all set to check in the fix to fat.asm, but I was never asked by
subversion ( tortoise client ) to log in, so I assume it just used anon
or something. How do I tell subversion to log me in as me?
_______________________________________________
Ros-dev mailing list
Ros-dev(a)reactos.com
http://reactos.com:8080/mailman/listinfo/ros-dev