Permalink
Switch branches/tags
Nothing to show
Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
21978 lines (18669 sloc) 422 KB
/*
This is a giant header file generated by clang's preprocessor containing all the core EFI tables and many useful
protocol headers. It was generated by including every protocol header in a package in the EDK and running `clang -E`
over it.
JB: The compiler used on the UDK2010 firmware installation automatically aligns
structure data members to 4 bytes. Ensure #pragma is set appropriately for a given structure.
*/
typedef unsigned long long UINT64;
typedef long long INT64;
typedef unsigned int UINT32;
typedef int INT32;
typedef unsigned short UINT16;
typedef unsigned short CHAR16;
typedef short INT16;
typedef unsigned char BOOLEAN;
typedef unsigned char UINT8;
typedef char CHAR8;
typedef signed char INT8;
//This may be 64 bit in later phases, but in the PEI phase it is confirmed to be 32 bits
//typedef UINT64 UINTN;
typedef UINT32 UINTN;
typedef INT64 INTN;
extern UINT8 _VerifySizeofBOOLEAN[(sizeof(BOOLEAN) == (1)) / (sizeof(BOOLEAN) == (1))];
extern UINT8 _VerifySizeofINT8[(sizeof(INT8) == (1)) / (sizeof(INT8) == (1))];
extern UINT8 _VerifySizeofUINT8[(sizeof(UINT8) == (1)) / (sizeof(UINT8) == (1))];
extern UINT8 _VerifySizeofINT16[(sizeof(INT16) == (2)) / (sizeof(INT16) == (2))];
extern UINT8 _VerifySizeofUINT16[(sizeof(UINT16) == (2)) / (sizeof(UINT16) == (2))];
extern UINT8 _VerifySizeofINT32[(sizeof(INT32) == (4)) / (sizeof(INT32) == (4))];
extern UINT8 _VerifySizeofUINT32[(sizeof(UINT32) == (4)) / (sizeof(UINT32) == (4))];
extern UINT8 _VerifySizeofINT64[(sizeof(INT64) == (8)) / (sizeof(INT64) == (8))];
extern UINT8 _VerifySizeofUINT64[(sizeof(UINT64) == (8)) / (sizeof(UINT64) == (8))];
extern UINT8 _VerifySizeofCHAR8[(sizeof(CHAR8) == (1)) / (sizeof(CHAR8) == (1))];
extern UINT8 _VerifySizeofCHAR16[(sizeof(CHAR16) == (2)) / (sizeof(CHAR16) == (2))];
typedef struct {
UINT32 Data1;
UINT16 Data2;
UINT16 Data3;
UINT8 Data4[8];
} GUID;
typedef UINT64 PHYSICAL_ADDRESS;
typedef struct _LIST_ENTRY LIST_ENTRY;
struct _LIST_ENTRY {
LIST_ENTRY *ForwardLink;
LIST_ENTRY *BackLink;
};
typedef __builtin_va_list VA_LIST;
typedef UINTN *BASE_LIST;
typedef UINTN RETURN_STATUS;
typedef GUID EFI_GUID;
typedef RETURN_STATUS EFI_STATUS;
typedef void *EFI_HANDLE;
typedef void *EFI_EVENT;
typedef UINTN EFI_TPL;
typedef UINT64 EFI_LBA;
typedef UINT64 EFI_PHYSICAL_ADDRESS;
typedef UINT64 EFI_VIRTUAL_ADDRESS;
typedef struct {
UINT16 Year;
UINT8 Month;
UINT8 Day;
UINT8 Hour;
UINT8 Minute;
UINT8 Second;
UINT8 Pad1;
UINT32 Nanosecond;
INT16 TimeZone;
UINT8 Daylight;
UINT8 Pad2;
} EFI_TIME;
typedef struct {
UINT8 Addr[4];
} EFI_IPv4_ADDRESS;
typedef struct {
UINT8 Addr[16];
} EFI_IPv6_ADDRESS;
typedef struct {
UINT8 Addr[32];
} EFI_MAC_ADDRESS;
typedef union {
UINT32 Addr[4];
EFI_IPv4_ADDRESS v4;
EFI_IPv6_ADDRESS v6;
} EFI_IP_ADDRESS;
typedef struct {
UINT32 dwLength;
UINT16 wRevision;
UINT16 wCertificateType;
} WIN_CERTIFICATE;
typedef struct {
EFI_GUID HashType;
UINT8 PublicKey[256];
UINT8 Signature[256];
} EFI_CERT_BLOCK_RSA_2048_SHA256;
typedef struct {
WIN_CERTIFICATE Hdr;
EFI_GUID CertType;
UINT8 CertData[1];
} WIN_CERTIFICATE_UEFI_GUID;
typedef struct {
WIN_CERTIFICATE Hdr;
EFI_GUID HashAlgorithm;
} WIN_CERTIFICATE_EFI_PKCS1_15;
extern EFI_GUID gEfiCertTypeRsa2048Sha256Guid;
typedef enum {
EfiReservedMemoryType,
EfiLoaderCode,
EfiLoaderData,
EfiBootServicesCode,
EfiBootServicesData,
EfiRuntimeServicesCode,
EfiRuntimeServicesData,
EfiConventionalMemory,
EfiUnusableMemory,
EfiACPIReclaimMemory,
EfiACPIMemoryNVS,
EfiMemoryMappedIO,
EfiMemoryMappedIOPortSpace,
EfiPalCode,
EfiMaxMemoryType
} EFI_MEMORY_TYPE;
typedef struct {
UINT64 Signature;
UINT32 Revision;
UINT32 HeaderSize;
UINT32 CRC32;
UINT32 Reserved;
} EFI_TABLE_HEADER;
typedef struct {
UINT64 MonotonicCount;
WIN_CERTIFICATE_UEFI_GUID AuthInfo;
} EFI_VARIABLE_AUTHENTICATION;
typedef struct {
EFI_TIME TimeStamp;
WIN_CERTIFICATE_UEFI_GUID AuthInfo;
} EFI_VARIABLE_AUTHENTICATION_2;
extern EFI_GUID gEfiPcAnsiGuid;
extern EFI_GUID gEfiVT100Guid;
extern EFI_GUID gEfiVT100PlusGuid;
extern EFI_GUID gEfiVTUTF8Guid;
extern EFI_GUID gEfiUartDevicePathGuid;
extern EFI_GUID gEfiSasDevicePathGuid;
#pragma pack(1)
typedef struct {
UINT8 Type;
UINT8 SubType;
UINT8 Length[2];
} EFI_DEVICE_PATH_PROTOCOL;
typedef EFI_DEVICE_PATH_PROTOCOL EFI_DEVICE_PATH;
typedef struct {
EFI_DEVICE_PATH_PROTOCOL Header;
UINT8 Function;
UINT8 Device;
} PCI_DEVICE_PATH;
typedef struct {
EFI_DEVICE_PATH_PROTOCOL Header;
UINT8 FunctionNumber;
} PCCARD_DEVICE_PATH;
typedef struct {
EFI_DEVICE_PATH_PROTOCOL Header;
UINT32 MemoryType;
EFI_PHYSICAL_ADDRESS StartingAddress;
EFI_PHYSICAL_ADDRESS EndingAddress;
} MEMMAP_DEVICE_PATH;
typedef struct {
EFI_DEVICE_PATH_PROTOCOL Header;
EFI_GUID Guid;
} VENDOR_DEVICE_PATH;
typedef struct {
EFI_DEVICE_PATH_PROTOCOL Header;
UINT32 ControllerNumber;
} CONTROLLER_DEVICE_PATH;
typedef struct {
EFI_DEVICE_PATH_PROTOCOL Header;
UINT32 HID;
UINT32 UID;
} ACPI_HID_DEVICE_PATH;
typedef struct {
EFI_DEVICE_PATH_PROTOCOL Header;
UINT32 HID;
UINT32 UID;
UINT32 CID;
} ACPI_EXTENDED_HID_DEVICE_PATH;
typedef struct {
EFI_DEVICE_PATH_PROTOCOL Header;
UINT32 ADR;
} ACPI_ADR_DEVICE_PATH;
typedef struct {
EFI_DEVICE_PATH_PROTOCOL Header;
UINT8 PrimarySecondary;
UINT8 SlaveMaster;
UINT16 Lun;
} ATAPI_DEVICE_PATH;
typedef struct {
EFI_DEVICE_PATH_PROTOCOL Header;
UINT16 Pun;
UINT16 Lun;
} SCSI_DEVICE_PATH;
typedef struct {
EFI_DEVICE_PATH_PROTOCOL Header;
UINT32 Reserved;
UINT64 WWN;
UINT64 Lun;
} FIBRECHANNEL_DEVICE_PATH;
typedef struct {
EFI_DEVICE_PATH_PROTOCOL Header;
UINT32 Reserved;
UINT8 WWN[8];
UINT8 Lun[8];
} FIBRECHANNELEX_DEVICE_PATH;
typedef struct {
EFI_DEVICE_PATH_PROTOCOL Header;
UINT32 Reserved;
UINT64 Guid;
} F1394_DEVICE_PATH;
typedef struct {
EFI_DEVICE_PATH_PROTOCOL Header;
UINT8 ParentPortNumber;
UINT8 InterfaceNumber;
} USB_DEVICE_PATH;
typedef struct {
EFI_DEVICE_PATH_PROTOCOL Header;
UINT16 VendorId;
UINT16 ProductId;
UINT8 DeviceClass;
UINT8 DeviceSubClass;
UINT8 DeviceProtocol;
} USB_CLASS_DEVICE_PATH;
typedef struct {
EFI_DEVICE_PATH_PROTOCOL Header;
UINT16 InterfaceNumber;
UINT16 VendorId;
UINT16 ProductId;
} USB_WWID_DEVICE_PATH;
typedef struct {
EFI_DEVICE_PATH_PROTOCOL Header;
UINT8 Lun;
} DEVICE_LOGICAL_UNIT_DEVICE_PATH;
typedef struct {
EFI_DEVICE_PATH_PROTOCOL Header;
UINT16 HBAPortNumber;
UINT16 PortMultiplierPortNumber;
UINT16 Lun;
} SATA_DEVICE_PATH;
typedef struct {
EFI_DEVICE_PATH_PROTOCOL Header;
UINT32 Tid;
} I2O_DEVICE_PATH;
typedef struct {
EFI_DEVICE_PATH_PROTOCOL Header;
EFI_MAC_ADDRESS MacAddress;
UINT8 IfType;
} MAC_ADDR_DEVICE_PATH;
typedef struct {
EFI_DEVICE_PATH_PROTOCOL Header;
EFI_IPv4_ADDRESS LocalIpAddress;
EFI_IPv4_ADDRESS RemoteIpAddress;
UINT16 LocalPort;
UINT16 RemotePort;
UINT16 Protocol;
BOOLEAN StaticIpAddress;
EFI_IPv4_ADDRESS GatewayIpAddress;
EFI_IPv4_ADDRESS SubnetMask;
} IPv4_DEVICE_PATH;
typedef struct {
EFI_DEVICE_PATH_PROTOCOL Header;
EFI_IPv6_ADDRESS LocalIpAddress;
EFI_IPv6_ADDRESS RemoteIpAddress;
UINT16 LocalPort;
UINT16 RemotePort;
UINT16 Protocol;
UINT8 IpAddressOrigin;
UINT8 PrefixLength;
EFI_IPv6_ADDRESS GatewayIpAddress;
} IPv6_DEVICE_PATH;
typedef struct {
EFI_DEVICE_PATH_PROTOCOL Header;
UINT32 ResourceFlags;
UINT8 PortGid[16];
UINT64 ServiceId;
UINT64 TargetPortId;
UINT64 DeviceId;
} INFINIBAND_DEVICE_PATH;
typedef struct {
EFI_DEVICE_PATH_PROTOCOL Header;
UINT32 Reserved;
UINT64 BaudRate;
UINT8 DataBits;
UINT8 Parity;
UINT8 StopBits;
} UART_DEVICE_PATH;
typedef VENDOR_DEVICE_PATH VENDOR_DEFINED_DEVICE_PATH;
typedef struct {
EFI_DEVICE_PATH_PROTOCOL Header;
EFI_GUID Guid;
UINT32 FlowControlMap;
} UART_FLOW_CONTROL_DEVICE_PATH;
typedef struct {
EFI_DEVICE_PATH_PROTOCOL Header;
EFI_GUID Guid;
UINT32 Reserved;
UINT64 SasAddress;
UINT64 Lun;
UINT16 DeviceTopology;
UINT16 RelativeTargetPort;
} SAS_DEVICE_PATH;
typedef struct {
EFI_DEVICE_PATH_PROTOCOL Header;
UINT8 SasAddress[8];
UINT8 Lun[8];
UINT16 DeviceTopology;
UINT16 RelativeTargetPort;
} SASEX_DEVICE_PATH;
typedef struct {
EFI_DEVICE_PATH_PROTOCOL Header;
UINT16 NetworkProtocol;
UINT16 LoginOption;
UINT64 Lun;
UINT16 TargetPortalGroupTag;
} ISCSI_DEVICE_PATH;
typedef struct {
EFI_DEVICE_PATH_PROTOCOL Header;
UINT16 VlanId;
} VLAN_DEVICE_PATH;
typedef struct {
EFI_DEVICE_PATH_PROTOCOL Header;
UINT32 PartitionNumber;
UINT64 PartitionStart;
UINT64 PartitionSize;
UINT8 Signature[16];
UINT8 MBRType;
UINT8 SignatureType;
} HARDDRIVE_DEVICE_PATH;
typedef struct {
EFI_DEVICE_PATH_PROTOCOL Header;
UINT32 BootEntry;
UINT64 PartitionStart;
UINT64 PartitionSize;
} CDROM_DEVICE_PATH;
typedef struct {
EFI_DEVICE_PATH_PROTOCOL Header;
CHAR16 PathName[1];
} FILEPATH_DEVICE_PATH;
typedef struct {
EFI_DEVICE_PATH_PROTOCOL Header;
EFI_GUID Protocol;
} MEDIA_PROTOCOL_DEVICE_PATH;
typedef struct {
EFI_DEVICE_PATH_PROTOCOL Header;
EFI_GUID FvFileName;
} MEDIA_FW_VOL_FILEPATH_DEVICE_PATH;
typedef struct {
EFI_DEVICE_PATH_PROTOCOL Header;
EFI_GUID FvName;
} MEDIA_FW_VOL_DEVICE_PATH;
typedef struct {
EFI_DEVICE_PATH_PROTOCOL Header;
UINT32 Reserved;
UINT64 StartingOffset;
UINT64 EndingOffset;
} MEDIA_RELATIVE_OFFSET_RANGE_DEVICE_PATH;
typedef struct {
EFI_DEVICE_PATH_PROTOCOL Header;
UINT16 DeviceType;
UINT16 StatusFlag;
CHAR8 String[1];
} BBS_BBS_DEVICE_PATH;
typedef union {
EFI_DEVICE_PATH_PROTOCOL DevPath;
PCI_DEVICE_PATH Pci;
PCCARD_DEVICE_PATH PcCard;
MEMMAP_DEVICE_PATH MemMap;
VENDOR_DEVICE_PATH Vendor;
CONTROLLER_DEVICE_PATH Controller;
ACPI_HID_DEVICE_PATH Acpi;
ACPI_EXTENDED_HID_DEVICE_PATH ExtendedAcpi;
ACPI_ADR_DEVICE_PATH AcpiAdr;
ATAPI_DEVICE_PATH Atapi;
SCSI_DEVICE_PATH Scsi;
ISCSI_DEVICE_PATH Iscsi;
FIBRECHANNEL_DEVICE_PATH FibreChannel;
FIBRECHANNELEX_DEVICE_PATH FibreChannelEx;
F1394_DEVICE_PATH F1394;
USB_DEVICE_PATH Usb;
SATA_DEVICE_PATH Sata;
USB_CLASS_DEVICE_PATH UsbClass;
USB_WWID_DEVICE_PATH UsbWwid;
DEVICE_LOGICAL_UNIT_DEVICE_PATH LogicUnit;
I2O_DEVICE_PATH I2O;
MAC_ADDR_DEVICE_PATH MacAddr;
IPv4_DEVICE_PATH Ipv4;
IPv6_DEVICE_PATH Ipv6;
VLAN_DEVICE_PATH Vlan;
INFINIBAND_DEVICE_PATH InfiniBand;
UART_DEVICE_PATH Uart;
UART_FLOW_CONTROL_DEVICE_PATH UartFlowControl;
SAS_DEVICE_PATH Sas;
SASEX_DEVICE_PATH SasEx;
HARDDRIVE_DEVICE_PATH HardDrive;
CDROM_DEVICE_PATH CD;
FILEPATH_DEVICE_PATH FilePath;
MEDIA_PROTOCOL_DEVICE_PATH MediaProtocol;
MEDIA_FW_VOL_DEVICE_PATH FirmwareVolume;
MEDIA_FW_VOL_FILEPATH_DEVICE_PATH FirmwareFile;
MEDIA_RELATIVE_OFFSET_RANGE_DEVICE_PATH Offset;
BBS_BBS_DEVICE_PATH Bbs;
} EFI_DEV_PATH;
typedef union {
EFI_DEVICE_PATH_PROTOCOL *DevPath;
PCI_DEVICE_PATH *Pci;
PCCARD_DEVICE_PATH *PcCard;
MEMMAP_DEVICE_PATH *MemMap;
VENDOR_DEVICE_PATH *Vendor;
CONTROLLER_DEVICE_PATH *Controller;
ACPI_HID_DEVICE_PATH *Acpi;
ACPI_EXTENDED_HID_DEVICE_PATH *ExtendedAcpi;
ACPI_ADR_DEVICE_PATH *AcpiAdr;
ATAPI_DEVICE_PATH *Atapi;
SCSI_DEVICE_PATH *Scsi;
ISCSI_DEVICE_PATH *Iscsi;
FIBRECHANNEL_DEVICE_PATH *FibreChannel;
FIBRECHANNELEX_DEVICE_PATH *FibreChannelEx;
F1394_DEVICE_PATH *F1394;
USB_DEVICE_PATH *Usb;
SATA_DEVICE_PATH *Sata;
USB_CLASS_DEVICE_PATH *UsbClass;
USB_WWID_DEVICE_PATH *UsbWwid;
DEVICE_LOGICAL_UNIT_DEVICE_PATH *LogicUnit;
I2O_DEVICE_PATH *I2O;
MAC_ADDR_DEVICE_PATH *MacAddr;
IPv4_DEVICE_PATH *Ipv4;
IPv6_DEVICE_PATH *Ipv6;
VLAN_DEVICE_PATH *Vlan;
INFINIBAND_DEVICE_PATH *InfiniBand;
UART_DEVICE_PATH *Uart;
UART_FLOW_CONTROL_DEVICE_PATH *UartFlowControl;
SAS_DEVICE_PATH *Sas;
SASEX_DEVICE_PATH *SasEx;
HARDDRIVE_DEVICE_PATH *HardDrive;
CDROM_DEVICE_PATH *CD;
FILEPATH_DEVICE_PATH *FilePath;
MEDIA_PROTOCOL_DEVICE_PATH *MediaProtocol;
MEDIA_FW_VOL_DEVICE_PATH *FirmwareVolume;
MEDIA_FW_VOL_FILEPATH_DEVICE_PATH *FirmwareFile;
MEDIA_RELATIVE_OFFSET_RANGE_DEVICE_PATH *Offset;
BBS_BBS_DEVICE_PATH *Bbs;
UINT8 *Raw;
} EFI_DEV_PATH_PTR;
#pragma pack()
extern EFI_GUID gEfiDevicePathProtocolGuid;
typedef struct _EFI_SIMPLE_TEXT_INPUT_PROTOCOL EFI_SIMPLE_TEXT_INPUT_PROTOCOL;
typedef struct _EFI_SIMPLE_TEXT_INPUT_PROTOCOL SIMPLE_INPUT_INTERFACE;
typedef struct {
UINT16 ScanCode;
CHAR16 UnicodeChar;
} EFI_INPUT_KEY;
typedef
EFI_STATUS
( *EFI_INPUT_RESET)(
EFI_SIMPLE_TEXT_INPUT_PROTOCOL *This,
BOOLEAN ExtendedVerification
);
typedef
EFI_STATUS
( *EFI_INPUT_READ_KEY)(
EFI_SIMPLE_TEXT_INPUT_PROTOCOL *This,
EFI_INPUT_KEY *Key
);
struct _EFI_SIMPLE_TEXT_INPUT_PROTOCOL {
EFI_INPUT_RESET Reset;
EFI_INPUT_READ_KEY ReadKeyStroke;
EFI_EVENT WaitForKey;
};
extern EFI_GUID gEfiSimpleTextInProtocolGuid;
typedef struct _EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL;
typedef
EFI_STATUS
( *EFI_INPUT_RESET_EX)(
EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL *This,
BOOLEAN ExtendedVerification
);
typedef UINT8 EFI_KEY_TOGGLE_STATE;
typedef struct _EFI_KEY_STATE {
UINT32 KeyShiftState;
EFI_KEY_TOGGLE_STATE KeyToggleState;
} EFI_KEY_STATE;
typedef struct {
EFI_INPUT_KEY Key;
EFI_KEY_STATE KeyState;
} EFI_KEY_DATA;
typedef
EFI_STATUS
( *EFI_INPUT_READ_KEY_EX)(
EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL *This,
EFI_KEY_DATA *KeyData
);
typedef
EFI_STATUS
( *EFI_SET_STATE)(
EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL *This,
EFI_KEY_TOGGLE_STATE *KeyToggleState
);
typedef
EFI_STATUS
( *EFI_KEY_NOTIFY_FUNCTION)(
EFI_KEY_DATA *KeyData
);
typedef
EFI_STATUS
( *EFI_REGISTER_KEYSTROKE_NOTIFY)(
EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL *This,
EFI_KEY_DATA *KeyData,
EFI_KEY_NOTIFY_FUNCTION KeyNotificationFunction,
EFI_HANDLE *NotifyHandle
);
typedef
EFI_STATUS
( *EFI_UNREGISTER_KEYSTROKE_NOTIFY)(
EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL *This,
EFI_HANDLE NotificationHandle
);
struct _EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL{
EFI_INPUT_RESET_EX Reset;
EFI_INPUT_READ_KEY_EX ReadKeyStrokeEx;
EFI_EVENT WaitForKeyEx;
EFI_SET_STATE SetState;
EFI_REGISTER_KEYSTROKE_NOTIFY RegisterKeyNotify;
EFI_UNREGISTER_KEYSTROKE_NOTIFY UnregisterKeyNotify;
};
extern EFI_GUID gEfiSimpleTextInputExProtocolGuid;
typedef struct _EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL;
typedef EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL SIMPLE_TEXT_OUTPUT_INTERFACE;
typedef
EFI_STATUS
( *EFI_TEXT_RESET)(
EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL *This,
BOOLEAN ExtendedVerification
);
typedef
EFI_STATUS
( *EFI_TEXT_STRING)(
EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL *This,
CHAR16 *String
);
typedef
EFI_STATUS
( *EFI_TEXT_TEST_STRING)(
EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL *This,
CHAR16 *String
);
typedef
EFI_STATUS
( *EFI_TEXT_QUERY_MODE)(
EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL *This,
UINTN ModeNumber,
UINTN *Columns,
UINTN *Rows
);
typedef
EFI_STATUS
( *EFI_TEXT_SET_MODE)(
EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL *This,
UINTN ModeNumber
);
typedef
EFI_STATUS
( *EFI_TEXT_SET_ATTRIBUTE)(
EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL *This,
UINTN Attribute
);
typedef
EFI_STATUS
( *EFI_TEXT_CLEAR_SCREEN)(
EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL *This
);
typedef
EFI_STATUS
( *EFI_TEXT_SET_CURSOR_POSITION)(
EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL *This,
UINTN Column,
UINTN Row
);
typedef
EFI_STATUS
( *EFI_TEXT_ENABLE_CURSOR)(
EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL *This,
BOOLEAN Visible
);
typedef struct {
INT32 MaxMode;
INT32 Mode;
INT32 Attribute;
INT32 CursorColumn;
INT32 CursorRow;
BOOLEAN CursorVisible;
} EFI_SIMPLE_TEXT_OUTPUT_MODE;
struct _EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL {
EFI_TEXT_RESET Reset;
EFI_TEXT_STRING OutputString;
EFI_TEXT_TEST_STRING TestString;
EFI_TEXT_QUERY_MODE QueryMode;
EFI_TEXT_SET_MODE SetMode;
EFI_TEXT_SET_ATTRIBUTE SetAttribute;
EFI_TEXT_CLEAR_SCREEN ClearScreen;
EFI_TEXT_SET_CURSOR_POSITION SetCursorPosition;
EFI_TEXT_ENABLE_CURSOR EnableCursor;
EFI_SIMPLE_TEXT_OUTPUT_MODE *Mode;
};
extern EFI_GUID gEfiSimpleTextOutProtocolGuid;
typedef enum {
AllocateAnyPages,
AllocateMaxAddress,
AllocateAddress,
MaxAllocateType
} EFI_ALLOCATE_TYPE;
typedef struct {
UINT32 Type;
EFI_PHYSICAL_ADDRESS PhysicalStart;
EFI_VIRTUAL_ADDRESS VirtualStart;
UINT64 NumberOfPages;
UINT64 Attribute;
} EFI_MEMORY_DESCRIPTOR;
typedef
EFI_STATUS
( *EFI_ALLOCATE_PAGES)(
EFI_ALLOCATE_TYPE Type,
EFI_MEMORY_TYPE MemoryType,
UINTN Pages,
EFI_PHYSICAL_ADDRESS *Memory
);
typedef
EFI_STATUS
( *EFI_FREE_PAGES)(
EFI_PHYSICAL_ADDRESS Memory,
UINTN Pages
);
typedef
EFI_STATUS
( *EFI_GET_MEMORY_MAP)(
UINTN *MemoryMapSize,
EFI_MEMORY_DESCRIPTOR *MemoryMap,
UINTN *MapKey,
UINTN *DescriptorSize,
UINT32 *DescriptorVersion
);
typedef
EFI_STATUS
( *EFI_ALLOCATE_POOL)(
EFI_MEMORY_TYPE PoolType,
UINTN Size,
void **Buffer
);
typedef
EFI_STATUS
( *EFI_FREE_POOL)(
void *Buffer
);
typedef
EFI_STATUS
( *EFI_SET_VIRTUAL_ADDRESS_MAP)(
UINTN MemoryMapSize,
UINTN DescriptorSize,
UINT32 DescriptorVersion,
EFI_MEMORY_DESCRIPTOR *VirtualMap
);
typedef
EFI_STATUS
( *EFI_CONNECT_CONTROLLER)(
EFI_HANDLE ControllerHandle,
EFI_HANDLE *DriverImageHandle,
EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath,
BOOLEAN Recursive
);
typedef
EFI_STATUS
( *EFI_DISCONNECT_CONTROLLER)(
EFI_HANDLE ControllerHandle,
EFI_HANDLE DriverImageHandle,
EFI_HANDLE ChildHandle
);
typedef
EFI_STATUS
( *EFI_CONVERT_POINTER)(
UINTN DebugDisposition,
void **Address
);
typedef
void
( *EFI_EVENT_NOTIFY)(
EFI_EVENT Event,
void *Context
);
typedef
EFI_STATUS
( *EFI_CREATE_EVENT)(
UINT32 Type,
EFI_TPL NotifyTpl,
EFI_EVENT_NOTIFY NotifyFunction,
void *NotifyContext,
EFI_EVENT *Event
);
typedef
EFI_STATUS
( *EFI_CREATE_EVENT_EX)(
UINT32 Type,
EFI_TPL NotifyTpl,
EFI_EVENT_NOTIFY NotifyFunction ,
void *NotifyContext ,
EFI_GUID *EventGroup ,
EFI_EVENT *Event
);
typedef enum {
TimerCancel,
TimerPeriodic,
TimerRelative
} EFI_TIMER_DELAY;
typedef
EFI_STATUS
( *EFI_SET_TIMER)(
EFI_EVENT Event,
EFI_TIMER_DELAY Type,
UINT64 TriggerTime
);
typedef
EFI_STATUS
( *EFI_SIGNAL_EVENT)(
EFI_EVENT Event
);
typedef
EFI_STATUS
( *EFI_WAIT_FOR_EVENT)(
UINTN NumberOfEvents,
EFI_EVENT *Event,
UINTN *Index
);
typedef
EFI_STATUS
( *EFI_CLOSE_EVENT)(
EFI_EVENT Event
);
typedef
EFI_STATUS
( *EFI_CHECK_EVENT)(
EFI_EVENT Event
);
typedef
EFI_TPL
( *EFI_RAISE_TPL)(
EFI_TPL NewTpl
);
typedef
void
( *EFI_RESTORE_TPL)(
EFI_TPL OldTpl
);
typedef
EFI_STATUS
( *EFI_GET_VARIABLE)(
CHAR16 *VariableName,
EFI_GUID *VendorGuid,
UINT32 *Attributes,
UINTN *DataSize,
void *Data
);
typedef
EFI_STATUS
( *EFI_GET_NEXT_VARIABLE_NAME)(
UINTN *VariableNameSize,
CHAR16 *VariableName,
EFI_GUID *VendorGuid
);
typedef
EFI_STATUS
( *EFI_SET_VARIABLE)(
CHAR16 *VariableName,
EFI_GUID *VendorGuid,
UINT32 Attributes,
UINTN DataSize,
void *Data
);
typedef struct {
UINT32 Resolution;
UINT32 Accuracy;
BOOLEAN SetsToZero;
} EFI_TIME_CAPABILITIES;
typedef
EFI_STATUS
( *EFI_GET_TIME)(
EFI_TIME *Time,
EFI_TIME_CAPABILITIES *Capabilities
);
typedef
EFI_STATUS
( *EFI_SET_TIME)(
EFI_TIME *Time
);
typedef
EFI_STATUS
( *EFI_GET_WAKEUP_TIME)(
BOOLEAN *Enabled,
BOOLEAN *Pending,
EFI_TIME *Time
);
typedef
EFI_STATUS
( *EFI_SET_WAKEUP_TIME)(
BOOLEAN Enable,
EFI_TIME *Time
);
typedef
EFI_STATUS
( *EFI_IMAGE_LOAD)(
BOOLEAN BootPolicy,
EFI_HANDLE ParentImageHandle,
EFI_DEVICE_PATH_PROTOCOL *DevicePath,
void *SourceBuffer ,
UINTN SourceSize,
EFI_HANDLE *ImageHandle
);
typedef
EFI_STATUS
( *EFI_IMAGE_START)(
EFI_HANDLE ImageHandle,
UINTN *ExitDataSize,
CHAR16 **ExitData
);
typedef
EFI_STATUS
( *EFI_EXIT)(
EFI_HANDLE ImageHandle,
EFI_STATUS ExitStatus,
UINTN ExitDataSize,
CHAR16 *ExitData
);
typedef
EFI_STATUS
( *EFI_IMAGE_UNLOAD)(
EFI_HANDLE ImageHandle
);
typedef
EFI_STATUS
( *EFI_EXIT_BOOT_SERVICES)(
EFI_HANDLE ImageHandle,
UINTN MapKey
);
typedef
EFI_STATUS
( *EFI_STALL)(
UINTN Microseconds
);
typedef
EFI_STATUS
( *EFI_SET_WATCHDOG_TIMER)(
UINTN Timeout,
UINT64 WatchdogCode,
UINTN DataSize,
CHAR16 *WatchdogData
);
typedef enum {
EfiResetCold,
EfiResetWarm,
EfiResetShutdown
} EFI_RESET_TYPE;
typedef
void
( *EFI_RESET_SYSTEM)(
EFI_RESET_TYPE ResetType,
EFI_STATUS ResetStatus,
UINTN DataSize,
void *ResetData
);
typedef
EFI_STATUS
( *EFI_GET_NEXT_MONOTONIC_COUNT)(
UINT64 *Count
);
typedef
EFI_STATUS
( *EFI_GET_NEXT_HIGH_MONO_COUNT)(
UINT32 *HighCount
);
typedef
EFI_STATUS
( *EFI_CALCULATE_CRC32)(
void *Data,
UINTN DataSize,
UINT32 *Crc32
);
typedef
void
( *EFI_COPY_MEM)(
void *Destination,
void *Source,
UINTN Length
);
typedef
void
( *EFI_SET_MEM)(
void *Buffer,
UINTN Size,
UINT8 Value
);
typedef enum {
EFI_NATIVE_INTERFACE
} EFI_INTERFACE_TYPE;
typedef
EFI_STATUS
( *EFI_INSTALL_PROTOCOL_INTERFACE)(
EFI_HANDLE *Handle,
EFI_GUID *Protocol,
EFI_INTERFACE_TYPE InterfaceType,
void *Interface
);
typedef
EFI_STATUS
( *EFI_INSTALL_MULTIPLE_PROTOCOL_INTERFACES)(
EFI_HANDLE *Handle,
...
);
typedef
EFI_STATUS
( *EFI_REINSTALL_PROTOCOL_INTERFACE)(
EFI_HANDLE Handle,
EFI_GUID *Protocol,
void *OldInterface,
void *NewInterface
);
typedef
EFI_STATUS
( *EFI_UNINSTALL_PROTOCOL_INTERFACE)(
EFI_HANDLE Handle,
EFI_GUID *Protocol,
void *Interface
);
typedef
EFI_STATUS
( *EFI_UNINSTALL_MULTIPLE_PROTOCOL_INTERFACES)(
EFI_HANDLE Handle,
...
);
typedef
EFI_STATUS
( *EFI_HANDLE_PROTOCOL)(
EFI_HANDLE Handle,
EFI_GUID *Protocol,
void **Interface
);
typedef
EFI_STATUS
( *EFI_OPEN_PROTOCOL)(
EFI_HANDLE Handle,
EFI_GUID *Protocol,
void **Interface,
EFI_HANDLE AgentHandle,
EFI_HANDLE ControllerHandle,
UINT32 Attributes
);
typedef
EFI_STATUS
( *EFI_CLOSE_PROTOCOL)(
EFI_HANDLE Handle,
EFI_GUID *Protocol,
EFI_HANDLE AgentHandle,
EFI_HANDLE ControllerHandle
);
typedef struct {
EFI_HANDLE AgentHandle;
EFI_HANDLE ControllerHandle;
UINT32 Attributes;
UINT32 OpenCount;
} EFI_OPEN_PROTOCOL_INFORMATION_ENTRY;
typedef
EFI_STATUS
( *EFI_OPEN_PROTOCOL_INFORMATION)(
EFI_HANDLE Handle,
EFI_GUID *Protocol,
EFI_OPEN_PROTOCOL_INFORMATION_ENTRY **EntryBuffer,
UINTN *EntryCount
);
typedef
EFI_STATUS
( *EFI_PROTOCOLS_PER_HANDLE)(
EFI_HANDLE Handle,
EFI_GUID ***ProtocolBuffer,
UINTN *ProtocolBufferCount
);
typedef
EFI_STATUS
( *EFI_REGISTER_PROTOCOL_NOTIFY)(
EFI_GUID *Protocol,
EFI_EVENT Event,
void **Registration
);
typedef enum {
AllHandles,
ByRegisterNotify,
ByProtocol
} EFI_LOCATE_SEARCH_TYPE;
typedef
EFI_STATUS
( *EFI_LOCATE_HANDLE)(
EFI_LOCATE_SEARCH_TYPE SearchType,
EFI_GUID *Protocol,
void *SearchKey,
UINTN *BufferSize,
EFI_HANDLE *Buffer
);
typedef
EFI_STATUS
( *EFI_LOCATE_DEVICE_PATH)(
EFI_GUID *Protocol,
EFI_DEVICE_PATH_PROTOCOL **DevicePath,
EFI_HANDLE *Device
);
typedef
EFI_STATUS
( *EFI_INSTALL_CONFIGURATION_TABLE)(
EFI_GUID *Guid,
void *Table
);
typedef
EFI_STATUS
( *EFI_LOCATE_HANDLE_BUFFER)(
EFI_LOCATE_SEARCH_TYPE SearchType,
EFI_GUID *Protocol,
void *SearchKey,
UINTN *NoHandles,
EFI_HANDLE **Buffer
);
typedef
EFI_STATUS
( *EFI_LOCATE_PROTOCOL)(
EFI_GUID *Protocol,
void *Registration,
void **Interface
);
typedef struct {
UINT64 Length;
union {
EFI_PHYSICAL_ADDRESS DataBlock;
EFI_PHYSICAL_ADDRESS ContinuationPointer;
} Union;
} EFI_CAPSULE_BLOCK_DESCRIPTOR;
typedef struct {
EFI_GUID CapsuleGuid;
UINT32 HeaderSize;
UINT32 Flags;
UINT32 CapsuleImageSize;
} EFI_CAPSULE_HEADER;
typedef struct {
UINT32 CapsuleArrayNumber;
void* CapsulePtr[1];
} EFI_CAPSULE_TABLE;
typedef
EFI_STATUS
( *EFI_UPDATE_CAPSULE)(
EFI_CAPSULE_HEADER **CapsuleHeaderArray,
UINTN CapsuleCount,
EFI_PHYSICAL_ADDRESS ScatterGatherList
);
typedef
EFI_STATUS
( *EFI_QUERY_CAPSULE_CAPABILITIES)(
EFI_CAPSULE_HEADER **CapsuleHeaderArray,
UINTN CapsuleCount,
UINT64 *MaximumCapsuleSize,
EFI_RESET_TYPE *ResetType
);
typedef
EFI_STATUS
( *EFI_QUERY_VARIABLE_INFO)(
UINT32 Attributes,
UINT64 *MaximumVariableStorageSize,
UINT64 *RemainingVariableStorageSize,
UINT64 *MaximumVariableSize
);
typedef struct {
EFI_TABLE_HEADER Hdr;
EFI_GET_TIME GetTime;
EFI_SET_TIME SetTime;
EFI_GET_WAKEUP_TIME GetWakeupTime;
EFI_SET_WAKEUP_TIME SetWakeupTime;
EFI_SET_VIRTUAL_ADDRESS_MAP SetVirtualAddressMap;
EFI_CONVERT_POINTER ConvertPointer;
EFI_GET_VARIABLE GetVariable;
EFI_GET_NEXT_VARIABLE_NAME GetNextVariableName;
EFI_SET_VARIABLE SetVariable;
EFI_GET_NEXT_HIGH_MONO_COUNT GetNextHighMonotonicCount;
EFI_RESET_SYSTEM ResetSystem;
EFI_UPDATE_CAPSULE UpdateCapsule;
EFI_QUERY_CAPSULE_CAPABILITIES QueryCapsuleCapabilities;
EFI_QUERY_VARIABLE_INFO QueryVariableInfo;
} EFI_RUNTIME_SERVICES;
typedef struct {
EFI_TABLE_HEADER Hdr;
EFI_RAISE_TPL RaiseTPL;
EFI_RESTORE_TPL RestoreTPL;
EFI_ALLOCATE_PAGES AllocatePages;
EFI_FREE_PAGES FreePages;
EFI_GET_MEMORY_MAP GetMemoryMap;
EFI_ALLOCATE_POOL AllocatePool;
EFI_FREE_POOL FreePool;
EFI_CREATE_EVENT CreateEvent;
EFI_SET_TIMER SetTimer;
EFI_WAIT_FOR_EVENT WaitForEvent;
EFI_SIGNAL_EVENT SignalEvent;
EFI_CLOSE_EVENT CloseEvent;
EFI_CHECK_EVENT CheckEvent;
EFI_INSTALL_PROTOCOL_INTERFACE InstallProtocolInterface;
EFI_REINSTALL_PROTOCOL_INTERFACE ReinstallProtocolInterface;
EFI_UNINSTALL_PROTOCOL_INTERFACE UninstallProtocolInterface;
EFI_HANDLE_PROTOCOL HandleProtocol;
void *Reserved;
EFI_REGISTER_PROTOCOL_NOTIFY RegisterProtocolNotify;
EFI_LOCATE_HANDLE LocateHandle;
EFI_LOCATE_DEVICE_PATH LocateDevicePath;
EFI_INSTALL_CONFIGURATION_TABLE InstallConfigurationTable;
EFI_IMAGE_LOAD LoadImage;
EFI_IMAGE_START StartImage;
EFI_EXIT Exit;
EFI_IMAGE_UNLOAD UnloadImage;
EFI_EXIT_BOOT_SERVICES ExitBootServices;
EFI_GET_NEXT_MONOTONIC_COUNT GetNextMonotonicCount;
EFI_STALL Stall;
EFI_SET_WATCHDOG_TIMER SetWatchdogTimer;
EFI_CONNECT_CONTROLLER ConnectController;
EFI_DISCONNECT_CONTROLLER DisconnectController;
EFI_OPEN_PROTOCOL OpenProtocol;
EFI_CLOSE_PROTOCOL CloseProtocol;
EFI_OPEN_PROTOCOL_INFORMATION OpenProtocolInformation;
EFI_PROTOCOLS_PER_HANDLE ProtocolsPerHandle;
EFI_LOCATE_HANDLE_BUFFER LocateHandleBuffer;
EFI_LOCATE_PROTOCOL LocateProtocol;
EFI_INSTALL_MULTIPLE_PROTOCOL_INTERFACES InstallMultipleProtocolInterfaces;
EFI_UNINSTALL_MULTIPLE_PROTOCOL_INTERFACES UninstallMultipleProtocolInterfaces;
EFI_CALCULATE_CRC32 CalculateCrc32;
EFI_COPY_MEM CopyMem;
EFI_SET_MEM SetMem;
EFI_CREATE_EVENT_EX CreateEventEx;
} EFI_BOOT_SERVICES;
typedef struct {
EFI_GUID VendorGuid;
void *VendorTable;
} EFI_CONFIGURATION_TABLE;
typedef struct {
EFI_TABLE_HEADER Hdr;
CHAR16 *FirmwareVendor;
UINT32 FirmwareRevision;
EFI_HANDLE ConsoleInHandle;
EFI_SIMPLE_TEXT_INPUT_PROTOCOL *ConIn;
EFI_HANDLE ConsoleOutHandle;
EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL *ConOut;
EFI_HANDLE StandardErrorHandle;
EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL *StdErr;
EFI_RUNTIME_SERVICES *RuntimeServices;
EFI_BOOT_SERVICES *BootServices;
UINTN NumberOfTableEntries;
EFI_CONFIGURATION_TABLE *ConfigurationTable;
} EFI_SYSTEM_TABLE;
typedef
EFI_STATUS
( *EFI_IMAGE_ENTRY_POINT)(
EFI_HANDLE ImageHandle,
EFI_SYSTEM_TABLE *SystemTable
);
typedef union {
struct {
UINT32 Revision : 8;
UINT32 ShiftPressed : 1;
UINT32 ControlPressed : 1;
UINT32 AltPressed : 1;
UINT32 LogoPressed : 1;
UINT32 MenuPressed : 1;
UINT32 SysReqPressed : 1;
UINT32 Reserved : 16;
UINT32 InputKeyCount : 2;
} Options;
UINT32 PackedValue;
} EFI_BOOT_KEY_DATA;
typedef struct {
EFI_BOOT_KEY_DATA KeyData;
UINT32 BootOptionCrc;
UINT16 BootOption;
} EFI_KEY_OPTION;
#pragma pack(1)
typedef void PXE_VOID;
typedef UINT8 PXE_UINT8;
typedef UINT16 PXE_UINT16;
typedef UINT32 PXE_UINT32;
typedef UINTN PXE_UINTN;
typedef UINT64 PXE_UINT64;
typedef PXE_UINT8 PXE_BOOL;
typedef PXE_UINT16 PXE_OPCODE;
typedef PXE_UINT16 PXE_OPFLAGS;
typedef PXE_UINT16 PXE_STATFLAGS;
typedef PXE_UINT16 PXE_STATCODE;
typedef PXE_UINT16 PXE_IFNUM;
typedef PXE_UINT16 PXE_CONTROL;
typedef PXE_UINT8 PXE_FRAME_TYPE;
typedef PXE_UINT32 PXE_IPV4;
typedef PXE_UINT32 PXE_IPV6[4];
typedef PXE_UINT8 PXE_MAC_ADDR[32];
typedef PXE_UINT8 PXE_IFTYPE;
typedef UINT16 PXE_MEDIA_PROTOCOL;
typedef struct s_pxe_hw_undi {
PXE_UINT32 Signature;
PXE_UINT8 Len;
PXE_UINT8 Fudge;
PXE_UINT8 Rev;
PXE_UINT8 IFcnt;
PXE_UINT8 MajorVer;
PXE_UINT8 MinorVer;
PXE_UINT16 reserved;
PXE_UINT32 Implementation;
} PXE_HW_UNDI;
typedef struct s_pxe_sw_undi {
PXE_UINT32 Signature;
PXE_UINT8 Len;
PXE_UINT8 Fudge;
PXE_UINT8 Rev;
PXE_UINT8 IFcnt;
PXE_UINT8 MajorVer;
PXE_UINT8 MinorVer;
PXE_UINT16 reserved1;
PXE_UINT32 Implementation;
PXE_UINT64 EntryPoint;
PXE_UINT8 reserved2[3];
PXE_UINT8 BusCnt;
PXE_UINT32 BusType[1];
} PXE_SW_UNDI;
typedef union u_pxe_undi {
PXE_HW_UNDI hw;
PXE_SW_UNDI sw;
} PXE_UNDI;
typedef struct s_pxe_cdb {
PXE_OPCODE OpCode;
PXE_OPFLAGS OpFlags;
PXE_UINT16 CPBsize;
PXE_UINT16 DBsize;
PXE_UINT64 CPBaddr;
PXE_UINT64 DBaddr;
PXE_STATCODE StatCode;
PXE_STATFLAGS StatFlags;
PXE_UINT16 IFnum;
PXE_CONTROL Control;
} PXE_CDB;
typedef union u_pxe_ip_addr {
PXE_IPV6 IPv6;
PXE_IPV4 IPv4;
} PXE_IP_ADDR;
typedef union pxe_device {
struct {
PXE_UINT32 BusType;
PXE_UINT16 Bus;
PXE_UINT8 Device;
PXE_UINT8 Function;
}
PCI, PCC;
} PXE_DEVICE;
typedef struct s_pxe_cpb_start_30 {
UINT64 Delay;
UINT64 Block;
UINT64 Virt2Phys;
UINT64 Mem_IO;
} PXE_CPB_START_30;
typedef struct s_pxe_cpb_start_31 {
UINT64 Delay;
UINT64 Block;
UINT64 Virt2Phys;
UINT64 Mem_IO;
UINT64 Map_Mem;
UINT64 UnMap_Mem;
UINT64 Sync_Mem;
UINT64 Unique_ID;
} PXE_CPB_START_31;
typedef struct s_pxe_db_get_init_info {
PXE_UINT32 MemoryRequired;
PXE_UINT32 FrameDataLen;
PXE_UINT32 LinkSpeeds[4];
PXE_UINT32 NvCount;
PXE_UINT16 NvWidth;
PXE_UINT16 MediaHeaderLen;
PXE_UINT16 HWaddrLen;
PXE_UINT16 MCastFilterCnt;
PXE_UINT16 TxBufCnt;
PXE_UINT16 TxBufSize;
PXE_UINT16 RxBufCnt;
PXE_UINT16 RxBufSize;
PXE_UINT8 IFtype;
PXE_UINT8 SupportedDuplexModes;
PXE_UINT8 SupportedLoopBackModes;
} PXE_DB_GET_INIT_INFO;
typedef struct s_pxe_pci_config_info {
UINT32 BusType;
UINT16 Bus;
UINT8 Device;
UINT8 Function;
union {
UINT8 Byte[256];
UINT16 Word[128];
UINT32 Dword[64];
} Config;
} PXE_PCI_CONFIG_INFO;
typedef struct s_pxe_pcc_config_info {
PXE_UINT32 BusType;
PXE_UINT16 Bus;
PXE_UINT8 Device;
PXE_UINT8 Function;
union {
PXE_UINT8 Byte[256];
PXE_UINT16 Word[128];
PXE_UINT32 Dword[64];
} Config;
} PXE_PCC_CONFIG_INFO;
typedef union u_pxe_db_get_config_info {
PXE_PCI_CONFIG_INFO pci;
PXE_PCC_CONFIG_INFO pcc;
} PXE_DB_GET_CONFIG_INFO;
typedef struct s_pxe_cpb_initialize {
PXE_UINT64 MemoryAddr;
PXE_UINT32 MemoryLength;
PXE_UINT32 LinkSpeed;
PXE_UINT16 TxBufCnt;
PXE_UINT16 TxBufSize;
PXE_UINT16 RxBufCnt;
PXE_UINT16 RxBufSize;
PXE_UINT8 DuplexMode;
PXE_UINT8 LoopBackMode;
} PXE_CPB_INITIALIZE;
typedef struct s_pxe_db_initialize {
PXE_UINT32 MemoryUsed;
PXE_UINT16 TxBufCnt;
PXE_UINT16 TxBufSize;
PXE_UINT16 RxBufCnt;
PXE_UINT16 RxBufSize;
} PXE_DB_INITIALIZE;
typedef struct s_pxe_cpb_receive_filters {
PXE_MAC_ADDR MCastList[8];
} PXE_CPB_RECEIVE_FILTERS;
typedef struct s_pxe_db_receive_filters {
PXE_MAC_ADDR MCastList[8];
} PXE_DB_RECEIVE_FILTERS;
typedef struct s_pxe_cpb_station_address {
PXE_MAC_ADDR StationAddr;
} PXE_CPB_STATION_ADDRESS;
typedef struct s_pxe_dpb_station_address {
PXE_MAC_ADDR StationAddr;
PXE_MAC_ADDR BroadcastAddr;
PXE_MAC_ADDR PermanentAddr;
} PXE_DB_STATION_ADDRESS;
typedef struct s_pxe_db_statistics {
PXE_UINT64 Supported;
PXE_UINT64 Data[64];
} PXE_DB_STATISTICS;
typedef struct s_pxe_cpb_mcast_ip_to_mac {
PXE_IP_ADDR IP;
} PXE_CPB_MCAST_IP_TO_MAC;
typedef struct s_pxe_db_mcast_ip_to_mac {
PXE_MAC_ADDR MAC;
} PXE_DB_MCAST_IP_TO_MAC;
typedef struct s_pxe_cpb_nvdata_sparse {
struct {
PXE_UINT32 Addr;
union {
PXE_UINT8 Byte;
PXE_UINT16 Word;
PXE_UINT32 Dword;
} Data;
} Item[128];
} PXE_CPB_NVDATA_SPARSE;
typedef union u_pxe_cpb_nvdata_bulk {
PXE_UINT8 Byte[128 << 2];
PXE_UINT16 Word[128 << 1];
PXE_UINT32 Dword[128];
} PXE_CPB_NVDATA_BULK;
typedef struct s_pxe_db_nvdata {
union {
PXE_UINT8 Byte[128 << 2];
PXE_UINT16 Word[128 << 1];
PXE_UINT32 Dword[128];
} Data;
} PXE_DB_NVDATA;
typedef struct s_pxe_db_get_status {
PXE_UINT32 RxFrameLen;
PXE_UINT32 reserved;
PXE_UINT64 TxBuffer[32];
} PXE_DB_GET_STATUS;
typedef struct s_pxe_cpb_fill_header {
PXE_MAC_ADDR SrcAddr;
PXE_MAC_ADDR DestAddr;
PXE_UINT64 MediaHeader;
PXE_UINT32 PacketLen;
PXE_UINT16 Protocol;
PXE_UINT16 MediaHeaderLen;
} PXE_CPB_FILL_HEADER;
typedef struct s_pxe_cpb_fill_header_fragmented {
PXE_MAC_ADDR SrcAddr;
PXE_MAC_ADDR DestAddr;
PXE_UINT32 PacketLen;
PXE_MEDIA_PROTOCOL Protocol;
PXE_UINT16 MediaHeaderLen;
PXE_UINT16 FragCnt;
PXE_UINT16 reserved;
struct {
PXE_UINT64 FragAddr;
PXE_UINT32 FragLen;
PXE_UINT32 reserved;
} FragDesc[16];
}
PXE_CPB_FILL_HEADER_FRAGMENTED;
typedef struct s_pxe_cpb_transmit {
PXE_UINT64 FrameAddr;
PXE_UINT32 DataLen;
PXE_UINT16 MediaheaderLen;
PXE_UINT16 reserved;
} PXE_CPB_TRANSMIT;
typedef struct s_pxe_cpb_transmit_fragments {
PXE_UINT32 FrameLen;
PXE_UINT16 MediaheaderLen;
PXE_UINT16 FragCnt;
struct {
PXE_UINT64 FragAddr;
PXE_UINT32 FragLen;
PXE_UINT32 reserved;
} FragDesc[16];
}
PXE_CPB_TRANSMIT_FRAGMENTS;
typedef struct s_pxe_cpb_receive {
PXE_UINT64 BufferAddr;
PXE_UINT32 BufferLen;
PXE_UINT32 reserved;
} PXE_CPB_RECEIVE;
typedef struct s_pxe_db_receive {
PXE_MAC_ADDR SrcAddr;
PXE_MAC_ADDR DestAddr;
PXE_UINT32 FrameLen;
PXE_MEDIA_PROTOCOL Protocol;
PXE_UINT16 MediaHeaderLen;
PXE_FRAME_TYPE Type;
PXE_UINT8 reserved[7];
} PXE_DB_RECEIVE;
#pragma pack()
#pragma pack(1)
typedef struct {
EFI_TABLE_HEADER Header;
EFI_LBA MyLBA;
EFI_LBA AlternateLBA;
EFI_LBA FirstUsableLBA;
EFI_LBA LastUsableLBA;
EFI_GUID DiskGUID;
EFI_LBA PartitionEntryLBA;
UINT32 NumberOfPartitionEntries;
UINT32 SizeOfPartitionEntry;
UINT32 PartitionEntryArrayCRC32;
} EFI_PARTITION_TABLE_HEADER;
typedef struct {
EFI_GUID PartitionTypeGUID;
EFI_GUID UniquePartitionGUID;
EFI_LBA StartingLBA;
EFI_LBA EndingLBA;
UINT64 Attributes;
CHAR16 PartitionName[36];
} EFI_PARTITION_ENTRY;
#pragma pack()
extern EFI_GUID gEfiHiiStandardFormGuid;
typedef void* EFI_HII_HANDLE;
typedef CHAR16* EFI_STRING;
typedef UINT16 EFI_IMAGE_ID;
typedef UINT16 EFI_QUESTION_ID;
typedef UINT16 EFI_STRING_ID;
typedef UINT16 EFI_FORM_ID;
typedef UINT16 EFI_VARSTORE_ID;
typedef UINT16 EFI_ANIMATION_ID;
typedef UINT16 EFI_DEFAULT_ID;
typedef UINT32 EFI_HII_FONT_STYLE;
#pragma pack(1)
typedef struct {
EFI_GUID PackageListGuid;
UINT32 PackageLength;
} EFI_HII_PACKAGE_LIST_HEADER;
typedef struct {
UINT32 Length:24;
UINT32 Type:8;
} EFI_HII_PACKAGE_HEADER;
typedef struct {
CHAR16 UnicodeWeight;
UINT8 Attributes;
UINT8 GlyphCol1[19];
} EFI_NARROW_GLYPH;
typedef struct {
CHAR16 UnicodeWeight;
UINT8 Attributes;
UINT8 GlyphCol1[19];
UINT8 GlyphCol2[19];
UINT8 Pad[3];
} EFI_WIDE_GLYPH;
typedef struct _EFI_HII_SIMPLE_FONT_PACKAGE_HDR {
EFI_HII_PACKAGE_HEADER Header;
UINT16 NumberOfNarrowGlyphs;
UINT16 NumberOfWideGlyphs;
} EFI_HII_SIMPLE_FONT_PACKAGE_HDR;
typedef struct _EFI_HII_GLYPH_INFO {
UINT16 Width;
UINT16 Height;
INT16 OffsetX;
INT16 OffsetY;
INT16 AdvanceX;
} EFI_HII_GLYPH_INFO;
typedef struct _EFI_HII_FONT_PACKAGE_HDR {
EFI_HII_PACKAGE_HEADER Header;
UINT32 HdrSize;
UINT32 GlyphBlockOffset;
EFI_HII_GLYPH_INFO Cell;
EFI_HII_FONT_STYLE FontStyle;
CHAR16 FontFamily[1];
} EFI_HII_FONT_PACKAGE_HDR;
typedef struct _EFI_HII_GLYPH_BLOCK {
UINT8 BlockType;
} EFI_HII_GLYPH_BLOCK;
typedef struct _EFI_HII_GIBT_DEFAULTS_BLOCK {
EFI_HII_GLYPH_BLOCK Header;
EFI_HII_GLYPH_INFO Cell;
} EFI_HII_GIBT_DEFAULTS_BLOCK;
typedef struct _EFI_HII_GIBT_DUPLICATE_BLOCK {
EFI_HII_GLYPH_BLOCK Header;
CHAR16 CharValue;
} EFI_HII_GIBT_DUPLICATE_BLOCK;
typedef struct _EFI_GLYPH_GIBT_END_BLOCK {
EFI_HII_GLYPH_BLOCK Header;
} EFI_GLYPH_GIBT_END_BLOCK;
typedef struct _EFI_HII_GIBT_EXT1_BLOCK {
EFI_HII_GLYPH_BLOCK Header;
UINT8 BlockType2;
UINT8 Length;
} EFI_HII_GIBT_EXT1_BLOCK;
typedef struct _EFI_HII_GIBT_EXT2_BLOCK {
EFI_HII_GLYPH_BLOCK Header;
UINT8 BlockType2;
UINT16 Length;
} EFI_HII_GIBT_EXT2_BLOCK;
typedef struct _EFI_HII_GIBT_EXT4_BLOCK {
EFI_HII_GLYPH_BLOCK Header;
UINT8 BlockType2;
UINT32 Length;
} EFI_HII_GIBT_EXT4_BLOCK;
typedef struct _EFI_HII_GIBT_GLYPH_BLOCK {
EFI_HII_GLYPH_BLOCK Header;
EFI_HII_GLYPH_INFO Cell;
UINT8 BitmapData[1];
} EFI_HII_GIBT_GLYPH_BLOCK;
typedef struct _EFI_HII_GIBT_GLYPHS_BLOCK {
EFI_HII_GLYPH_BLOCK Header;
EFI_HII_GLYPH_INFO Cell;
UINT16 Count;
UINT8 BitmapData[1];
} EFI_HII_GIBT_GLYPHS_BLOCK;
typedef struct _EFI_HII_GIBT_GLYPH_DEFAULT_BLOCK {
EFI_HII_GLYPH_BLOCK Header;
UINT8 BitmapData[1];
} EFI_HII_GIBT_GLYPH_DEFAULT_BLOCK;
typedef struct _EFI_HII_GIBT_GLYPHS_DEFAULT_BLOCK {
EFI_HII_GLYPH_BLOCK Header;
UINT16 Count;
UINT8 BitmapData[1];
} EFI_HII_GIBT_GLYPHS_DEFAULT_BLOCK;
typedef struct _EFI_HII_GIBT_SKIP1_BLOCK {
EFI_HII_GLYPH_BLOCK Header;
UINT8 SkipCount;
} EFI_HII_GIBT_SKIP1_BLOCK;
typedef struct _EFI_HII_GIBT_SKIP2_BLOCK {
EFI_HII_GLYPH_BLOCK Header;
UINT16 SkipCount;
} EFI_HII_GIBT_SKIP2_BLOCK;
typedef struct _EFI_HII_DEVICE_PATH_PACKAGE_HDR {
EFI_HII_PACKAGE_HEADER Header;
} EFI_HII_DEVICE_PATH_PACKAGE_HDR;
typedef struct _EFI_HII_GUID_PACKAGE_HDR {
EFI_HII_PACKAGE_HEADER Header;
EFI_GUID Guid;
} EFI_HII_GUID_PACKAGE_HDR;
typedef struct _EFI_HII_STRING_PACKAGE_HDR {
EFI_HII_PACKAGE_HEADER Header;
UINT32 HdrSize;
UINT32 StringInfoOffset;
CHAR16 LanguageWindow[16];
EFI_STRING_ID LanguageName;
CHAR8 Language[1];
} EFI_HII_STRING_PACKAGE_HDR;
typedef struct {
UINT8 BlockType;
} EFI_HII_STRING_BLOCK;
typedef struct _EFI_HII_SIBT_DUPLICATE_BLOCK {
EFI_HII_STRING_BLOCK Header;
EFI_STRING_ID StringId;
} EFI_HII_SIBT_DUPLICATE_BLOCK;
typedef struct _EFI_HII_SIBT_END_BLOCK {
EFI_HII_STRING_BLOCK Header;
} EFI_HII_SIBT_END_BLOCK;
typedef struct _EFI_HII_SIBT_EXT1_BLOCK {
EFI_HII_STRING_BLOCK Header;
UINT8 BlockType2;
UINT8 Length;
} EFI_HII_SIBT_EXT1_BLOCK;
typedef struct _EFI_HII_SIBT_EXT2_BLOCK {
EFI_HII_STRING_BLOCK Header;
UINT8 BlockType2;
UINT16 Length;
} EFI_HII_SIBT_EXT2_BLOCK;
typedef struct _EFI_HII_SIBT_EXT4_BLOCK {
EFI_HII_STRING_BLOCK Header;
UINT8 BlockType2;
UINT32 Length;
} EFI_HII_SIBT_EXT4_BLOCK;
typedef struct _EFI_HII_SIBT_FONT_BLOCK {
EFI_HII_SIBT_EXT2_BLOCK Header;
UINT8 FontId;
UINT16 FontSize;
EFI_HII_FONT_STYLE FontStyle;
CHAR16 FontName[1];
} EFI_HII_SIBT_FONT_BLOCK;
typedef struct _EFI_HII_SIBT_SKIP1_BLOCK {
EFI_HII_STRING_BLOCK Header;
UINT8 SkipCount;
} EFI_HII_SIBT_SKIP1_BLOCK;
typedef struct _EFI_HII_SIBT_SKIP2_BLOCK {
EFI_HII_STRING_BLOCK Header;
UINT16 SkipCount;
} EFI_HII_SIBT_SKIP2_BLOCK;
typedef struct _EFI_HII_SIBT_STRING_SCSU_BLOCK {
EFI_HII_STRING_BLOCK Header;
UINT8 StringText[1];
} EFI_HII_SIBT_STRING_SCSU_BLOCK;
typedef struct _EFI_HII_SIBT_STRING_SCSU_FONT_BLOCK {
EFI_HII_STRING_BLOCK Header;
UINT8 FontIdentifier;
UINT8 StringText[1];
} EFI_HII_SIBT_STRING_SCSU_FONT_BLOCK;
typedef struct _EFI_HII_SIBT_STRINGS_SCSU_BLOCK {
EFI_HII_STRING_BLOCK Header;
UINT16 StringCount;
UINT8 StringText[1];
} EFI_HII_SIBT_STRINGS_SCSU_BLOCK;
typedef struct _EFI_HII_SIBT_STRINGS_SCSU_FONT_BLOCK {
EFI_HII_STRING_BLOCK Header;
UINT8 FontIdentifier;
UINT16 StringCount;
UINT8 StringText[1];
} EFI_HII_SIBT_STRINGS_SCSU_FONT_BLOCK;
typedef struct _EFI_HII_SIBT_STRING_UCS2_BLOCK {
EFI_HII_STRING_BLOCK Header;
CHAR16 StringText[1];
} EFI_HII_SIBT_STRING_UCS2_BLOCK;
typedef struct _EFI_HII_SIBT_STRING_UCS2_FONT_BLOCK {
EFI_HII_STRING_BLOCK Header;
UINT8 FontIdentifier;
CHAR16 StringText[1];
} EFI_HII_SIBT_STRING_UCS2_FONT_BLOCK;
typedef struct _EFI_HII_SIBT_STRINGS_UCS2_BLOCK {
EFI_HII_STRING_BLOCK Header;
UINT16 StringCount;
CHAR16 StringText[1];
} EFI_HII_SIBT_STRINGS_UCS2_BLOCK;
typedef struct _EFI_HII_SIBT_STRINGS_UCS2_FONT_BLOCK {
EFI_HII_STRING_BLOCK Header;
UINT8 FontIdentifier;
UINT16 StringCount;
CHAR16 StringText[1];
} EFI_HII_SIBT_STRINGS_UCS2_FONT_BLOCK;
typedef struct _EFI_HII_IMAGE_PACKAGE_HDR {
EFI_HII_PACKAGE_HEADER Header;
UINT32 ImageInfoOffset;
UINT32 PaletteInfoOffset;
} EFI_HII_IMAGE_PACKAGE_HDR;
typedef struct _EFI_HII_IMAGE_BLOCK {
UINT8 BlockType;
} EFI_HII_IMAGE_BLOCK;
typedef struct _EFI_HII_IIBT_END_BLOCK {
EFI_HII_IMAGE_BLOCK Header;
} EFI_HII_IIBT_END_BLOCK;
typedef struct _EFI_HII_IIBT_EXT1_BLOCK {
EFI_HII_IMAGE_BLOCK Header;
UINT8 BlockType2;
UINT8 Length;
} EFI_HII_IIBT_EXT1_BLOCK;
typedef struct _EFI_HII_IIBT_EXT2_BLOCK {
EFI_HII_IMAGE_BLOCK Header;
UINT8 BlockType2;
UINT16 Length;
} EFI_HII_IIBT_EXT2_BLOCK;
typedef struct _EFI_HII_IIBT_EXT4_BLOCK {
EFI_HII_IMAGE_BLOCK Header;
UINT8 BlockType2;
UINT32 Length;
} EFI_HII_IIBT_EXT4_BLOCK;
typedef struct _EFI_HII_IIBT_IMAGE_1BIT_BASE {
UINT16 Width;
UINT16 Height;
UINT8 Data[1];
} EFI_HII_IIBT_IMAGE_1BIT_BASE;
typedef struct _EFI_HII_IIBT_IMAGE_1BIT_BLOCK {
EFI_HII_IMAGE_BLOCK Header;
UINT8 PaletteIndex;
EFI_HII_IIBT_IMAGE_1BIT_BASE Bitmap;
} EFI_HII_IIBT_IMAGE_1BIT_BLOCK;
typedef struct _EFI_HII_IIBT_IMAGE_1BIT_TRANS_BLOCK {
EFI_HII_IMAGE_BLOCK Header;
UINT8 PaletteIndex;
EFI_HII_IIBT_IMAGE_1BIT_BASE Bitmap;
} EFI_HII_IIBT_IMAGE_1BIT_TRANS_BLOCK;
typedef struct _EFI_HII_RGB_PIXEL {
UINT8 b;
UINT8 g;
UINT8 r;
} EFI_HII_RGB_PIXEL;
typedef struct _EFI_HII_IIBT_IMAGE_24BIT_BASE {
UINT16 Width;
UINT16 Height;
EFI_HII_RGB_PIXEL Bitmap[1];
} EFI_HII_IIBT_IMAGE_24BIT_BASE;
typedef struct _EFI_HII_IIBT_IMAGE_24BIT_BLOCK {
EFI_HII_IMAGE_BLOCK Header;
EFI_HII_IIBT_IMAGE_24BIT_BASE Bitmap;
} EFI_HII_IIBT_IMAGE_24BIT_BLOCK;
typedef struct _EFI_HII_IIBT_IMAGE_24BIT_TRANS_BLOCK {
EFI_HII_IMAGE_BLOCK Header;
EFI_HII_IIBT_IMAGE_24BIT_BASE Bitmap;
} EFI_HII_IIBT_IMAGE_24BIT_TRANS_BLOCK;
typedef struct _EFI_HII_IIBT_IMAGE_4BIT_BASE {
UINT16 Width;
UINT16 Height;
UINT8 Data[1];
} EFI_HII_IIBT_IMAGE_4BIT_BASE;
typedef struct _EFI_HII_IIBT_IMAGE_4BIT_BLOCK {
EFI_HII_IMAGE_BLOCK Header;
UINT8 PaletteIndex;
EFI_HII_IIBT_IMAGE_4BIT_BASE Bitmap;
} EFI_HII_IIBT_IMAGE_4BIT_BLOCK;
typedef struct _EFI_HII_IIBT_IMAGE_4BIT_TRANS_BLOCK {
EFI_HII_IMAGE_BLOCK Header;
UINT8 PaletteIndex;
EFI_HII_IIBT_IMAGE_4BIT_BASE Bitmap;
} EFI_HII_IIBT_IMAGE_4BIT_TRANS_BLOCK;
typedef struct _EFI_HII_IIBT_IMAGE_8BIT_BASE {
UINT16 Width;
UINT16 Height;
UINT8 Data[1];
} EFI_HII_IIBT_IMAGE_8BIT_BASE;
typedef struct _EFI_HII_IIBT_IMAGE_8BIT_PALETTE_BLOCK {
EFI_HII_IMAGE_BLOCK Header;
UINT8 PaletteIndex;
EFI_HII_IIBT_IMAGE_8BIT_BASE Bitmap;
} EFI_HII_IIBT_IMAGE_8BIT_BLOCK;
typedef struct _EFI_HII_IIBT_IMAGE_8BIT_TRANS_BLOCK {
EFI_HII_IMAGE_BLOCK Header;
UINT8 PaletteIndex;
EFI_HII_IIBT_IMAGE_8BIT_BASE Bitmap;
} EFI_HII_IIBT_IMAGE_8BIT_TRAN_BLOCK;
typedef struct _EFI_HII_IIBT_DUPLICATE_BLOCK {
EFI_HII_IMAGE_BLOCK Header;
EFI_IMAGE_ID ImageId;
} EFI_HII_IIBT_DUPLICATE_BLOCK;
typedef struct _EFI_HII_IIBT_JPEG_BLOCK {
EFI_HII_IMAGE_BLOCK Header;
UINT32 Size;
UINT8 Data[1];
} EFI_HII_IIBT_JPEG_BLOCK;
typedef struct _EFI_HII_IIBT_SKIP1_BLOCK {
EFI_HII_IMAGE_BLOCK Header;
UINT8 SkipCount;
} EFI_HII_IIBT_SKIP1_BLOCK;
typedef struct _EFI_HII_IIBT_SKIP2_BLOCK {
EFI_HII_IMAGE_BLOCK Header;
UINT16 SkipCount;
} EFI_HII_IIBT_SKIP2_BLOCK;
typedef struct _EFI_HII_IMAGE_PALETTE_INFO_HEADER {
UINT16 PaletteCount;
} EFI_HII_IMAGE_PALETTE_INFO_HEADER;
typedef struct _EFI_HII_IMAGE_PALETTE_INFO {
UINT16 PaletteSize;
EFI_HII_RGB_PIXEL PaletteValue[1];
} EFI_HII_IMAGE_PALETTE_INFO;
typedef struct _EFI_HII_FORM_PACKAGE_HDR {
EFI_HII_PACKAGE_HEADER Header;
} EFI_HII_FORM_PACKAGE_HDR;
typedef struct {
UINT8 Hour;
UINT8 Minute;
UINT8 Second;
} EFI_HII_TIME;
typedef struct {
UINT16 Year;
UINT8 Month;
UINT8 Day;
} EFI_HII_DATE;
typedef struct {
EFI_QUESTION_ID QuestionId;
EFI_FORM_ID FormId;
EFI_GUID FormSetGuid;
EFI_STRING_ID DevicePath;
} EFI_HII_REF;
typedef union {
UINT8 u8;
UINT16 u16;
UINT32 u32;
UINT64 u64;
BOOLEAN b;
EFI_HII_TIME time;
EFI_HII_DATE date;
EFI_STRING_ID string;
EFI_HII_REF ref;
} EFI_IFR_TYPE_VALUE;
typedef struct _EFI_IFR_OP_HEADER {
UINT8 OpCode;
UINT8 Length:7;
UINT8 Scope:1;
} EFI_IFR_OP_HEADER;
typedef struct _EFI_IFR_STATEMENT_HEADER {
EFI_STRING_ID Prompt;
EFI_STRING_ID Help;
} EFI_IFR_STATEMENT_HEADER;
typedef struct _EFI_IFR_QUESTION_HEADER {
EFI_IFR_STATEMENT_HEADER Header;
EFI_QUESTION_ID QuestionId;
EFI_VARSTORE_ID VarStoreId;
union {
EFI_STRING_ID VarName;
UINT16 VarOffset;
} VarStoreInfo;
UINT8 Flags;
} EFI_IFR_QUESTION_HEADER;
typedef struct _EFI_IFR_DEFAULTSTORE {
EFI_IFR_OP_HEADER Header;
EFI_STRING_ID DefaultName;
UINT16 DefaultId;
} EFI_IFR_DEFAULTSTORE;
typedef struct _EFI_IFR_VARSTORE {
EFI_IFR_OP_HEADER Header;
EFI_GUID Guid;
EFI_VARSTORE_ID VarStoreId;
UINT16 Size;
UINT8 Name[1];
} EFI_IFR_VARSTORE;
typedef struct _EFI_IFR_VARSTORE_EFI {
EFI_IFR_OP_HEADER Header;
EFI_VARSTORE_ID VarStoreId;
EFI_GUID Guid;
UINT32 Attributes;
UINT16 Size;
UINT8 Name[1];
} EFI_IFR_VARSTORE_EFI;
typedef struct _EFI_IFR_VARSTORE_NAME_VALUE {
EFI_IFR_OP_HEADER Header;
EFI_VARSTORE_ID VarStoreId;
EFI_GUID Guid;
} EFI_IFR_VARSTORE_NAME_VALUE;
typedef struct _EFI_IFR_FORM_SET {
EFI_IFR_OP_HEADER Header;
EFI_GUID Guid;
EFI_STRING_ID FormSetTitle;
EFI_STRING_ID Help;
UINT8 Flags;
} EFI_IFR_FORM_SET;
typedef struct _EFI_IFR_END {
EFI_IFR_OP_HEADER Header;
} EFI_IFR_END;
typedef struct _EFI_IFR_FORM {
EFI_IFR_OP_HEADER Header;
UINT16 FormId;
EFI_STRING_ID FormTitle;
} EFI_IFR_FORM;
typedef struct _EFI_IFR_IMAGE {
EFI_IFR_OP_HEADER Header;
EFI_IMAGE_ID Id;
} EFI_IFR_IMAGE;
typedef struct _EFI_IFR_MODAL {
EFI_IFR_OP_HEADER Header;
} EFI_IFR_MODAL;
typedef struct _EFI_IFR_LOCKED {
EFI_IFR_OP_HEADER Header;
} EFI_IFR_LOCKED;
typedef struct _EFI_IFR_RULE {
EFI_IFR_OP_HEADER Header;
UINT8 RuleId;
} EFI_IFR_RULE;
typedef struct _EFI_IFR_DEFAULT {
EFI_IFR_OP_HEADER Header;
UINT16 DefaultId;
UINT8 Type;
EFI_IFR_TYPE_VALUE Value;
} EFI_IFR_DEFAULT;
typedef struct _EFI_IFR_VALUE {
EFI_IFR_OP_HEADER Header;
} EFI_IFR_VALUE;
typedef struct _EFI_IFR_SUBTITLE {
EFI_IFR_OP_HEADER Header;
EFI_IFR_STATEMENT_HEADER Statement;
UINT8 Flags;
} EFI_IFR_SUBTITLE;
typedef struct _EFI_IFR_CHECKBOX {
EFI_IFR_OP_HEADER Header;
EFI_IFR_QUESTION_HEADER Question;
UINT8 Flags;
} EFI_IFR_CHECKBOX;
typedef struct _EFI_IFR_TEXT {
EFI_IFR_OP_HEADER Header;
EFI_IFR_STATEMENT_HEADER Statement;
EFI_STRING_ID TextTwo;
} EFI_IFR_TEXT;
typedef struct _EFI_IFR_REF {
EFI_IFR_OP_HEADER Header;
EFI_IFR_QUESTION_HEADER Question;
EFI_FORM_ID FormId;
} EFI_IFR_REF;
typedef struct _EFI_IFR_REF2 {
EFI_IFR_OP_HEADER Header;
EFI_IFR_QUESTION_HEADER Question;
EFI_FORM_ID FormId;
EFI_QUESTION_ID QuestionId;
} EFI_IFR_REF2;
typedef struct _EFI_IFR_REF3 {
EFI_IFR_OP_HEADER Header;
EFI_IFR_QUESTION_HEADER Question;
EFI_FORM_ID FormId;
EFI_QUESTION_ID QuestionId;
EFI_GUID FormSetId;
} EFI_IFR_REF3;
typedef struct _EFI_IFR_REF4 {
EFI_IFR_OP_HEADER Header;
EFI_IFR_QUESTION_HEADER Question;
EFI_FORM_ID FormId;
EFI_QUESTION_ID QuestionId;
EFI_GUID FormSetId;
EFI_STRING_ID DevicePath;
} EFI_IFR_REF4;
typedef struct _EFI_IFR_REF5 {
EFI_IFR_OP_HEADER Header;
EFI_IFR_QUESTION_HEADER Question;
} EFI_IFR_REF5;
typedef struct _EFI_IFR_RESET_BUTTON {
EFI_IFR_OP_HEADER Header;
EFI_IFR_STATEMENT_HEADER Statement;
EFI_DEFAULT_ID DefaultId;
} EFI_IFR_RESET_BUTTON;
typedef struct _EFI_IFR_ACTION {
EFI_IFR_OP_HEADER Header;
EFI_IFR_QUESTION_HEADER Question;
EFI_STRING_ID QuestionConfig;
} EFI_IFR_ACTION;
typedef struct _EFI_IFR_ACTION_1 {
EFI_IFR_OP_HEADER Header;
EFI_IFR_QUESTION_HEADER Question;
} EFI_IFR_ACTION_1;
typedef struct _EFI_IFR_DATE {
EFI_IFR_OP_HEADER Header;
EFI_IFR_QUESTION_HEADER Question;
UINT8 Flags;
} EFI_IFR_DATE;
typedef union {
struct {
UINT8 MinValue;
UINT8 MaxValue;
UINT8 Step;
} u8;
struct {
UINT16 MinValue;
UINT16 MaxValue;
UINT16 Step;
} u16;
struct {
UINT32 MinValue;
UINT32 MaxValue;
UINT32 Step;
} u32;
struct {
UINT64 MinValue;
UINT64 MaxValue;
UINT64 Step;
} u64;
} MINMAXSTEP_DATA;
typedef struct _EFI_IFR_NUMERIC {
EFI_IFR_OP_HEADER Header;
EFI_IFR_QUESTION_HEADER Question;
UINT8 Flags;
MINMAXSTEP_DATA data;
} EFI_IFR_NUMERIC;
typedef struct _EFI_IFR_ONE_OF {
EFI_IFR_OP_HEADER Header;
EFI_IFR_QUESTION_HEADER Question;
UINT8 Flags;
MINMAXSTEP_DATA data;
} EFI_IFR_ONE_OF;
typedef struct _EFI_IFR_STRING {
EFI_IFR_OP_HEADER Header;
EFI_IFR_QUESTION_HEADER Question;
UINT8 MinSize;
UINT8 MaxSize;
UINT8 Flags;
} EFI_IFR_STRING;
typedef struct _EFI_IFR_PASSWORD {
EFI_IFR_OP_HEADER Header;
EFI_IFR_QUESTION_HEADER Question;
UINT16 MinSize;
UINT16 MaxSize;
} EFI_IFR_PASSWORD;
typedef struct _EFI_IFR_ORDERED_LIST {
EFI_IFR_OP_HEADER Header;
EFI_IFR_QUESTION_HEADER Question;
UINT8 MaxContainers;
UINT8 Flags;
} EFI_IFR_ORDERED_LIST;
typedef struct _EFI_IFR_TIME {
EFI_IFR_OP_HEADER Header;
EFI_IFR_QUESTION_HEADER Question;
UINT8 Flags;
} EFI_IFR_TIME;
typedef struct _EFI_IFR_DISABLE_IF {
EFI_IFR_OP_HEADER Header;
} EFI_IFR_DISABLE_IF;
typedef struct _EFI_IFR_SUPPRESS_IF {
EFI_IFR_OP_HEADER Header;
} EFI_IFR_SUPPRESS_IF;
typedef struct _EFI_IFR_GRAY_OUT_IF {
EFI_IFR_OP_HEADER Header;
} EFI_IFR_GRAY_OUT_IF;
typedef struct _EFI_IFR_INCONSISTENT_IF {
EFI_IFR_OP_HEADER Header;
EFI_STRING_ID Error;
} EFI_IFR_INCONSISTENT_IF;
typedef struct _EFI_IFR_NO_SUBMIT_IF {
EFI_IFR_OP_HEADER Header;
EFI_STRING_ID Error;
} EFI_IFR_NO_SUBMIT_IF;
typedef struct _EFI_IFR_REFRESH {
EFI_IFR_OP_HEADER Header;
UINT8 RefreshInterval;
} EFI_IFR_REFRESH;
typedef struct _EFI_IFR_VARSTORE_DEVICE {
EFI_IFR_OP_HEADER Header;
EFI_STRING_ID DevicePath;
} EFI_IFR_VARSTORE_DEVICE;
typedef struct _EFI_IFR_ONE_OF_OPTION {
EFI_IFR_OP_HEADER Header;
EFI_STRING_ID Option;
UINT8 Flags;
UINT8 Type;
EFI_IFR_TYPE_VALUE Value;
} EFI_IFR_ONE_OF_OPTION;
typedef struct _EFI_IFR_GUID {
EFI_IFR_OP_HEADER Header;
EFI_GUID Guid;
} EFI_IFR_GUID;
typedef struct _EFI_IFR_REFRESH_ID {
EFI_IFR_OP_HEADER Header;
EFI_GUID RefreshEventGroupId;
} EFI_IFR_REFRESH_ID;
typedef struct _EFI_IFR_DUP {
EFI_IFR_OP_HEADER Header;
} EFI_IFR_DUP;
typedef struct _EFI_IFR_EQ_ID_ID {
EFI_IFR_OP_HEADER Header;
EFI_QUESTION_ID QuestionId1;
EFI_QUESTION_ID QuestionId2;
} EFI_IFR_EQ_ID_ID;
typedef struct _EFI_IFR_EQ_ID_VAL {
EFI_IFR_OP_HEADER Header;
EFI_QUESTION_ID QuestionId;
UINT16 Value;
} EFI_IFR_EQ_ID_VAL;
typedef struct _EFI_IFR_EQ_ID_VAL_LIST {
EFI_IFR_OP_HEADER Header;
EFI_QUESTION_ID QuestionId;
UINT16 ListLength;
UINT16 ValueList[1];
} EFI_IFR_EQ_ID_VAL_LIST;
typedef struct _EFI_IFR_UINT8 {
EFI_IFR_OP_HEADER Header;
UINT8 Value;
} EFI_IFR_UINT8;
typedef struct _EFI_IFR_UINT16 {
EFI_IFR_OP_HEADER Header;
UINT16 Value;
} EFI_IFR_UINT16;
typedef struct _EFI_IFR_UINT32 {
EFI_IFR_OP_HEADER Header;
UINT32 Value;
} EFI_IFR_UINT32;
typedef struct _EFI_IFR_UINT64 {
EFI_IFR_OP_HEADER Header;
UINT64 Value;
} EFI_IFR_UINT64;
typedef struct _EFI_IFR_QUESTION_REF1 {
EFI_IFR_OP_HEADER Header;
EFI_QUESTION_ID QuestionId;
} EFI_IFR_QUESTION_REF1;
typedef struct _EFI_IFR_QUESTION_REF2 {
EFI_IFR_OP_HEADER Header;
} EFI_IFR_QUESTION_REF2;
typedef struct _EFI_IFR_QUESTION_REF3 {
EFI_IFR_OP_HEADER Header;
} EFI_IFR_QUESTION_REF3;
typedef struct _EFI_IFR_QUESTION_REF3_2 {
EFI_IFR_OP_HEADER Header;
EFI_STRING_ID DevicePath;
} EFI_IFR_QUESTION_REF3_2;
typedef struct _EFI_IFR_QUESTION_REF3_3 {
EFI_IFR_OP_HEADER Header;
EFI_STRING_ID DevicePath;
EFI_GUID Guid;
} EFI_IFR_QUESTION_REF3_3;
typedef struct _EFI_IFR_RULE_REF {
EFI_IFR_OP_HEADER Header;
UINT8 RuleId;
} EFI_IFR_RULE_REF;
typedef struct _EFI_IFR_STRING_REF1 {
EFI_IFR_OP_HEADER Header;
EFI_STRING_ID StringId;
} EFI_IFR_STRING_REF1;
typedef struct _EFI_IFR_STRING_REF2 {
EFI_IFR_OP_HEADER Header;
} EFI_IFR_STRING_REF2;
typedef struct _EFI_IFR_THIS {
EFI_IFR_OP_HEADER Header;
} EFI_IFR_THIS;
typedef struct _EFI_IFR_TRUE {
EFI_IFR_OP_HEADER Header;
} EFI_IFR_TRUE;
typedef struct _EFI_IFR_FALSE {
EFI_IFR_OP_HEADER Header;
} EFI_IFR_FALSE;
typedef struct _EFI_IFR_ONE {
EFI_IFR_OP_HEADER Header;
} EFI_IFR_ONE;
typedef struct _EFI_IFR_ONES {
EFI_IFR_OP_HEADER Header;
} EFI_IFR_ONES;
typedef struct _EFI_IFR_ZERO {
EFI_IFR_OP_HEADER Header;
} EFI_IFR_ZERO;
typedef struct _EFI_IFR_UNDEFINED {
EFI_IFR_OP_HEADER Header;
} EFI_IFR_UNDEFINED;
typedef struct _EFI_IFR_VERSION {
EFI_IFR_OP_HEADER Header;
} EFI_IFR_VERSION;
typedef struct _EFI_IFR_LENGTH {
EFI_IFR_OP_HEADER Header;
} EFI_IFR_LENGTH;
typedef struct _EFI_IFR_NOT {
EFI_IFR_OP_HEADER Header;
} EFI_IFR_NOT;
typedef struct _EFI_IFR_BITWISE_NOT {
EFI_IFR_OP_HEADER Header;
} EFI_IFR_BITWISE_NOT;
typedef struct _EFI_IFR_TO_BOOLEAN {
EFI_IFR_OP_HEADER Header;
} EFI_IFR_TO_BOOLEAN;
typedef struct _EFI_IFR_TO_STRING {
EFI_IFR_OP_HEADER Header;
UINT8 Format;
} EFI_IFR_TO_STRING;
typedef struct _EFI_IFR_TO_UINT {
EFI_IFR_OP_HEADER Header;
} EFI_IFR_TO_UINT;
typedef struct _EFI_IFR_TO_UPPER {
EFI_IFR_OP_HEADER Header;
} EFI_IFR_TO_UPPER;
typedef struct _EFI_IFR_TO_LOWER {
EFI_IFR_OP_HEADER Header;
} EFI_IFR_TO_LOWER;
typedef struct _EFI_IFR_ADD {
EFI_IFR_OP_HEADER Header;
} EFI_IFR_ADD;
typedef struct _EFI_IFR_AND {
EFI_IFR_OP_HEADER Header;
} EFI_IFR_AND;
typedef struct _EFI_IFR_BITWISE_AND {
EFI_IFR_OP_HEADER Header;
} EFI_IFR_BITWISE_AND;
typedef struct _EFI_IFR_BITWISE_OR {
EFI_IFR_OP_HEADER Header;
} EFI_IFR_BITWISE_OR;
typedef struct _EFI_IFR_CATENATE {
EFI_IFR_OP_HEADER Header;
} EFI_IFR_CATENATE;
typedef struct _EFI_IFR_DIVIDE {
EFI_IFR_OP_HEADER Header;
} EFI_IFR_DIVIDE;
typedef struct _EFI_IFR_EQUAL {
EFI_IFR_OP_HEADER Header;
} EFI_IFR_EQUAL;
typedef struct _EFI_IFR_GREATER_EQUAL {
EFI_IFR_OP_HEADER Header;
} EFI_IFR_GREATER_EQUAL;
typedef struct _EFI_IFR_GREATER_THAN {
EFI_IFR_OP_HEADER Header;
} EFI_IFR_GREATER_THAN;
typedef struct _EFI_IFR_LESS_EQUAL {
EFI_IFR_OP_HEADER Header;
} EFI_IFR_LESS_EQUAL;
typedef struct _EFI_IFR_LESS_THAN {
EFI_IFR_OP_HEADER Header;
} EFI_IFR_LESS_THAN;
typedef struct _EFI_IFR_MATCH {
EFI_IFR_OP_HEADER Header;
} EFI_IFR_MATCH;
typedef struct _EFI_IFR_MULTIPLY {
EFI_IFR_OP_HEADER Header;
} EFI_IFR_MULTIPLY;
typedef struct _EFI_IFR_MODULO {
EFI_IFR_OP_HEADER Header;
} EFI_IFR_MODULO;
typedef struct _EFI_IFR_NOT_EQUAL {
EFI_IFR_OP_HEADER Header;
} EFI_IFR_NOT_EQUAL;
typedef struct _EFI_IFR_OR {
EFI_IFR_OP_HEADER Header;
} EFI_IFR_OR;
typedef struct _EFI_IFR_SHIFT_LEFT {
EFI_IFR_OP_HEADER Header;
} EFI_IFR_SHIFT_LEFT;
typedef struct _EFI_IFR_SHIFT_RIGHT {
EFI_IFR_OP_HEADER Header;
} EFI_IFR_SHIFT_RIGHT;
typedef struct _EFI_IFR_SUBTRACT {
EFI_IFR_OP_HEADER Header;
} EFI_IFR_SUBTRACT;
typedef struct _EFI_IFR_CONDITIONAL {
EFI_IFR_OP_HEADER Header;
} EFI_IFR_CONDITIONAL;
typedef struct _EFI_IFR_FIND {
EFI_IFR_OP_HEADER Header;
UINT8 Format;
} EFI_IFR_FIND;
typedef struct _EFI_IFR_MID {
EFI_IFR_OP_HEADER Header;
} EFI_IFR_MID;
typedef struct _EFI_IFR_TOKEN {
EFI_IFR_OP_HEADER Header;
} EFI_IFR_TOKEN;
typedef struct _EFI_IFR_SPAN {
EFI_IFR_OP_HEADER Header;
UINT8 Flags;
} EFI_IFR_SPAN;
typedef struct _EFI_IFR_SECURITY {
EFI_IFR_OP_HEADER Header;
EFI_GUID Permissions;
} EFI_IFR_SECURITY;
typedef struct _EFI_IFR_FORM_MAP_METHOD {
EFI_STRING_ID MethodTitle;
EFI_GUID MethodIdentifier;
} EFI_IFR_FORM_MAP_METHOD;
typedef struct _EFI_IFR_FORM_MAP {
EFI_IFR_OP_HEADER Header;
EFI_FORM_ID FormId;
} EFI_IFR_FORM_MAP;
typedef struct _EFI_IFR_SET {
EFI_IFR_OP_HEADER Header;
EFI_VARSTORE_ID VarStoreId;
union {
EFI_STRING_ID VarName;
UINT16 VarOffset;
} VarStoreInfo;
UINT8 VarStoreType;
} EFI_IFR_SET;
typedef struct _EFI_IFR_GET {
EFI_IFR_OP_HEADER Header;
EFI_VARSTORE_ID VarStoreId;
union {
EFI_STRING_ID VarName;
UINT16 VarOffset;
} VarStoreInfo;
UINT8 VarStoreType;
} EFI_IFR_GET;
typedef struct _EFI_IFR_READ {
EFI_IFR_OP_HEADER Header;
} EFI_IFR_READ;
typedef struct _EFI_IFR_WRITE {
EFI_IFR_OP_HEADER Header;
} EFI_IFR_WRITE;
typedef struct _EFI_IFR_MAP {
EFI_IFR_OP_HEADER Header;
} EFI_IFR_MAP;
typedef enum {
EfiKeyLCtrl,
EfiKeyA0,
EfiKeyLAlt,
EfiKeySpaceBar,
EfiKeyA2,
EfiKeyA3,
EfiKeyA4,
EfiKeyRCtrl,
EfiKeyLeftArrow,
EfiKeyDownArrow,
EfiKeyRightArrow,
EfiKeyZero,
EfiKeyPeriod,
EfiKeyEnter,
EfiKeyLShift,
EfiKeyB0,
EfiKeyB1,
EfiKeyB2,
EfiKeyB3,
EfiKeyB4,
EfiKeyB5,
EfiKeyB6,
EfiKeyB7,
EfiKeyB8,
EfiKeyB9,
EfiKeyB10,
EfiKeyRShift,
EfiKeyUpArrow,
EfiKeyOne,
EfiKeyTwo,
EfiKeyThree,
EfiKeyCapsLock,
EfiKeyC1,
EfiKeyC2,
EfiKeyC3,
EfiKeyC4,
EfiKeyC5,
EfiKeyC6,
EfiKeyC7,
EfiKeyC8,
EfiKeyC9,
EfiKeyC10,
EfiKeyC11,
EfiKeyC12,
EfiKeyFour,
EfiKeyFive,
EfiKeySix,
EfiKeyPlus,
EfiKeyTab,
EfiKeyD1,
EfiKeyD2,
EfiKeyD3,
EfiKeyD4,
EfiKeyD5,
EfiKeyD6,
EfiKeyD7,
EfiKeyD8,
EfiKeyD9,
EfiKeyD10,
EfiKeyD11,
EfiKeyD12,
EfiKeyD13,
EfiKeyDel,
EfiKeyEnd,
EfiKeyPgDn,
EfiKeySeven,
EfiKeyEight,
EfiKeyNine,
EfiKeyE0,
EfiKeyE1,
EfiKeyE2,
EfiKeyE3,
EfiKeyE4,
EfiKeyE5,
EfiKeyE6,
EfiKeyE7,
EfiKeyE8,
EfiKeyE9,
EfiKeyE10,
EfiKeyE11,
EfiKeyE12,
EfiKeyBackSpace,
EfiKeyIns,
EfiKeyHome,
EfiKeyPgUp,
EfiKeyNLck,
EfiKeySlash,
EfiKeyAsterisk,
EfiKeyMinus,
EfiKeyEsc,
EfiKeyF1,
EfiKeyF2,
EfiKeyF3,
EfiKeyF4,
EfiKeyF5,
EfiKeyF6,
EfiKeyF7,
EfiKeyF8,
EfiKeyF9,
EfiKeyF10,
EfiKeyF11,
EfiKeyF12,
EfiKeyPrint,
EfiKeySLck,
EfiKeyPause
} EFI_KEY;
typedef struct {
EFI_KEY Key;
CHAR16 Unicode;
CHAR16 ShiftedUnicode;
CHAR16 AltGrUnicode;
CHAR16 ShiftedAltGrUnicode;
UINT16 Modifier;
UINT16 AffectedAttribute;
} EFI_KEY_DESCRIPTOR;
typedef struct {
UINT16 LayoutLength;
EFI_GUID Guid;
UINT32 LayoutDescriptorStringOffset;
UINT8 DescriptorCount;
} EFI_HII_KEYBOARD_LAYOUT;
typedef struct {
EFI_HII_PACKAGE_HEADER Header;
UINT16 LayoutCount;
} EFI_HII_KEYBOARD_PACKAGE_HDR;
typedef struct _EFI_IFR_ANIMATION {
EFI_IFR_OP_HEADER Header;
EFI_ANIMATION_ID Id;
} EFI_IFR_ANIMATION;
typedef struct _EFI_HII_ANIMATION_PACKAGE_HDR {
EFI_HII_PACKAGE_HEADER Header;
UINT32 AnimationInfoOffset;
} EFI_HII_ANIMATION_PACKAGE_HDR;
typedef struct _EFI_HII_ANIMATION_BLOCK {
UINT8 BlockType;
} EFI_HII_ANIMATION_BLOCK;
typedef struct _EFI_HII_AIBT_EXT1_BLOCK {
EFI_HII_ANIMATION_BLOCK Header;
UINT8 BlockType2;
UINT8 Length;
} EFI_HII_AIBT_EXT1_BLOCK;
typedef struct _EFI_HII_AIBT_EXT2_BLOCK {
EFI_HII_ANIMATION_BLOCK Header;
UINT8 BlockType2;
UINT16 Length;
} EFI_HII_AIBT_EXT2_BLOCK;
typedef struct _EFI_HII_AIBT_EXT4_BLOCK {
EFI_HII_ANIMATION_BLOCK Header;
UINT8 BlockType2;
UINT32 Length;
} EFI_HII_AIBT_EXT4_BLOCK;
typedef struct _EFI_HII_ANIMATION_CELL {
UINT16 OffsetX;
UINT16 OffsetY;
EFI_IMAGE_ID ImageId;
UINT16 Delay;
} EFI_HII_ANIMATION_CELL;
typedef struct _EFI_HII_AIBT_OVERLAY_IMAGES_BLOCK {
EFI_IMAGE_ID DftImageId;
UINT16 Width;
UINT16 Height;
UINT16 CellCount;
EFI_HII_ANIMATION_CELL AnimationCell[1];
} EFI_HII_AIBT_OVERLAY_IMAGES_BLOCK;
typedef struct _EFI_HII_AIBT_CLEAR_IMAGES_BLOCK {
EFI_IMAGE_ID DftImageId;
UINT16 Width;
UINT16 Height;
UINT16 CellCount;
EFI_HII_RGB_PIXEL BackgndColor;
EFI_HII_ANIMATION_CELL AnimationCell[1];
} EFI_HII_AIBT_CLEAR_IMAGES_BLOCK;
typedef struct _EFI_HII_AIBT_RESTORE_SCRN_BLOCK {
EFI_IMAGE_ID DftImageId;
UINT16 Width;
UINT16 Height;
UINT16 CellCount;
EFI_HII_ANIMATION_CELL AnimationCell[1];
} EFI_HII_AIBT_RESTORE_SCRN_BLOCK;
typedef EFI_HII_AIBT_OVERLAY_IMAGES_BLOCK EFI_HII_AIBT_OVERLAY_IMAGES_LOOP_BLOCK;
typedef EFI_HII_AIBT_CLEAR_IMAGES_BLOCK EFI_HII_AIBT_CLEAR_IMAGES_LOOP_BLOCK;
typedef EFI_HII_AIBT_RESTORE_SCRN_BLOCK EFI_HII_AIBT_RESTORE_SCRN_LOOP_BLOCK;
typedef struct _EFI_HII_AIBT_DUPLICATE_BLOCK {
EFI_ANIMATION_ID AnimationId;
} EFI_HII_AIBT_DUPLICATE_BLOCK;
typedef struct _EFI_HII_AIBT_SKIP1_BLOCK {
UINT8 SkipCount;
} EFI_HII_AIBT_SKIP1_BLOCK;
typedef struct _EFI_HII_AIBT_SKIP2_BLOCK {
UINT16 SkipCount;
} EFI_HII_AIBT_SKIP2_BLOCK;
#pragma pack()
UINTN
LibPcdSetSku (
UINTN SkuId
);
UINT8
LibPcdGet8 (
UINTN TokenNumber
);
UINT16
LibPcdGet16 (
UINTN TokenNumber
);
UINT32
LibPcdGet32 (
UINTN TokenNumber
);
UINT64
LibPcdGet64 (
UINTN TokenNumber
);
void *
LibPcdGetPtr (
UINTN TokenNumber
);
BOOLEAN
LibPcdGetBool (
UINTN TokenNumber
);
UINTN
LibPcdGetSize (
UINTN TokenNumber
);
UINT8
LibPcdGetEx8 (
GUID *Guid,
UINTN TokenNumber
);
UINT16
LibPcdGetEx16 (
GUID *Guid,
UINTN TokenNumber
);
UINT32
LibPcdGetEx32 (
GUID *Guid,
UINTN TokenNumber
);
UINT64
LibPcdGetEx64 (
GUID *Guid,
UINTN TokenNumber
);
void *
LibPcdGetExPtr (
GUID *Guid,
UINTN TokenNumber
);
BOOLEAN
LibPcdGetExBool (
GUID *Guid,
UINTN TokenNumber
);
UINTN
LibPcdGetExSize (
GUID *Guid,
UINTN TokenNumber
);
UINT8
LibPcdSet8 (
UINTN TokenNumber,
UINT8 Value
);
UINT16
LibPcdSet16 (
UINTN TokenNumber,
UINT16 Value
);
UINT32
LibPcdSet32 (
UINTN TokenNumber,
UINT32 Value
);
UINT64
LibPcdSet64 (
UINTN TokenNumber,
UINT64 Value
);
void *
LibPcdSetPtr (
UINTN TokenNumber,
UINTN *SizeOfBuffer,
void *Buffer
);
BOOLEAN
LibPcdSetBool (
UINTN TokenNumber,
BOOLEAN Value
);
UINT8
LibPcdSetEx8 (
GUID *Guid,
UINTN TokenNumber,
UINT8 Value
);
UINT16
LibPcdSetEx16 (
GUID *Guid,
UINTN TokenNumber,
UINT16 Value
);
UINT32
LibPcdSetEx32 (
GUID *Guid,
UINTN TokenNumber,
UINT32 Value
);
UINT64
LibPcdSetEx64 (
GUID *Guid,
UINTN TokenNumber,
UINT64 Value
);
void *
LibPcdSetExPtr (
GUID *Guid,
UINTN TokenNumber,
UINTN *SizeOfBuffer,
void *Buffer
);
BOOLEAN
LibPcdSetExBool (
GUID *Guid,
UINTN TokenNumber,
BOOLEAN Value
);
typedef
void
( *PCD_CALLBACK)(
GUID *CallBackGuid,
UINTN CallBackToken,
void *TokenData,
UINTN TokenDataSize
);
void
LibPcdCallbackOnSet (
GUID *Guid,
UINTN TokenNumber,
PCD_CALLBACK NotificationFunction
);
void
LibPcdCancelCallback (
GUID *Guid,
UINTN TokenNumber,
PCD_CALLBACK NotificationFunction
);
UINTN
LibPcdGetNextToken (
GUID *Guid,
UINTN TokenNumber
);
GUID *
LibPcdGetNextTokenSpace (
GUID *TokenSpaceGuid
);
void *
LibPatchPcdSetPtr (
void *PatchVariable,
UINTN MaximumDatumSize,
UINTN *SizeOfBuffer,
void *Buffer
);
extern GUID gEfiCallerIdGuid;
EFI_STATUS
UefiMain (
EFI_HANDLE ImageHandle,
EFI_SYSTEM_TABLE *SystemTable
);
typedef struct _EFI_DRIVER_BINDING_PROTOCOL EFI_DRIVER_BINDING_PROTOCOL;
typedef
EFI_STATUS
( *EFI_DRIVER_BINDING_SUPPORTED)(
EFI_DRIVER_BINDING_PROTOCOL *This,
EFI_HANDLE ControllerHandle,
EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
);
typedef
EFI_STATUS
( *EFI_DRIVER_BINDING_START)(
EFI_DRIVER_BINDING_PROTOCOL *This,
EFI_HANDLE ControllerHandle,
EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
);
typedef
EFI_STATUS
( *EFI_DRIVER_BINDING_STOP)(
EFI_DRIVER_BINDING_PROTOCOL *This,
EFI_HANDLE ControllerHandle,
UINTN NumberOfChildren,
EFI_HANDLE *ChildHandleBuffer
);
struct _EFI_DRIVER_BINDING_PROTOCOL {
EFI_DRIVER_BINDING_SUPPORTED Supported;
EFI_DRIVER_BINDING_START Start;
EFI_DRIVER_BINDING_STOP Stop;
UINT32 Version;
EFI_HANDLE ImageHandle;
EFI_HANDLE DriverBindingHandle;
};
extern EFI_GUID gEfiDriverBindingProtocolGuid;
typedef struct _EFI_DRIVER_CONFIGURATION2_PROTOCOL EFI_DRIVER_CONFIGURATION2_PROTOCOL;
typedef enum {
EfiDriverConfigurationActionNone = 0,
EfiDriverConfigurationActionStopController = 1,
EfiDriverConfigurationActionRestartController = 2,
EfiDriverConfigurationActionRestartPlatform = 3,
EfiDriverConfigurationActionMaximum
} EFI_DRIVER_CONFIGURATION_ACTION_REQUIRED;
typedef
EFI_STATUS
( *EFI_DRIVER_CONFIGURATION2_SET_OPTIONS)(
EFI_DRIVER_CONFIGURATION2_PROTOCOL *This,
EFI_HANDLE ControllerHandle,
EFI_HANDLE ChildHandle ,
CHAR8 *Language,
EFI_DRIVER_CONFIGURATION_ACTION_REQUIRED *ActionRequired
);
typedef
EFI_STATUS
( *EFI_DRIVER_CONFIGURATION2_OPTIONS_VALID)(
EFI_DRIVER_CONFIGURATION2_PROTOCOL *This,
EFI_HANDLE ControllerHandle,
EFI_HANDLE ChildHandle
);
typedef
EFI_STATUS
( *EFI_DRIVER_CONFIGURATION2_FORCE_DEFAULTS)(
EFI_DRIVER_CONFIGURATION2_PROTOCOL *This,
EFI_HANDLE ControllerHandle,
EFI_HANDLE ChildHandle ,
UINT32 DefaultType,
EFI_DRIVER_CONFIGURATION_ACTION_REQUIRED *ActionRequired
);
struct _EFI_DRIVER_CONFIGURATION2_PROTOCOL {
EFI_DRIVER_CONFIGURATION2_SET_OPTIONS SetOptions;
EFI_DRIVER_CONFIGURATION2_OPTIONS_VALID OptionsValid;
EFI_DRIVER_CONFIGURATION2_FORCE_DEFAULTS ForceDefaults;
CHAR8 *SupportedLanguages;
};
extern EFI_GUID gEfiDriverConfiguration2ProtocolGuid;
typedef struct _EFI_DRIVER_CONFIGURATION_PROTOCOL EFI_DRIVER_CONFIGURATION_PROTOCOL;
typedef
EFI_STATUS
( *EFI_DRIVER_CONFIGURATION_SET_OPTIONS)(
EFI_DRIVER_CONFIGURATION_PROTOCOL *This,
EFI_HANDLE ControllerHandle,
EFI_HANDLE ChildHandle ,
CHAR8 *Language,
EFI_DRIVER_CONFIGURATION_ACTION_REQUIRED *ActionRequired
);
typedef
EFI_STATUS
( *EFI_DRIVER_CONFIGURATION_OPTIONS_VALID)(
EFI_DRIVER_CONFIGURATION_PROTOCOL *This,
EFI_HANDLE ControllerHandle,
EFI_HANDLE ChildHandle
);
typedef
EFI_STATUS
( *EFI_DRIVER_CONFIGURATION_FORCE_DEFAULTS)(
EFI_DRIVER_CONFIGURATION_PROTOCOL *This,
EFI_HANDLE ControllerHandle,
EFI_HANDLE ChildHandle ,
UINT32 DefaultType,
EFI_DRIVER_CONFIGURATION_ACTION_REQUIRED *ActionRequired
);
struct _EFI_DRIVER_CONFIGURATION_PROTOCOL {
EFI_DRIVER_CONFIGURATION_SET_OPTIONS SetOptions;
EFI_DRIVER_CONFIGURATION_OPTIONS_VALID OptionsValid;
EFI_DRIVER_CONFIGURATION_FORCE_DEFAULTS ForceDefaults;
CHAR8 *SupportedLanguages;
};
extern EFI_GUID gEfiDriverConfigurationProtocolGuid;
typedef struct _EFI_COMPONENT_NAME_PROTOCOL EFI_COMPONENT_NAME_PROTOCOL;
typedef
EFI_STATUS
( *EFI_COMPONENT_NAME_GET_DRIVER_NAME)(
EFI_COMPONENT_NAME_PROTOCOL *This,
CHAR8 *Language,
CHAR16 **DriverName
);
typedef
EFI_STATUS
( *EFI_COMPONENT_NAME_GET_CONTROLLER_NAME)(
EFI_COMPONENT_NAME_PROTOCOL *This,
EFI_HANDLE ControllerHandle,
EFI_HANDLE ChildHandle ,
CHAR8 *Language,
CHAR16 **ControllerName
);
struct _EFI_COMPONENT_NAME_PROTOCOL {
EFI_COMPONENT_NAME_GET_DRIVER_NAME GetDriverName;
EFI_COMPONENT_NAME_GET_CONTROLLER_NAME GetControllerName;
CHAR8 *SupportedLanguages;
};
extern EFI_GUID gEfiComponentNameProtocolGuid;
typedef struct _EFI_COMPONENT_NAME2_PROTOCOL EFI_COMPONENT_NAME2_PROTOCOL;
typedef
EFI_STATUS
( *EFI_COMPONENT_NAME2_GET_DRIVER_NAME)(
EFI_COMPONENT_NAME2_PROTOCOL *This,
CHAR8 *Language,
CHAR16 **DriverName
);
typedef
EFI_STATUS
( *EFI_COMPONENT_NAME2_GET_CONTROLLER_NAME)(
EFI_COMPONENT_NAME2_PROTOCOL *This,
EFI_HANDLE ControllerHandle,
EFI_HANDLE ChildHandle ,
CHAR8 *Language,
CHAR16 **ControllerName
);
struct _EFI_COMPONENT_NAME2_PROTOCOL {
EFI_COMPONENT_NAME2_GET_DRIVER_NAME GetDriverName;
EFI_COMPONENT_NAME2_GET_CONTROLLER_NAME GetControllerName;
CHAR8 *SupportedLanguages;
};
extern EFI_GUID gEfiComponentName2ProtocolGuid;
typedef struct _EFI_DRIVER_DIAGNOSTICS_PROTOCOL EFI_DRIVER_DIAGNOSTICS_PROTOCOL;
typedef enum {
EfiDriverDiagnosticTypeStandard = 0,
EfiDriverDiagnosticTypeExtended = 1,
EfiDriverDiagnosticTypeManufacturing= 2,
EfiDriverDiagnosticTypeMaximum
} EFI_DRIVER_DIAGNOSTIC_TYPE;
typedef
EFI_STATUS
( *EFI_DRIVER_DIAGNOSTICS_RUN_DIAGNOSTICS)(
EFI_DRIVER_DIAGNOSTICS_PROTOCOL *This,
EFI_HANDLE ControllerHandle,
EFI_HANDLE ChildHandle ,
EFI_DRIVER_DIAGNOSTIC_TYPE DiagnosticType,
CHAR8 *Language,
EFI_GUID **ErrorType,
UINTN *BufferSize,
CHAR16 **Buffer
);
struct _EFI_DRIVER_DIAGNOSTICS_PROTOCOL {
EFI_DRIVER_DIAGNOSTICS_RUN_DIAGNOSTICS RunDiagnostics;
CHAR8 *SupportedLanguages;
};
extern EFI_GUID gEfiDriverDiagnosticsProtocolGuid;
typedef struct _EFI_DRIVER_DIAGNOSTICS2_PROTOCOL EFI_DRIVER_DIAGNOSTICS2_PROTOCOL;
typedef
EFI_STATUS
( *EFI_DRIVER_DIAGNOSTICS2_RUN_DIAGNOSTICS)(
EFI_DRIVER_DIAGNOSTICS2_PROTOCOL *This,
EFI_HANDLE ControllerHandle,
EFI_HANDLE ChildHandle ,
EFI_DRIVER_DIAGNOSTIC_TYPE DiagnosticType,
CHAR8 *Language,
EFI_GUID **ErrorType,
UINTN *BufferSize,
CHAR16 **Buffer
);
struct _EFI_DRIVER_DIAGNOSTICS2_PROTOCOL {
EFI_DRIVER_DIAGNOSTICS2_RUN_DIAGNOSTICS RunDiagnostics;
CHAR8 *SupportedLanguages;
};
extern EFI_GUID gEfiDriverDiagnostics2ProtocolGuid;
typedef struct _EFI_GRAPHICS_OUTPUT_PROTOCOL EFI_GRAPHICS_OUTPUT_PROTOCOL;
typedef struct {
UINT32 RedMask;
UINT32 GreenMask;
UINT32 BlueMask;
UINT32 ReservedMask;
} EFI_PIXEL_BITMASK;
typedef enum {
PixelRedGreenBlueReserved8BitPerColor,
PixelBlueGreenRedReserved8BitPerColor,
PixelBitMask,
PixelBltOnly,
PixelFormatMax
} EFI_GRAPHICS_PIXEL_FORMAT;
typedef struct {
UINT32 Version;
UINT32 HorizontalResolution;
UINT32 VerticalResolution;
EFI_GRAPHICS_PIXEL_FORMAT PixelFormat;
EFI_PIXEL_BITMASK PixelInformation;
UINT32 PixelsPerScanLine;
} EFI_GRAPHICS_OUTPUT_MODE_INFORMATION;
typedef
EFI_STATUS
( *EFI_GRAPHICS_OUTPUT_PROTOCOL_QUERY_MODE)(
EFI_GRAPHICS_OUTPUT_PROTOCOL *This,
UINT32 ModeNumber,
UINTN *SizeOfInfo,
EFI_GRAPHICS_OUTPUT_MODE_INFORMATION **Info
);
typedef
EFI_STATUS
( *EFI_GRAPHICS_OUTPUT_PROTOCOL_SET_MODE)(
EFI_GRAPHICS_OUTPUT_PROTOCOL *This,
UINT32 ModeNumber
);
typedef struct {
UINT8 Blue;
UINT8 Green;
UINT8 Red;
UINT8 Reserved;
} EFI_GRAPHICS_OUTPUT_BLT_PIXEL;
typedef union {
EFI_GRAPHICS_OUTPUT_BLT_PIXEL Pixel;
UINT32 Raw;
} EFI_GRAPHICS_OUTPUT_BLT_PIXEL_UNION;
typedef enum {
EfiBltVideoFill,
EfiBltVideoToBltBuffer,
EfiBltBufferToVideo,
EfiBltVideoToVideo,
EfiGraphicsOutputBltOperationMax
} EFI_GRAPHICS_OUTPUT_BLT_OPERATION;
typedef
EFI_STATUS
( *EFI_GRAPHICS_OUTPUT_PROTOCOL_BLT)(
EFI_GRAPHICS_OUTPUT_PROTOCOL *This,
EFI_GRAPHICS_OUTPUT_BLT_PIXEL *BltBuffer,
EFI_GRAPHICS_OUTPUT_BLT_OPERATION BltOperation,
UINTN SourceX,
UINTN SourceY,
UINTN DestinationX,
UINTN DestinationY,
UINTN Width,
UINTN Height,
UINTN Delta
);
typedef struct {
UINT32 MaxMode;
UINT32 Mode;
EFI_GRAPHICS_OUTPUT_MODE_INFORMATION *Info;
UINTN SizeOfInfo;
EFI_PHYSICAL_ADDRESS FrameBufferBase;
UINTN FrameBufferSize;
} EFI_GRAPHICS_OUTPUT_PROTOCOL_MODE;
struct _EFI_GRAPHICS_OUTPUT_PROTOCOL {
EFI_GRAPHICS_OUTPUT_PROTOCOL_QUERY_MODE QueryMode;
EFI_GRAPHICS_OUTPUT_PROTOCOL_SET_MODE SetMode;
EFI_GRAPHICS_OUTPUT_PROTOCOL_BLT Blt;
EFI_GRAPHICS_OUTPUT_PROTOCOL_MODE *Mode;
};
extern EFI_GUID gEfiGraphicsOutputProtocolGuid;
typedef struct {
UINT64 Rbx;
UINT64 Rsp;
UINT64 Rbp;
UINT64 Rdi;
UINT64 Rsi;
UINT64 R12;
UINT64 R13;
UINT64 R14;
UINT64 R15;
UINT64 Rip;
UINT64 MxCsr;
UINT8 XmmBuffer[160];
} BASE_LIBRARY_JUMP_BUFFER;
CHAR16 *
StrCpy (
CHAR16 *Destination,
CHAR16 *Source
);
CHAR16 *
StrnCpy (
CHAR16 *Destination,
CHAR16 *Source,
UINTN Length
);
UINTN
StrLen (
CHAR16 *String
);
UINTN
StrSize (
CHAR16 *String
);
INTN
StrCmp (
CHAR16 *FirstString,
CHAR16 *SecondString
);
INTN
StrnCmp (
CHAR16 *FirstString,
CHAR16 *SecondString,
UINTN Length
);
CHAR16 *
StrCat (
CHAR16 *Destination,
CHAR16 *Source
);
CHAR16 *
StrnCat (
CHAR16 *Destination,
CHAR16 *Source,
UINTN Length
);
CHAR16 *
StrStr (
CHAR16 *String,
CHAR16 *SearchString
);
UINTN
StrDecimalToUintn (
CHAR16 *String
);
UINT64
StrDecimalToUint64 (
CHAR16 *String
);
UINTN
StrHexToUintn (
CHAR16 *String
);
UINT64
StrHexToUint64 (
CHAR16 *String
);
CHAR8 *
UnicodeStrToAsciiStr (
CHAR16 *Source,
CHAR8 *Destination
);
CHAR8 *
AsciiStrCpy (
CHAR8 *Destination,
CHAR8 *Source
);
CHAR8 *
AsciiStrnCpy (
CHAR8 *Destination,
CHAR8 *Source,
UINTN Length
);
UINTN
AsciiStrLen (
CHAR8 *String
);
UINTN
AsciiStrSize (
CHAR8 *String
);
INTN
AsciiStrCmp (
CHAR8 *FirstString,
CHAR8 *SecondString
);
INTN
AsciiStriCmp (
CHAR8 *FirstString,
CHAR8 *SecondString
);
INTN
AsciiStrnCmp (
CHAR8 *FirstString,
CHAR8 *SecondString,
UINTN Length
);
CHAR8 *
AsciiStrCat (
CHAR8 *Destination,
CHAR8 *Source
);
CHAR8 *
AsciiStrnCat (
CHAR8 *Destination,
CHAR8 *Source,
UINTN Length
);
CHAR8 *
AsciiStrStr (
CHAR8 *String,
CHAR8 *SearchString
);
UINTN
AsciiStrDecimalToUintn (
CHAR8 *String
);
UINT64
AsciiStrDecimalToUint64 (
CHAR8 *String
);
UINTN
AsciiStrHexToUintn (
CHAR8 *String
);
UINT64
AsciiStrHexToUint64 (
CHAR8 *String
);
CHAR16 *
AsciiStrToUnicodeStr (
CHAR8 *Source,
CHAR16 *Destination
);
UINT8
DecimalToBcd8 (
UINT8 Value
);
UINT8
BcdToDecimal8 (
UINT8 Value
);
LIST_ENTRY *
InitializeListHead (
LIST_ENTRY *ListHead
);
LIST_ENTRY *
InsertHeadList (
LIST_ENTRY *ListHead,
LIST_ENTRY *Entry
);
LIST_ENTRY *
InsertTailList (
LIST_ENTRY *ListHead,
LIST_ENTRY *Entry
);
LIST_ENTRY *
GetFirstNode (
LIST_ENTRY *List
);
LIST_ENTRY *
GetNextNode (
LIST_ENTRY *List,
LIST_ENTRY *Node
);
LIST_ENTRY *
GetPreviousNode (
LIST_ENTRY *List,
LIST_ENTRY *Node
);
BOOLEAN
IsListEmpty (
LIST_ENTRY *ListHead
);
BOOLEAN
IsNull (
LIST_ENTRY *List,
LIST_ENTRY *Node
);
BOOLEAN
IsNodeAtEnd (
LIST_ENTRY *List,
LIST_ENTRY *Node
);
LIST_ENTRY *
SwapListEntries (
LIST_ENTRY *FirstEntry,
LIST_ENTRY *SecondEntry
);
LIST_ENTRY *
RemoveEntryList (
LIST_ENTRY *Entry
);
UINT64
LShiftU64 (
UINT64 Operand,
UINTN Count
);
UINT64
RShiftU64 (
UINT64 Operand,
UINTN Count
);
UINT64
ARShiftU64 (
UINT64 Operand,
UINTN Count
);
UINT32
LRotU32 (
UINT32 Operand,
UINTN Count
);
UINT32
RRotU32 (
UINT32 Operand,
UINTN Count
);
UINT64
LRotU64 (
UINT64 Operand,
UINTN Count
);
UINT64
RRotU64 (
UINT64 Operand,
UINTN Count
);
INTN
LowBitSet32 (
UINT32 Operand
);
INTN
LowBitSet64 (
UINT64 Operand
);
INTN
HighBitSet32 (
UINT32 Operand
);
INTN
HighBitSet64 (
UINT64 Operand
);
UINT32
GetPowerOfTwo32 (
UINT32 Operand
);
UINT64
GetPowerOfTwo64 (
UINT64 Operand
);
UINT16
SwapBytes16 (
UINT16 Value
);
UINT32
SwapBytes32 (
UINT32 Value
);
UINT64
SwapBytes64 (
UINT64 Value
);
UINT64
MultU64x32 (
UINT64 Multiplicand,
UINT32 Multiplier
);
UINT64
MultU64x64 (
UINT64 Multiplicand,
UINT64 Multiplier
);
INT64
MultS64x64 (
INT64 Multiplicand,
INT64 Multiplier
);
UINT64
DivU64x32 (
UINT64 Dividend,
UINT32 Divisor
);
UINT32
ModU64x32 (
UINT64 Dividend,
UINT32 Divisor
);
UINT64
DivU64x32Remainder (
UINT64 Dividend,
UINT32 Divisor,
UINT32 *Remainder
);
UINT64
DivU64x64Remainder (
UINT64 Dividend,
UINT64 Divisor,
UINT64 *Remainder
);
INT64
DivS64x64Remainder (
INT64 Dividend,
INT64 Divisor,
INT64 *Remainder
);
UINT16
ReadUnaligned16 (
UINT16 *Buffer
);
UINT16
WriteUnaligned16 (
UINT16 *Buffer,
UINT16 Value
);
UINT32
ReadUnaligned24 (
UINT32 *Buffer
);
UINT32
WriteUnaligned24 (
UINT32 *Buffer,
UINT32 Value
);
UINT32
ReadUnaligned32 (
UINT32 *Buffer
);
UINT32
WriteUnaligned32 (
UINT32 *Buffer,
UINT32 Value
);
UINT64
ReadUnaligned64 (
UINT64 *Buffer
);
UINT64
WriteUnaligned64 (
UINT64 *Buffer,
UINT64 Value
);
UINT8
BitFieldRead8 (
UINT8 Operand,
UINTN StartBit,
UINTN EndBit
);
UINT8
BitFieldWrite8 (
UINT8 Operand,
UINTN StartBit,
UINTN EndBit,
UINT8 Value
);
UINT8
BitFieldOr8 (
UINT8 Operand,
UINTN StartBit,
UINTN EndBit,
UINT8 OrData
);
UINT8
BitFieldAnd8 (
UINT8 Operand,
UINTN StartBit,
UINTN EndBit,
UINT8 AndData
);
UINT8
BitFieldAndThenOr8 (
UINT8 Operand,
UINTN StartBit,
UINTN EndBit,
UINT8 AndData,
UINT8 OrData
);
UINT16
BitFieldRead16 (
UINT16 Operand,
UINTN StartBit,
UINTN EndBit
);
UINT16
BitFieldWrite16 (
UINT16 Operand,
UINTN StartBit,
UINTN EndBit,
UINT16 Value
);
UINT16
BitFieldOr16 (
UINT16 Operand,
UINTN StartBit,
UINTN EndBit,
UINT16 OrData
);
UINT16
BitFieldAnd16 (
UINT16 Operand,
UINTN StartBit,
UINTN EndBit,
UINT16 AndData
);
UINT16
BitFieldAndThenOr16 (
UINT16 Operand,
UINTN StartBit,
UINTN EndBit,
UINT16 AndData,
UINT16 OrData
);
UINT32
BitFieldRead32 (
UINT32 Operand,
UINTN StartBit,
UINTN EndBit
);
UINT32
BitFieldWrite32 (
UINT32 Operand,
UINTN StartBit,
UINTN EndBit,
UINT32 Value
);
UINT32
BitFieldOr32 (
UINT32 Operand,
UINTN StartBit,
UINTN EndBit,
UINT32 OrData
);
UINT32
BitFieldAnd32 (
UINT32 Operand,
UINTN StartBit,
UINTN EndBit,
UINT32 AndData
);
UINT32
BitFieldAndThenOr32 (
UINT32 Operand,
UINTN StartBit,
UINTN EndBit,
UINT32 AndData,
UINT32 OrData
);
UINT64
BitFieldRead64 (
UINT64 Operand,
UINTN StartBit,
UINTN EndBit
);
UINT64
BitFieldWrite64 (
UINT64 Operand,
UINTN StartBit,
UINTN EndBit,
UINT64 Value
);
UINT64
BitFieldOr64 (
UINT64 Operand,
UINTN StartBit,
UINTN EndBit,
UINT64 OrData
);
UINT64
BitFieldAnd64 (
UINT64 Operand,
UINTN StartBit,
UINTN EndBit,
UINT64 AndData
);
UINT64
BitFieldAndThenOr64 (
UINT64 Operand,
UINTN StartBit,
UINTN EndBit,
UINT64 AndData,
UINT64 OrData
);
UINT8
CalculateSum8 (
UINT8 *Buffer,
UINTN Length
);
UINT8
CalculateCheckSum8 (
UINT8 *Buffer,
UINTN Length
);
UINT16
CalculateSum16 (
UINT16 *Buffer,
UINTN Length
);
UINT16
CalculateCheckSum16 (
UINT16 *Buffer,
UINTN Length
);
UINT32
CalculateSum32 (
UINT32 *Buffer,
UINTN Length
);
UINT32
CalculateCheckSum32 (
UINT32 *Buffer,
UINTN Length
);
UINT64
CalculateSum64 (
UINT64 *Buffer,
UINTN Length
);
UINT64
CalculateCheckSum64 (
UINT64 *Buffer,
UINTN Length
);
typedef
void
( *SWITCH_STACK_ENTRY_POINT)(
void *Context1,
void *Context2
);
void
MemoryFence (
void
);
UINTN
SetJump (
BASE_LIBRARY_JUMP_BUFFER *JumpBuffer
);
void
LongJump (
BASE_LIBRARY_JUMP_BUFFER *JumpBuffer,
UINTN Value
);
void
EnableInterrupts (
void
);
void
DisableInterrupts (
void
);
BOOLEAN
SaveAndDisableInterrupts (
void
);
void
EnableDisableInterrupts (
void
);
BOOLEAN
GetInterruptState (
void
);
BOOLEAN
SetInterruptState (
BOOLEAN InterruptState
);
void
CpuPause (
void
);
void
SwitchStack (
SWITCH_STACK_ENTRY_POINT EntryPoint,
void *Context1,
void *Context2,
void *NewStack,
...
);
void
CpuBreakpoint (
void
);
void
CpuDeadLoop (
void
);
typedef union {
struct {
UINT32 CF:1;
UINT32 Reserved_0:1;
UINT32 PF:1;
UINT32 Reserved_1:1;
UINT32 AF:1;
UINT32 Reserved_2:1;
UINT32 ZF:1;
UINT32 SF:1;
UINT32 TF:1;
UINT32 IF:1;
UINT32 DF:1;
UINT32 OF:1;
UINT32 IOPL:2;
UINT32 NT:1;
UINT32 Reserved_3:1;
} Bits;
UINT16 Uint16;
} IA32_FLAGS16;
typedef union {
struct {
UINT32 CF:1;
UINT32 Reserved_0:1;
UINT32 PF:1;
UINT32 Reserved_1:1;
UINT32 AF:1;
UINT32 Reserved_2:1;
UINT32 ZF:1;
UINT32 SF:1;
UINT32 TF:1;
UINT32 IF:1;
UINT32 DF:1;
UINT32 OF:1;
UINT32 IOPL:2;
UINT32 NT:1;
UINT32 Reserved_3:1;
UINT32 RF:1;
UINT32 VM:1;
UINT32 AC:1;
UINT32 VIF:1;
UINT32 VIP:1;
UINT32 ID:1;
UINT32 Reserved_4:10;
} Bits;
UINTN UintN;
} IA32_EFLAGS32;
typedef union {
struct {
UINT32 PE:1;
UINT32 MP:1;
UINT32 EM:1;
UINT32 TS:1;
UINT32 ET:1;
UINT32 NE:1;
UINT32 Reserved_0:10;
UINT32 WP:1;
UINT32 Reserved_1:1;
UINT32 AM:1;
UINT32 Reserved_2:10;
UINT32 NW:1;
UINT32 CD:1;
UINT32 PG:1;
} Bits;
UINTN UintN;
} IA32_CR0;
typedef union {
struct {
UINT32 VME:1;
UINT32 PVI:1;
UINT32 TSD:1;
UINT32 DE:1;
UINT32 PSE:1;
UINT32 PAE:1;
UINT32 MCE:1;
UINT32 PGE:1;
UINT32 PCE:1;
UINT32 OSFXSR:1;
UINT32 OSXMMEXCPT:1;
UINT32 Reserved_0:2;
UINT32 VMXE:1;
UINT32 Reserved_1:18;
} Bits;
UINTN UintN;
} IA32_CR4;
typedef union {
struct {
UINT32 LimitLow:16;
UINT32 BaseLow:16;
UINT32 BaseMid:8;
UINT32 Type:4;
UINT32 S:1;
UINT32 DPL:2;
UINT32 P:1;
UINT32 LimitHigh:4;
UINT32 AVL:1;
UINT32 L:1;
UINT32 DB:1;
UINT32 G:1;
UINT32 BaseHigh:8;
} Bits;
UINT64 Uint64;
} IA32_SEGMENT_DESCRIPTOR;
#pragma pack (1)
typedef struct {
UINT16 Limit;
UINTN Base;
} IA32_DESCRIPTOR;
#pragma pack ()
typedef union {
struct {
UINT32 OffsetLow:16;
UINT32 Selector:16;
UINT32 Reserved_0:8;
UINT32 GateType:8;
UINT32 OffsetHigh:16;
UINT32 OffsetUpper:32;
UINT32 Reserved_1:32;
} Bits;
struct {
UINT64 Uint64;
UINT64 Uint64_1;
} Uint128;
} IA32_IDT_GATE_DESCRIPTOR;
typedef struct {
UINT8 Buffer[512];
} IA32_FX_BUFFER;
typedef struct {
UINT32 Reserved1;
UINT32 Reserved2;
UINT32 Reserved3;
UINT32 Reserved4;
UINT8 BL;
UINT8 BH;
UINT16 Reserved5;
UINT8 DL;
UINT8 DH;
UINT16 Reserved6;
UINT8 CL;
UINT8 CH;
UINT16 Reserved7;
UINT8 AL;
UINT8 AH;
UINT16 Reserved8;
} IA32_BYTE_REGS;
typedef struct {
UINT16 DI;
UINT16 Reserved1;
UINT16 SI;
UINT16 Reserved2;
UINT16 BP;
UINT16 Reserved3;
UINT16 SP;
UINT16 Reserved4;
UINT16 BX;
UINT16 Reserved5;
UINT16 DX;
UINT16 Reserved6;
UINT16 CX;
UINT16 Reserved7;
UINT16 AX;
UINT16 Reserved8;
} IA32_WORD_REGS;
typedef struct {
UINT32 EDI;
UINT32 ESI;
UINT32 EBP;
UINT32 ESP;
UINT32 EBX;
UINT32 EDX;
UINT32 ECX;
UINT32 EAX;
UINT16 DS;
UINT16 ES;
UINT16 FS;
UINT16 GS;
IA32_EFLAGS32 EFLAGS;
UINT32 Eip;
UINT16 CS;
UINT16 SS;
} IA32_DWORD_REGS;
typedef union {
IA32_DWORD_REGS E;
IA32_WORD_REGS X;
IA32_BYTE_REGS H;
} IA32_REGISTER_SET;
typedef struct {
IA32_REGISTER_SET *RealModeState;
void *RealModeBuffer;
UINT32 RealModeBufferSize;
UINT32 ThunkAttributes;
} THUNK_CONTEXT;
UINT32
AsmCpuid (
UINT32 Index,
UINT32 *Eax,
UINT32 *Ebx,
UINT32 *Ecx,
UINT32 *Edx
);
UINT32
AsmCpuidEx (
UINT32 Index,
UINT32 SubIndex,
UINT32 *Eax,
UINT32 *Ebx,
UINT32 *Ecx,
UINT32 *Edx
);
void
AsmDisableCache (
void
);
void
AsmEnableCache (
void
);
UINT32
AsmReadMsr32 (
UINT32 Index
);
UINT32
AsmWriteMsr32 (
UINT32 Index,
UINT32 Value
);
UINT32
AsmMsrOr32 (
UINT32 Index,
UINT32 OrData
);
UINT32
AsmMsrAnd32 (
UINT32 Index,
UINT32 AndData
);
UINT32
AsmMsrAndThenOr32 (
UINT32 Index,
UINT32 AndData,
UINT32 OrData
);
UINT32
AsmMsrBitFieldRead32 (
UINT32 Index,
UINTN StartBit,
UINTN EndBit
);
UINT32
AsmMsrBitFieldWrite32 (
UINT32 Index,
UINTN StartBit,
UINTN EndBit,
UINT32 Value
);
UINT32
AsmMsrBitFieldOr32 (
UINT32 Index,
UINTN StartBit,
UINTN EndBit,
UINT32 OrData
);
UINT32
AsmMsrBitFieldAnd32 (
UINT32 Index,
UINTN StartBit,
UINTN EndBit,
UINT32 AndData
);
UINT32
AsmMsrBitFieldAndThenOr32 (
UINT32 Index,
UINTN StartBit,
UINTN EndBit,
UINT32 AndData,
UINT32 OrData
);
UINT64
AsmReadMsr64 (
UINT32 Index
);
UINT64
AsmWriteMsr64 (
UINT32 Index,
UINT64 Value
);
UINT64
AsmMsrOr64 (
UINT32 Index,
UINT64 OrData
);
UINT64
AsmMsrAnd64 (
UINT32 Index,
UINT64 AndData
);
UINT64
AsmMsrAndThenOr64 (
UINT32 Index,
UINT64 AndData,
UINT64 OrData
);
UINT64
AsmMsrBitFieldRead64 (
UINT32 Index,
UINTN StartBit,
UINTN EndBit
);
UINT64
AsmMsrBitFieldWrite64 (
UINT32 Index,
UINTN StartBit,
UINTN EndBit,
UINT64 Value
);
UINT64
AsmMsrBitFieldOr64 (
UINT32 Index,
UINTN StartBit,
UINTN EndBit,
UINT64 OrData
);
UINT64
AsmMsrBitFieldAnd64 (
UINT32 Index,
UINTN StartBit,
UINTN EndBit,
UINT64 AndData
);
UINT64
AsmMsrBitFieldAndThenOr64 (
UINT32 Index,
UINTN StartBit,
UINTN EndBit,
UINT64 AndData,
UINT64 OrData
);
UINTN
AsmReadEflags (
void
);
UINTN
AsmReadCr0 (
void
);
UINTN
AsmReadCr2 (
void
);
UINTN
AsmReadCr3 (
void
);
UINTN
AsmReadCr4 (
void
);
UINTN
AsmWriteCr0 (
UINTN Cr0
);
UINTN
AsmWriteCr2 (
UINTN Cr2
);
UINTN
AsmWriteCr3 (
UINTN Cr3
);
UINTN