PCI Expansion ROM
Version 1.02 12/12/00 329
Table 18-3 defines the layout of an EFI PCI expansion ROM. Missing values will be supplied in a
later version of the specification.
Table 18-3. EFI PCI Expansion ROM Header
Offset
Byte
Length Value Description
0x00 1 0x55 ROM Signature, byte 1
0x01 1 0xAA ROM Signature, byte 2
0x02 2 XXXX Initialization Size size of this image in units of 512 bytes. The size
includes this header.
0x04 4 0x0EF1 Signature from EFI image header
0x08 2 XX Subsystem value for EFI image header
0x0a 2 XX Machine type from EFI image header
0x0c 10 XX Reserved
0x16 2 XX Offset to EFI Image header
0x18 2 XX Offset to PCI Data Structure
18.3 Multiple Image Format Support
With the extension defined in this chapter it is possible to discover an EFI driver image in a
PCI ROM. Since EFI images are defined with relocation there is no inherent limit as to where in
memory it can be loaded. However, EFI driver images will only be loaded if enough free memory
exists in the system.
An EFI system will only load an image if the platform supports the image type. Currently EFI has
defined three image types: IA-32 image type; Itanium-based image type; and intermediate byte
stream image type. The IA-32 and Itanium-based image type represent 32-bit and 64-bit native
Intel architecture processor code that has knowledge about EFI interfaces. The intermediate byte
stream type is a place holder for a new format that will be defined in a subsequent version of the
EFI specification. A PCI expansion ROM may contain one or more EFI image types.
18.4 EFI PCI Expansion ROM Driver
PCI Expansion ROM drivers are no different from other EFI drivers that control hardware. (See
Chapter 4 for details on how to construct an EFI driver.) To access a device, a driver needs to
know the devices device path. For a driver loaded from a PCI Expansion ROM, the driver can
examine the device path found in the LOADED_IMAGE structure for the driver image to obtain the
device path of the device that driver image was loaded from. The driver must check that no other
driver is already controlling the device.
For the driver to perform I/O and DMA operations with the device, the driver must use the proper
DEVICE_IO protocol interfaces for the device. This is found by using the
LocateDevicePath() function with the device path of the device and the ID of the
DEVICE_IO protocol. See Chapter 6 for more information about the DEVICE_IO protocol.