IntelFrameworkPkg/Include/Protocol/LegacyBios.h File Reference


Data Structures

struct  EFI_COMPATIBILITY16_TABLE
struct  EFI_DISPATCH_OPROM_TABLE
struct  EFI_TO_COMPATIBILITY16_INIT_TABLE
struct  DEVICE_PRODUCER_SERIAL
struct  DEVICE_PRODUCER_PARALLEL
 @) More...
struct  DEVICE_PRODUCER_FLOPPY
struct  LEGACY_DEVICE_FLAGS
struct  DEVICE_PRODUCER_DATA_HEADER
struct  ATAPI_IDENTIFY
struct  HDD_INFO
struct  BBS_STATUS_FLAGS
struct  BBS_TABLE
struct  SMM_ATTRIBUTES
struct  SMM_FUNCTION
struct  SMM_ENTRY
struct  SMM_TABLE
struct  UDC_ATTRIBUTES
struct  UD_TABLE
struct  EFI_TO_COMPATIBILITY16_BOOT_TABLE
struct  EFI_LEGACY_INSTALL_PCI_HANDLER
struct  EFI_EFLAGS_REG
struct  EFI_DWORD_REGS
struct  EFI_FLAGS_REG
struct  EFI_WORD_REGS
struct  EFI_BYTE_REGS
union  EFI_IA32_REGISTER_SET
struct  _EFI_LEGACY_BIOS_PROTOCOL

Defines

#define EFI_COMPATIBILITY16_TABLE_SIGNATURE   SIGNATURE_32 ('I', 'F', 'E', '$')
#define HDD_PRIMARY   0x01
#define HDD_SECONDARY   0x02
#define HDD_MASTER_ATAPI_CDROM   0x04
#define HDD_SLAVE_ATAPI_CDROM   0x08
#define HDD_MASTER_IDE   0x20
#define HDD_SLAVE_IDE   0x40
#define HDD_MASTER_ATAPI_ZIPDISK   0x10
#define HDD_SLAVE_ATAPI_ZIPDISK   0x80
#define EFI_TO_LEGACY_MAJOR_VERSION   0x02
#define EFI_TO_LEGACY_MINOR_VERSION   0x00
#define MAX_IDE_CONTROLLER   8
#define EFI_LEGACY_BIOS_PROTOCOL_GUID
#define NO_ROM   0x00
#define ROM_FOUND   0x01
#define VALID_LEGACY_ROM   0x02
#define ROM_WITH_CONFIG   0x04
 Not defined in the Framework CSM Specification.
#define CARRY_FLAG   0x01
#define DEVICE_SERIAL_MODE_NORMAL   0x00
#define DEVICE_SERIAL_MODE_IRDA   0x01
#define DEVICE_SERIAL_MODE_ASK_IR   0x02
#define DEVICE_SERIAL_MODE_DUPLEX_HALF   0x00
#define DEVICE_SERIAL_MODE_DUPLEX_FULL   0x10
#define DEVICE_PARALLEL_MODE_MODE_OUTPUT_ONLY   0x00
#define DEVICE_PARALLEL_MODE_MODE_BIDIRECTIONAL   0x01
#define DEVICE_PARALLEL_MODE_MODE_EPP   0x02
#define DEVICE_PARALLEL_MODE_MODE_ECP   0x03
#define BBS_FLOPPY   0x01
#define BBS_HARDDISK   0x02
#define BBS_CDROM   0x03
#define BBS_PCMCIA   0x04
#define BBS_USB   0x05
#define BBS_EMBED_NETWORK   0x06
#define BBS_BEV_DEVICE   0x80
#define BBS_UNKNOWN   0xff
#define BBS_DO_NOT_BOOT_FROM   0xFFFC
#define BBS_LOWEST_PRIORITY   0xFFFD
#define BBS_UNPRIORITIZED_ENTRY   0xFFFE
#define BBS_IGNORE_ENTRY   0xFFFF
#define STANDARD_IO   0x00
#define STANDARD_MEMORY   0x01
#define PORT_SIZE_8   0x00
#define PORT_SIZE_16   0x01
#define PORT_SIZE_32   0x02
#define PORT_SIZE_64   0x03
#define DATA_SIZE_8   0x00
#define DATA_SIZE_16   0x01
#define DATA_SIZE_32   0x02
#define DATA_SIZE_64   0x03
#define INT15_D042   0x0000
#define GET_USB_BOOT_INFO   0x0001
#define DMI_PNP_50_57   0x0002
#define STANDARD_OWNER   0x0
#define OEM_OWNER   0x1
#define EFI_SEGMENT(_Adr)   (UINT16) ((UINT16) (((UINTN) (_Adr)) >> 4) & 0xf000)
#define EFI_OFFSET(_Adr)   (UINT16) (((UINT16) ((UINTN) (_Adr))) & 0xffff)

Typedefs

typedef UINT8 SERIAL_MODE
typedef UINT8 PARALLEL_MODE
typedef struct
_EFI_LEGACY_BIOS_PROTOCOL 
EFI_LEGACY_BIOS_PROTOCOL
typedef BOOLEAN(EFIAPI * EFI_LEGACY_BIOS_INT86 )(IN EFI_LEGACY_BIOS_PROTOCOL *This, IN UINT8 BiosInt, IN OUT EFI_IA32_REGISTER_SET *Regs)
typedef BOOLEAN(EFIAPI * EFI_LEGACY_BIOS_FARCALL86 )(IN EFI_LEGACY_BIOS_PROTOCOL *This, IN UINT16 Segment, IN UINT16 Offset, IN EFI_IA32_REGISTER_SET *Regs, IN VOID *Stack, IN UINTN StackSize)
typedef EFI_STATUS(EFIAPI * EFI_LEGACY_BIOS_CHECK_ROM )(IN EFI_LEGACY_BIOS_PROTOCOL *This, IN EFI_HANDLE PciHandle, OUT VOID **RomImage, OUT UINTN *RomSize, OUT UINTN *Flags)
typedef EFI_STATUS(EFIAPI * EFI_LEGACY_BIOS_INSTALL_ROM )(IN EFI_LEGACY_BIOS_PROTOCOL *This, IN EFI_HANDLE PciHandle, IN VOID **RomImage, OUT UINTN *Flags, OUT UINT8 *DiskStart, OUT UINT8 *DiskEnd, OUT VOID **RomShadowAddress, OUT UINT32 *ShadowedRomSize)
typedef EFI_STATUS(EFIAPI * EFI_LEGACY_BIOS_BOOT )(IN EFI_LEGACY_BIOS_PROTOCOL *This, IN BBS_BBS_DEVICE_PATH *BootOption, IN UINT32 LoadOptionsSize, IN VOID *LoadOptions)
typedef EFI_STATUS(EFIAPI * EFI_LEGACY_BIOS_UPDATE_KEYBOARD_LED_STATUS )(IN EFI_LEGACY_BIOS_PROTOCOL *This, IN UINT8 Leds)
typedef EFI_STATUS(EFIAPI * EFI_LEGACY_BIOS_GET_BBS_INFO )(IN EFI_LEGACY_BIOS_PROTOCOL *This, OUT UINT16 *HddCount, OUT HDD_INFO **HddInfo, OUT UINT16 *BbsCount, IN OUT BBS_TABLE **BbsTable)
typedef EFI_STATUS(EFIAPI * EFI_LEGACY_BIOS_PREPARE_TO_BOOT_EFI )(IN EFI_LEGACY_BIOS_PROTOCOL *This, OUT UINT16 *BbsCount, OUT BBS_TABLE **BbsTable)
typedef EFI_STATUS(EFIAPI * EFI_LEGACY_BIOS_BOOT_UNCONVENTIONAL_DEVICE )(IN EFI_LEGACY_BIOS_PROTOCOL *This, IN UDC_ATTRIBUTES Attributes, IN UINTN BbsEntry, IN VOID *BeerData, IN VOID *ServiceAreaData)
typedef EFI_STATUS(EFIAPI * EFI_LEGACY_BIOS_SHADOW_ALL_LEGACY_OPROMS )(IN EFI_LEGACY_BIOS_PROTOCOL *This)
typedef EFI_STATUS(EFIAPI * EFI_LEGACY_BIOS_GET_LEGACY_REGION )(IN EFI_LEGACY_BIOS_PROTOCOL *This, IN UINTN LegacyMemorySize, IN UINTN Region, IN UINTN Alignment, OUT VOID **LegacyMemoryAddress)
typedef EFI_STATUS(EFIAPI * EFI_LEGACY_BIOS_COPY_LEGACY_REGION )(IN EFI_LEGACY_BIOS_PROTOCOL *This, IN UINTN LegacyMemorySize, IN VOID *LegacyMemoryAddress, IN VOID *LegacyMemorySourceAddress)

Enumerations

enum  EFI_COMPATIBILITY_FUNCTIONS {
  Legacy16InitializeYourself = 0x0000, Legacy16UpdateBbs = 0x0001, Legacy16PrepareToBoot = 0x0002, Legacy16Boot = 0x0003,
  Legacy16RetrieveLastBootDevice = 0x0004, Legacy16DispatchOprom = 0x0005, Legacy16GetTableAddress = 0x0006, Legacy16SetKeyboardLeds = 0x0007,
  Legacy16InstallPciHandler = 0x0008
}

Variables

EFI_GUID gEfiLegacyBiosProtocolGuid

Detailed Description

The EFI Legacy BIOS Protocol is used to abstract legacy Option ROM usage under EFI and Legacy OS boot. This file also includes all the related COMPATIBILIY16 structures and defintions.

Note: The names for EFI_IA32_REGISTER_SET elements were picked to follow well known naming conventions.

Thunk is the code that switches from 32-bit protected environment into the 16-bit real-mode environment. Reverse thunk is the code that does the opposite.

Copyright (c) 2007 - 2015, Intel Corporation. All rights reserved.
This program and the accompanying materials are licensed and made available under the terms and conditions of the BSD License that accompanies this distribution. The full text of the license may be found at http://opensource.org/licenses/bsd-license.php.

THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.

Revision Reference:
This protocol is defined in Framework for EFI Compatibility Support Module spec Version 0.98.

Define Documentation

#define BBS_BEV_DEVICE   0x80

BBS device type values

#define BBS_CDROM   0x03

BBS device type values

#define BBS_DO_NOT_BOOT_FROM   0xFFFC

BBS boot priority values

#define BBS_EMBED_NETWORK   0x06

BBS device type values

#define BBS_FLOPPY   0x01

BBS device type values

#define BBS_HARDDISK   0x02

BBS device type values

#define BBS_IGNORE_ENTRY   0xFFFF

BBS boot priority values

#define BBS_LOWEST_PRIORITY   0xFFFD

BBS boot priority values

#define BBS_PCMCIA   0x04

BBS device type values

#define BBS_UNKNOWN   0xff

BBS device type values

#define BBS_UNPRIORITIZED_ENTRY   0xFFFE

BBS boot priority values

#define BBS_USB   0x05

BBS device type values

#define CARRY_FLAG   0x01

#define DATA_SIZE_16   0x01

SMM_ATTRIBUTES data size constants.

#define DATA_SIZE_32   0x02

SMM_ATTRIBUTES data size constants.

#define DATA_SIZE_64   0x03

SMM_ATTRIBUTES data size constants.

#define DATA_SIZE_8   0x00

SMM_ATTRIBUTES data size constants.

#define DEVICE_PARALLEL_MODE_MODE_BIDIRECTIONAL   0x01

DEVICE_PRODUCER_SERIAL's modes.

#define DEVICE_PARALLEL_MODE_MODE_ECP   0x03

DEVICE_PRODUCER_SERIAL's modes.

#define DEVICE_PARALLEL_MODE_MODE_EPP   0x02

DEVICE_PRODUCER_SERIAL's modes.

#define DEVICE_PARALLEL_MODE_MODE_OUTPUT_ONLY   0x00

DEVICE_PRODUCER_PARALLEL's modes.

#define DEVICE_SERIAL_MODE_ASK_IR   0x02

DEVICE_PRODUCER_SERIAL's modes.

#define DEVICE_SERIAL_MODE_DUPLEX_FULL   0x10

DEVICE_PRODUCER_SERIAL's modes.

#define DEVICE_SERIAL_MODE_DUPLEX_HALF   0x00

DEVICE_PRODUCER_SERIAL's modes.

#define DEVICE_SERIAL_MODE_IRDA   0x01

DEVICE_PRODUCER_SERIAL's modes.

#define DEVICE_SERIAL_MODE_NORMAL   0x00

DEVICE_PRODUCER_SERIAL's modes.

#define DMI_PNP_50_57   0x0002

SMM_FUNCTION Function constants.

#define EFI_COMPATIBILITY16_TABLE_SIGNATURE   SIGNATURE_32 ('I', 'F', 'E', '$')

#define EFI_LEGACY_BIOS_PROTOCOL_GUID

Value:

{ \
    0xdb9a1e3d, 0x45cb, 0x4abb, {0x85, 0x3b, 0xe5, 0x38, 0x7f, 0xdb, 0x2e, 0x2d } \
  }

#define EFI_OFFSET ( _Adr   )     (UINT16) (((UINT16) ((UINTN) (_Adr))) & 0xffff)

The following macros do not appear in the Framework CSM Specification and are kept for backward compatibility only. They convert 32-bit address (_Adr) to Segment:Offset 16-bit form.

#define EFI_SEGMENT ( _Adr   )     (UINT16) ((UINT16) (((UINTN) (_Adr)) >> 4) & 0xf000)

The following macros do not appear in the Framework CSM Specification and are kept for backward compatibility only. They convert 32-bit address (_Adr) to Segment:Offset 16-bit form.

#define EFI_TO_LEGACY_MAJOR_VERSION   0x02

#define EFI_TO_LEGACY_MINOR_VERSION   0x00

#define GET_USB_BOOT_INFO   0x0001

SMM_FUNCTION Function constants.

#define HDD_MASTER_ATAPI_CDROM   0x04

#define HDD_MASTER_ATAPI_ZIPDISK   0x10

#define HDD_MASTER_IDE   0x20

#define HDD_PRIMARY   0x01

HDD_INFO status bits

#define HDD_SECONDARY   0x02

#define HDD_SLAVE_ATAPI_CDROM   0x08

#define HDD_SLAVE_ATAPI_ZIPDISK   0x80

#define HDD_SLAVE_IDE   0x40

#define INT15_D042   0x0000

SMM_FUNCTION Function constants.

#define MAX_IDE_CONTROLLER   8

#define NO_ROM   0x00

Flags returned by CheckPciRom().

#define OEM_OWNER   0x1

SMM_FUNCTION Owner constants.

#define PORT_SIZE_16   0x01

SMM_ATTRIBUTES port size constants.

#define PORT_SIZE_32   0x02

SMM_ATTRIBUTES port size constants.

#define PORT_SIZE_64   0x03

SMM_ATTRIBUTES port size constants.

#define PORT_SIZE_8   0x00

SMM_ATTRIBUTES port size constants.

#define ROM_FOUND   0x01

#define ROM_WITH_CONFIG   0x04

Not defined in the Framework CSM Specification.

#define STANDARD_IO   0x00

SMM_ATTRIBUTES type values.

#define STANDARD_MEMORY   0x01

SMM_ATTRIBUTES type values.

#define STANDARD_OWNER   0x0

SMM_FUNCTION Owner constants.

#define VALID_LEGACY_ROM   0x02


Typedef Documentation

typedef EFI_STATUS(EFIAPI * EFI_LEGACY_BIOS_BOOT)(IN EFI_LEGACY_BIOS_PROTOCOL *This, IN BBS_BBS_DEVICE_PATH *BootOption, IN UINT32 LoadOptionsSize, IN VOID *LoadOptions)

This function attempts to traditionally boot the specified BootOption. If the EFI context has been compromised, this function will not return. This procedure is not used for loading an EFI-aware OS off a traditional device. The following actions occur:

  • Get EFI SMBIOS data structures, convert them to a traditional format, and copy to Compatibility16.
  • Get a pointer to ACPI data structures and copy the Compatibility16 RSD PTR to F0000 block.
  • Find the traditional SMI handler from a firmware volume and register the traditional SMI handler with the EFI SMI handler.
  • Build onboard IDE information and pass this information to the Compatibility16 code.
  • Make sure all PCI Interrupt Line registers are programmed to match 8259.
  • Reconfigure SIO devices from EFI mode (polled) into traditional mode (interrupt driven).
  • Shadow all PCI ROMs.
  • Set up BDA and EBDA standard areas before the legacy boot.
  • Construct the Compatibility16 boot memory map and pass it to the Compatibility16 code.
  • Invoke the Compatibility16 table function Compatibility16PrepareToBoot(). This invocation causes a thunk into the Compatibility16 code, which sets all appropriate internal data structures. The boot device list is a parameter.
  • Invoke the Compatibility16 Table function Compatibility16Boot(). This invocation causes a thunk into the Compatibility16 code, which does an INT19.
  • If the Compatibility16Boot() function returns, then the boot failed in a graceful manner--meaning that the EFI code is still valid. An ungraceful boot failure causes a reset because the state of EFI code is unknown.

Parameters:
[in] This The protocol instance pointer.
[in] BootOption The EFI Device Path from BootXXXX variable.
[in] LoadOptionSize The size of LoadOption in size.
[in] LoadOption LThe oadOption from BootXXXX variable.
Return values:
EFI_DEVICE_ERROR Failed to boot from any boot device and memory is uncorrupted. Note: This function normally does not returns. It will either boot the OS or reset the system if memory has been "corrupted" by loading a boot sector and passing control to it.

typedef EFI_STATUS(EFIAPI * EFI_LEGACY_BIOS_BOOT_UNCONVENTIONAL_DEVICE)(IN EFI_LEGACY_BIOS_PROTOCOL *This, IN UDC_ATTRIBUTES Attributes, IN UINTN BbsEntry, IN VOID *BeerData, IN VOID *ServiceAreaData)

To boot from an unconventional device like parties and/or execute HDD diagnostics.

Parameters:
[in] This The protocol instance pointer.
[in] Attributes How to interpret the other input parameters.
[in] BbsEntry The 0-based index into the BbsTable for the parent device.
[in] BeerData A pointer to the 128 bytes of ram BEER data.
[in] ServiceAreaData A pointer to the 64 bytes of raw Service Area data. The caller must provide a pointer to the specific Service Area and not the start all Service Areas.
Return values:
EFI_INVALID_PARAMETER If error. Does NOT return if no error.

typedef EFI_STATUS(EFIAPI * EFI_LEGACY_BIOS_CHECK_ROM)(IN EFI_LEGACY_BIOS_PROTOCOL *This, IN EFI_HANDLE PciHandle, OUT VOID **RomImage, OUT UINTN *RomSize, OUT UINTN *Flags)

Test to see if a legacy PCI ROM exists for this device. Optionally return the Legacy ROM instance for this PCI device.

Parameters:
[in] This The protocol instance pointer.
[in] PciHandle The PCI PC-AT OPROM from this devices ROM BAR will be loaded
[out] RomImage Return the legacy PCI ROM for this device.
[out] RomSize The size of ROM Image.
[out] Flags Indicates if ROM found and if PC-AT. Multiple bits can be set as follows:
  • 00 = No ROM.
  • 01 = ROM Found.
  • 02 = ROM is a valid legacy ROM.
Return values:
EFI_SUCCESS The Legacy Option ROM availible for this device
EFI_UNSUPPORTED The Legacy Option ROM is not supported.

typedef EFI_STATUS(EFIAPI * EFI_LEGACY_BIOS_COPY_LEGACY_REGION)(IN EFI_LEGACY_BIOS_PROTOCOL *This, IN UINTN LegacyMemorySize, IN VOID *LegacyMemoryAddress, IN VOID *LegacyMemorySourceAddress)

Get a region from the LegacyBios for Tiano usage. Can only be invoked once.

Parameters:
[in] This The protocol instance pointer.
[in] LegacyMemorySize The size of data to copy.
[in] LegacyMemoryAddress The Legacy Region destination address. Note: must be in region assigned by LegacyBiosGetLegacyRegion.
[in] LegacyMemorySourceAddress The source of the data to copy.
Return values:
EFI_SUCCESS The Region assigned.
EFI_ACCESS_DENIED Destination was outside an assigned region.

typedef BOOLEAN(EFIAPI * EFI_LEGACY_BIOS_FARCALL86)(IN EFI_LEGACY_BIOS_PROTOCOL *This, IN UINT16 Segment, IN UINT16 Offset, IN EFI_IA32_REGISTER_SET *Regs, IN VOID *Stack, IN UINTN StackSize)

Thunk to 16-bit real mode and call Segment:Offset. Regs will contain the 16-bit register context on entry and exit. Arguments can be passed on the Stack argument

Parameters:
[in] This The protocol instance pointer.
[in] Segment The segemnt of 16-bit mode call.
[in] Offset The offset of 16-bit mdoe call.
[in] Reg Register contexted passed into (and returned) from thunk to 16-bit mode.
[in] Stack The caller allocated stack used to pass arguments.
[in] StackSize The size of Stack in bytes.
Return values:
FALSE Thunk completed with no BIOS errors in the target code. See Regs for status.
TRUE There was a BIOS error in the target code.

typedef EFI_STATUS(EFIAPI * EFI_LEGACY_BIOS_GET_BBS_INFO)(IN EFI_LEGACY_BIOS_PROTOCOL *This, OUT UINT16 *HddCount, OUT HDD_INFO **HddInfo, OUT UINT16 *BbsCount, IN OUT BBS_TABLE **BbsTable)

Retrieve legacy BBS info and assign boot priority.

Parameters:
[in] This The protocol instance pointer.
[out] HddCount The number of HDD_INFO structures.
[out] HddInfo Onboard IDE controller information.
[out] BbsCount The number of BBS_TABLE structures.
[in,out] BbsTable Points to List of BBS_TABLE.
Return values:
EFI_SUCCESS Tables were returned.

typedef EFI_STATUS(EFIAPI * EFI_LEGACY_BIOS_GET_LEGACY_REGION)(IN EFI_LEGACY_BIOS_PROTOCOL *This, IN UINTN LegacyMemorySize, IN UINTN Region, IN UINTN Alignment, OUT VOID **LegacyMemoryAddress)

Get a region from the LegacyBios for S3 usage.

Parameters:
[in] This The protocol instance pointer.
[in] LegacyMemorySize The size of required region.
[in] Region The region to use. 00 = Either 0xE0000 or 0xF0000 block.
  • Bit0 = 1 0xF0000 block.
  • Bit1 = 1 0xE0000 block.
[in] Alignment Address alignment. Bit mapped. The first non-zero bit from right is alignment.
[out] LegacyMemoryAddress The Region Assigned
Return values:
EFI_SUCCESS The Region was assigned.
EFI_ACCESS_DENIED The function was previously invoked.
Other The Region was not assigned.

typedef EFI_STATUS(EFIAPI * EFI_LEGACY_BIOS_INSTALL_ROM)(IN EFI_LEGACY_BIOS_PROTOCOL *This, IN EFI_HANDLE PciHandle, IN VOID **RomImage, OUT UINTN *Flags, OUT UINT8 *DiskStart, OUT UINT8 *DiskEnd, OUT VOID **RomShadowAddress, OUT UINT32 *ShadowedRomSize)

Load a legacy PC-AT OPROM on the PciHandle device. Return information about how many disks were added by the OPROM and the shadow address and size. DiskStart & DiskEnd are INT 13h drive letters. Thus 0x80 is C:

Parameters:
[in] This The protocol instance pointer.
[in] PciHandle The PCI PC-AT OPROM from this devices ROM BAR will be loaded. This value is NULL if RomImage is non-NULL. This is the normal case.
[in] RomImage A PCI PC-AT ROM image. This argument is non-NULL if there is no hardware associated with the ROM and thus no PciHandle, otherwise is must be NULL. Example is PXE base code.
[out] Flags The type of ROM discovered. Multiple bits can be set, as follows:
  • 00 = No ROM.
  • 01 = ROM found.
  • 02 = ROM is a valid legacy ROM.
[out] DiskStart The disk number of first device hooked by the ROM. If DiskStart is the same as DiskEnd no disked were hooked.
[out] DiskEnd disk number of the last device hooked by the ROM.
[out] RomShadowAddress Shadow address of PC-AT ROM.
[out] RomShadowSize Size of RomShadowAddress in bytes.
Return values:
EFI_SUCCESS Thunk completed, see Regs for status.
EFI_INVALID_PARAMETER PciHandle not found

typedef BOOLEAN(EFIAPI * EFI_LEGACY_BIOS_INT86)(IN EFI_LEGACY_BIOS_PROTOCOL *This, IN UINT8 BiosInt, IN OUT EFI_IA32_REGISTER_SET *Regs)

Thunk to 16-bit real mode and execute a software interrupt with a vector of BiosInt. Regs will contain the 16-bit register context on entry and exit.

Parameters:
[in] This The protocol instance pointer.
[in] BiosInt The processor interrupt vector to invoke.
[in,out] Reg Register contexted passed into (and returned) from thunk to 16-bit mode.
Return values:
TRUE Thunk completed with no BIOS errors in the target code. See Regs for status.
FALSE There was a BIOS error in the target code.

typedef EFI_STATUS(EFIAPI * EFI_LEGACY_BIOS_PREPARE_TO_BOOT_EFI)(IN EFI_LEGACY_BIOS_PROTOCOL *This, OUT UINT16 *BbsCount, OUT BBS_TABLE **BbsTable)

Assign drive number to legacy HDD drives prior to booting an EFI aware OS so the OS can access drives without an EFI driver.

Parameters:
[in] This The protocol instance pointer.
[out] BbsCount The number of BBS_TABLE structures
[out] BbsTable List of BBS entries
Return values:
EFI_SUCCESS Drive numbers assigned.

Shadow all legacy16 OPROMs that haven't been shadowed. Warning: Use this with caution. This routine disconnects all EFI drivers. If used externally, then the caller must re-connect EFI drivers.

Parameters:
[in] This The protocol instance pointer.
Return values:
EFI_SUCCESS OPROMs were shadowed.

typedef EFI_STATUS(EFIAPI * EFI_LEGACY_BIOS_UPDATE_KEYBOARD_LED_STATUS)(IN EFI_LEGACY_BIOS_PROTOCOL *This, IN UINT8 Leds)

This function takes the Leds input parameter and sets/resets the BDA accordingly. Leds is also passed to Compatibility16 code, in case any special processing is required. This function is normally called from EFI Setup drivers that handle user-selectable keyboard options such as boot with NUM LOCK on/off. This function does not touch the keyboard or keyboard LEDs but only the BDA.

Parameters:
[in] This The protocol instance pointer.
[in] Leds The status of current Scroll, Num & Cap lock LEDS:
  • Bit 0 is Scroll Lock 0 = Not locked.
  • Bit 1 is Num Lock.
  • Bit 2 is Caps Lock.
Return values:
EFI_SUCCESS The BDA was updated successfully.

typedef UINT8 PARALLEL_MODE

typedef UINT8 SERIAL_MODE


Enumeration Type Documentation

Functions provided by the CSM binary which communicate between the EfiCompatibility and Compatability16 code.

Inconsistent with the specification here: The member's name started with "Compatibility16" [defined in Intel Framework Compatibility Support Module Specification / 0.97 version] has been changed to "Legacy16" since keeping backward compatible.

Enumerator:
Legacy16InitializeYourself  Causes the Compatibility16 code to do any internal initialization required. Input: AX = Compatibility16InitializeYourself ES:BX = Pointer to EFI_TO_COMPATIBILITY16_INIT_TABLE Return: AX = Return Status codes
Legacy16UpdateBbs  Causes the Compatibility16 BIOS to perform any drive number translations to match the boot sequence. Input: AX = Compatibility16UpdateBbs ES:BX = Pointer to EFI_TO_COMPATIBILITY16_BOOT_TABLE Return: AX = Returned status codes
Legacy16PrepareToBoot  Allows the Compatibility16 code to perform any final actions before booting. The Compatibility16 code is read/write. Input: AX = Compatibility16PrepareToBoot ES:BX = Pointer to EFI_TO_COMPATIBILITY16_BOOT_TABLE structure Return: AX = Returned status codes
Legacy16Boot  Causes the Compatibility16 BIOS to boot. The Compatibility16 code is Read/Only. Input: AX = Compatibility16Boot Output: AX = Returned status codes
Legacy16RetrieveLastBootDevice  Allows the Compatibility16 code to get the last device from which a boot was attempted. This is stored in CMOS and is the priority number of the last attempted boot device. Input: AX = Compatibility16RetrieveLastBootDevice Output: AX = Returned status codes BX = Priority number of the boot device.
Legacy16DispatchOprom  Allows the Compatibility16 code rehook INT13, INT18, and/or INT19 after dispatching a legacy OpROM. Input: AX = Compatibility16DispatchOprom ES:BX = Pointer to EFI_DISPATCH_OPROM_TABLE Output: AX = Returned status codes BX = Number of non-BBS-compliant devices found. Equals 0 if BBS compliant.
Legacy16GetTableAddress  Finds a free area in the 0xFxxxx or 0xExxxx region of the specified length and returns the address of that region. Input: AX = Compatibility16GetTableAddress BX = Allocation region 00 = Allocate from either 0xE0000 or 0xF0000 64 KB blocks. Bit 0 = 1 Allocate from 0xF0000 64 KB block Bit 1 = 1 Allocate from 0xE0000 64 KB block CX = Requested length in bytes. DX = Required address alignment. Bit mapped. First non-zero bit from the right is the alignment. Output: AX = Returned status codes DS:BX = Address of the region
Legacy16SetKeyboardLeds  Enables the EfiCompatibility module to do any nonstandard processing of keyboard LEDs or state. Input: AX = Compatibility16SetKeyboardLeds CL = LED status. Bit 0 Scroll Lock 0 = Off Bit 1 NumLock Bit 2 Caps Lock Output: AX = Returned status codes
Legacy16InstallPciHandler  Enables the EfiCompatibility module to install an interrupt handler for PCI mass media devices that do not have an OpROM associated with them. An example is SATA. Input: AX = Compatibility16InstallPciHandler ES:BX = Pointer to EFI_LEGACY_INSTALL_PCI_HANDLER structure Output: AX = Returned status codes


Variable Documentation


Generated on Wed Sep 2 13:08:33 2015 for IntelFrameworkPkg[ALL] by  doxygen 1.5.7.1