summaryrefslogtreecommitdiffstats
path: root/src/arch/i386/interface/pcbios/int13.c
diff options
context:
space:
mode:
authorMichael Brown2011-04-28 14:05:40 +0200
committerMichael Brown2011-04-28 14:07:32 +0200
commit62c963516612103c965f7b4789faf63753ca77a4 (patch)
treee824afc555fda3f398dbbec3326f9feb18e999a4 /src/arch/i386/interface/pcbios/int13.c
parent[build] Accept EMBED=... as a synonym for EMBEDDED_IMAGE=... (diff)
downloadipxe-62c963516612103c965f7b4789faf63753ca77a4.tar.gz
ipxe-62c963516612103c965f7b4789faf63753ca77a4.tar.xz
ipxe-62c963516612103c965f7b4789faf63753ca77a4.zip
[int13] Catch INT 13,4b when no explicit drive number is present
This allows older versions of ELTORITO.SYS (such as the version found on the FreeDOS installation CD-ROM) to use iPXE's emulated CD-ROM drive. Reported-by: Robin Smidsrød <robin@smidsrod.no> Signed-off-by: Michael Brown <mcb30@ipxe.org>
Diffstat (limited to 'src/arch/i386/interface/pcbios/int13.c')
-rw-r--r--src/arch/i386/interface/pcbios/int13.c9
1 files changed, 7 insertions, 2 deletions
diff --git a/src/arch/i386/interface/pcbios/int13.c b/src/arch/i386/interface/pcbios/int13.c
index 93d01088..b099958c 100644
--- a/src/arch/i386/interface/pcbios/int13.c
+++ b/src/arch/i386/interface/pcbios/int13.c
@@ -1187,12 +1187,17 @@ static __asmcall void int13 ( struct i386_all_regs *ix86 ) {
bios_drive, int13->drive );
ix86->regs.dl = int13->drive;
return;
+ } else if ( ( ( bios_drive & 0x7f ) == 0x7f ) &&
+ ( command == INT13_CDROM_STATUS_TERMINATE )
+ && int13->is_cdrom ) {
+ /* Catch non-drive-specific CD-ROM calls */
+ } else {
+ continue;
}
- continue;
}
DBGC2 ( int13, "INT13,%02x (%02x): ",
- ix86->regs.ah, int13->drive );
+ ix86->regs.ah, bios_drive );
switch ( command ) {
case INT13_RESET: