From 59c99264362d6a084f6dfff0803e582c01a1ea2b Mon Sep 17 00:00:00 2001 From: "H. Peter Anvin" Date: Fri, 10 Oct 2008 15:01:19 -0700 Subject: [PATCH] Add CD-ROM mode query to the COM32 interface Report the booting mode of ISOLINUX through the COM32 interface. Signed-off-by: H. Peter Anvin --- com32/include/syslinux/config.h | 2 +- core/comboot.inc | 4 ++++ doc/comboot.txt | 7 +++++++ 3 files changed, 12 insertions(+), 1 deletion(-) diff --git a/com32/include/syslinux/config.h b/com32/include/syslinux/config.h index 82225c1..6983f8a 100644 --- a/com32/include/syslinux/config.h +++ b/com32/include/syslinux/config.h @@ -97,7 +97,7 @@ union syslinux_derivative_info { uint8_t filesystem; uint8_t ah; uint8_t sector_shift; - uint8_t ch; + uint8_t cd_mode; uint8_t drive_number; uint8_t dh; uint16_t _pad; diff --git a/core/comboot.inc b/core/comboot.inc index ca11852..810d825 100644 --- a/core/comboot.inc +++ b/core/comboot.inc @@ -604,6 +604,10 @@ comapi_derinfo: %elif IS_ISOLINUX mov P_ES,cs mov P_BX,spec_packet + mov ax,[BIOSType] + sub ax,bios_cdrom + shr ax,2 + mov P_CH,al ; Mode (el torito/cbios/ebios) %endif %endif clc diff --git a/doc/comboot.txt b/doc/comboot.txt index 42078ed..8c4a868 100644 --- a/doc/comboot.txt +++ b/doc/comboot.txt @@ -441,6 +441,10 @@ AX=000Ah [2.00] Get Derivative-Specific Information Output: AL 33h (ISOLINUX) DL drive number CL 11 (sector size as a power of 2) [3.35] + CH mode [3.73] + 0 = El Torito + 1 = Hybrid (hard disk), CBIOS mode + 2 = Hybrid (hard disk), EBIOS mode ES:BX pointer to El Torito spec packet FS:SI pointer to initial ES:DI value [3.53] @@ -798,6 +802,9 @@ AX=0019h [3.50] Read disk [SYSLINUX, ISOLINUX, EXTLINUX] This routine reports "boot failed" (and does not return) on disk error. + Note: for ISOLINUX in hybrid mode, this call uses simulated + 2048-byte CD-ROM sector numbers. + AX=001Ah [3.50] Cleanup, shuffle and boot to flat protected mode Input: AX 001Ah -- 2.7.4