Initial directory structure of IntelFrameworkPkg.
authorbxing <bxing@6f19259b-4bc3-4df7-8a09-765794883524>
Fri, 15 Jun 2007 10:02:42 +0000 (10:02 +0000)
committerbxing <bxing@6f19259b-4bc3-4df7-8a09-765794883524>
Fri, 15 Jun 2007 10:02:42 +0000 (10:02 +0000)
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@2657 6f19259b-4bc3-4df7-8a09-765794883524

67 files changed:
IntelFrameworkPkg/Include/Common/DataHubRecords.h [new file with mode: 0644]
IntelFrameworkPkg/Include/Common/FrameworkDxeCis.h [new file with mode: 0644]
IntelFrameworkPkg/Include/Common/FrameworkFirmwareFileSystem.h [new file with mode: 0644]
IntelFrameworkPkg/Include/Common/FrameworkHob.h [new file with mode: 0644]
IntelFrameworkPkg/Include/Common/FrameworkLegacy16.h [new file with mode: 0644]
IntelFrameworkPkg/Include/Common/FrameworkSmmCis.h [new file with mode: 0644]
IntelFrameworkPkg/Include/Common/FrameworkStatusCode.h [new file with mode: 0644]
IntelFrameworkPkg/Include/FrameworkBase.h [new file with mode: 0644]
IntelFrameworkPkg/Include/FrameworkDxe.h [new file with mode: 0644]
IntelFrameworkPkg/Include/FrameworkPei.h [new file with mode: 0644]
IntelFrameworkPkg/Include/FrameworkSmm.h [new file with mode: 0644]
IntelFrameworkPkg/Include/Guid/AcpiTableStorage.h [new file with mode: 0644]
IntelFrameworkPkg/Include/Guid/Capsule.h [new file with mode: 0644]
IntelFrameworkPkg/Include/Guid/DataHubRecords.h [new file with mode: 0644]
IntelFrameworkPkg/Include/Guid/FrameworkDevicePath.h [new file with mode: 0644]
IntelFrameworkPkg/Include/Guid/SmmCommunicate.h [new file with mode: 0644]
IntelFrameworkPkg/Include/Guid/SmramMemoryReserve.h [new file with mode: 0644]
IntelFrameworkPkg/Include/Ppi/BlockIo.h [new file with mode: 0644]
IntelFrameworkPkg/Include/Ppi/BootScriptExecuter.h [new file with mode: 0644]
IntelFrameworkPkg/Include/Ppi/RecoveryModule.h [new file with mode: 0644]
IntelFrameworkPkg/Include/Ppi/S3Resume.h [new file with mode: 0644]
IntelFrameworkPkg/Include/Ppi/Smbus.h [new file with mode: 0644]
IntelFrameworkPkg/Include/Protocol/AcpiSupport.h [new file with mode: 0644]
IntelFrameworkPkg/Include/Protocol/BootScriptSave.h [new file with mode: 0644]
IntelFrameworkPkg/Include/Protocol/CpuIo.h [new file with mode: 0644]
IntelFrameworkPkg/Include/Protocol/DataHub.h [new file with mode: 0644]
IntelFrameworkPkg/Include/Protocol/FirmwareVolume.h [new file with mode: 0644]
IntelFrameworkPkg/Include/Protocol/FirmwareVolumeBlock.h [new file with mode: 0644]
IntelFrameworkPkg/Include/Protocol/Hii.h [new file with mode: 0644]
IntelFrameworkPkg/Include/Protocol/IdeControllerInit.h [new file with mode: 0644]
IntelFrameworkPkg/Include/Protocol/IncompatiblePciDeviceSupport.h [new file with mode: 0644]
IntelFrameworkPkg/Include/Protocol/Legacy8259.h [new file with mode: 0644]
IntelFrameworkPkg/Include/Protocol/LegacyBios.h [new file with mode: 0644]
IntelFrameworkPkg/Include/Protocol/LegacyBiosPlatform.h [new file with mode: 0644]
IntelFrameworkPkg/Include/Protocol/LegacyInterrupt.h [new file with mode: 0644]
IntelFrameworkPkg/Include/Protocol/LegacyRegion.h [new file with mode: 0644]
IntelFrameworkPkg/Include/Protocol/PciHostBridgeResourceAllocation.h [new file with mode: 0644]
IntelFrameworkPkg/Include/Protocol/PciHotPlugInit.h [new file with mode: 0644]
IntelFrameworkPkg/Include/Protocol/PciPlatform.h [new file with mode: 0644]
IntelFrameworkPkg/Include/Protocol/SectionExtraction.h [new file with mode: 0644]
IntelFrameworkPkg/Include/Protocol/SmmAccess.h [new file with mode: 0644]
IntelFrameworkPkg/Include/Protocol/SmmBase.h [new file with mode: 0644]
IntelFrameworkPkg/Include/Protocol/SmmControl.h [new file with mode: 0644]
IntelFrameworkPkg/Include/Protocol/SmmGpiDispatch.h [new file with mode: 0644]
IntelFrameworkPkg/Include/Protocol/SmmIchnDispatch.h [new file with mode: 0644]
IntelFrameworkPkg/Include/Protocol/SmmPeriodicTimerDispatch.h [new file with mode: 0644]
IntelFrameworkPkg/Include/Protocol/SmmPowerButtonDispatch.h [new file with mode: 0644]
IntelFrameworkPkg/Include/Protocol/SmmStandbyButtonDispatch.h [new file with mode: 0644]
IntelFrameworkPkg/Include/Protocol/SmmSwDispatch.h [new file with mode: 0644]
IntelFrameworkPkg/Include/Protocol/SmmSxDispatch.h [new file with mode: 0644]
IntelFrameworkPkg/Include/Protocol/SmmUsbDispatch.h [new file with mode: 0644]
IntelFrameworkPkg/IntelFrameworkPkg.spd [new file with mode: 0644]
IntelFrameworkPkg/Library/DxeIoLibCpuIo/DxeCpuIoLibInternal.h [new file with mode: 0644]
IntelFrameworkPkg/Library/DxeIoLibCpuIo/DxeIoLibCpuIo.msa [new file with mode: 0644]
IntelFrameworkPkg/Library/DxeIoLibCpuIo/IoHighLevel.c [new file with mode: 0644]
IntelFrameworkPkg/Library/DxeIoLibCpuIo/IoLib.c [new file with mode: 0644]
IntelFrameworkPkg/Library/DxeIoLibCpuIo/IoLibMmioBuffer.c [new file with mode: 0644]
IntelFrameworkPkg/Library/DxeReportStatusCodeLibFramework/DxeReportStatusCodeLib.msa [new file with mode: 0644]
IntelFrameworkPkg/Library/DxeReportStatusCodeLibFramework/ReportStatusCodeLib.c [new file with mode: 0644]
IntelFrameworkPkg/Library/DxeSmmDriverEntryPoint/DriverEntryPoint.c [new file with mode: 0644]
IntelFrameworkPkg/Library/DxeSmmDriverEntryPoint/DxeSmmDriverEntryPoint.msa [new file with mode: 0644]
IntelFrameworkPkg/Library/UefiLibFramework/Console.c [new file with mode: 0644]
IntelFrameworkPkg/Library/UefiLibFramework/UefiLib.c [new file with mode: 0644]
IntelFrameworkPkg/Library/UefiLibFramework/UefiLib.msa [new file with mode: 0644]
IntelFrameworkPkg/Library/UefiLibFramework/UefiLibFramework.h [new file with mode: 0644]
IntelFrameworkPkg/Library/UefiLibFramework/UefiLibPrint.c [new file with mode: 0644]
IntelFrameworkPkg/Library/UefiLibFramework/UefiNotTiano.c [new file with mode: 0644]

diff --git a/IntelFrameworkPkg/Include/Common/DataHubRecords.h b/IntelFrameworkPkg/Include/Common/DataHubRecords.h
new file mode 100644 (file)
index 0000000..29bc8a7
--- /dev/null
@@ -0,0 +1,1908 @@
+/** @file\r
+  This file defines GUIDs and associated data structures for records posted to the Data Hub.\r
+  The producers of these records use these definitions to construct records.\r
+  The consumers of these records use these definitions to retrieve, filter and parse records.\r
+\r
+  Copyright (c) 2007, Intel Corporation\r
+  All rights reserved. This program and the accompanying materials\r
+  are licensed and made available under the terms and conditions of the BSD License\r
+  which accompanies this distribution.  The full text of the license may be found at\r
+  http://opensource.org/licenses/bsd-license.php\r
+\r
+  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
+  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
+\r
+  Module Name:  DataHubRecords.h\r
+\r
+  @par Revision Reference:\r
+  DataHubRecord.h include all data hub sub class defitions from Cache subclass\r
+  spec 0.9, DataHub SubClass spec 0.9, Memory SubClass Spec 0.9, Processor\r
+  Subclass spec 0.9,Misc SubClass spec 0.9.\r
+\r
+**/\r
+\r
+#ifndef _DATAHUB_RECORDS_H_\r
+#define _DATAHUB_RECORDS_H_\r
+\r
+#define EFI_PROCESSOR_SUBCLASS_VERSION    0x00010000\r
+\r
+\r
+#pragma pack(1)\r
+\r
+typedef struct _USB_PORT_DEVICE_PATH {\r
+  ACPI_HID_DEVICE_PATH      PciRootBridgeDevicePath;\r
+  PCI_DEVICE_PATH           PciBusDevicePath;\r
+  EFI_DEVICE_PATH_PROTOCOL  EndDevicePath;\r
+} USB_PORT_DEVICE_PATH;\r
+\r
+//\r
+// IDE\r
+//\r
+typedef struct _IDE_DEVICE_PATH {\r
+  ACPI_HID_DEVICE_PATH      PciRootBridgeDevicePath;\r
+  PCI_DEVICE_PATH           PciBusDevicePath;\r
+  EFI_DEVICE_PATH_PROTOCOL  EndDevicePath;\r
+} IDE_DEVICE_PATH;\r
+\r
+//\r
+// RMC Connector\r
+//\r
+typedef struct _RMC_CONN_DEVICE_PATH {\r
+  ACPI_HID_DEVICE_PATH      PciRootBridgeDevicePath;\r
+  PCI_DEVICE_PATH           PciBridgeDevicePath;\r
+  PCI_DEVICE_PATH           PciBusDevicePath;\r
+  EFI_DEVICE_PATH_PROTOCOL  EndDevicePath;\r
+} RMC_CONN_DEVICE_PATH;\r
+\r
+//\r
+// RIDE\r
+//\r
+typedef struct _RIDE_DEVICE_PATH {\r
+  ACPI_HID_DEVICE_PATH      PciRootBridgeDevicePath;\r
+  PCI_DEVICE_PATH           PciBridgeDevicePath;\r
+  PCI_DEVICE_PATH           PciBusDevicePath;\r
+  EFI_DEVICE_PATH_PROTOCOL  EndDevicePath;\r
+} RIDE_DEVICE_PATH;\r
+\r
+//\r
+// Gigabit NIC\r
+//\r
+typedef struct _GB_NIC_DEVICE_PATH {\r
+  ACPI_HID_DEVICE_PATH      PciRootBridgeDevicePath;\r
+  PCI_DEVICE_PATH           PciBridgeDevicePath;\r
+  PCI_DEVICE_PATH           PciXBridgeDevicePath;\r
+  PCI_DEVICE_PATH           PciXBusDevicePath;\r
+  EFI_DEVICE_PATH_PROTOCOL  EndDevicePath;\r
+} GB_NIC_DEVICE_PATH;\r
+\r
+//\r
+// P/S2 Connector\r
+//\r
+typedef struct _PS2_CONN_DEVICE_PATH {\r
+  ACPI_HID_DEVICE_PATH      PciRootBridgeDevicePath;\r
+  PCI_DEVICE_PATH           LpcBridgeDevicePath;\r
+  ACPI_HID_DEVICE_PATH      LpcBusDevicePath;\r
+  EFI_DEVICE_PATH_PROTOCOL  EndDevicePath;\r
+} PS2_CONN_DEVICE_PATH;\r
+\r
+//\r
+// Serial Port Connector\r
+//\r
+typedef struct _SERIAL_CONN_DEVICE_PATH {\r
+  ACPI_HID_DEVICE_PATH      PciRootBridgeDevicePath;\r
+  PCI_DEVICE_PATH           LpcBridgeDevicePath;\r
+  ACPI_HID_DEVICE_PATH      LpcBusDevicePath;\r
+  EFI_DEVICE_PATH_PROTOCOL  EndDevicePath;\r
+} SERIAL_CONN_DEVICE_PATH;\r
+\r
+//\r
+// Parallel Port Connector\r
+//\r
+typedef struct _PARALLEL_CONN_DEVICE_PATH {\r
+  ACPI_HID_DEVICE_PATH      PciRootBridgeDevicePath;\r
+  PCI_DEVICE_PATH           LpcBridgeDevicePath;\r
+  ACPI_HID_DEVICE_PATH      LpcBusDevicePath;\r
+  EFI_DEVICE_PATH_PROTOCOL  EndDevicePath;\r
+} PARALLEL_CONN_DEVICE_PATH;\r
+\r
+//\r
+// Floopy Connector\r
+//\r
+typedef struct _FLOOPY_CONN_DEVICE_PATH {\r
+  ACPI_HID_DEVICE_PATH      PciRootBridgeDevicePath;\r
+  PCI_DEVICE_PATH           LpcBridgeDevicePath;\r
+  ACPI_HID_DEVICE_PATH      LpcBusDevicePath;\r
+  EFI_DEVICE_PATH_PROTOCOL  EndDevicePath;\r
+} FLOOPY_CONN_DEVICE_PATH;\r
+\r
+typedef union _EFI_MISC_PORT_DEVICE_PATH {\r
+  USB_PORT_DEVICE_PATH      UsbDevicePath;\r
+  IDE_DEVICE_PATH           IdeDevicePath;\r
+  RMC_CONN_DEVICE_PATH      RmcConnDevicePath;\r
+  RIDE_DEVICE_PATH          RideDevicePath;\r
+  GB_NIC_DEVICE_PATH        GbNicDevicePath;\r
+  PS2_CONN_DEVICE_PATH      Ps2ConnDevicePath;\r
+  SERIAL_CONN_DEVICE_PATH   SerialConnDevicePath;\r
+  PARALLEL_CONN_DEVICE_PATH ParallelConnDevicePath;\r
+  FLOOPY_CONN_DEVICE_PATH   FloppyConnDevicePath;\r
+} EFI_MISC_PORT_DEVICE_PATH;\r
+\r
+#pragma pack()\r
+\r
+//\r
+// String Token Definition\r
+//\r
+#define EFI_STRING_TOKEN    UINT16\r
+\r
+typedef struct {\r
+  UINT32    Version;\r
+  UINT32    HeaderSize;\r
+  UINT16    Instance;\r
+  UINT16    SubInstance;\r
+  UINT32    RecordType;\r
+} EFI_SUBCLASS_TYPE1_HEADER;\r
+\r
+typedef struct {\r
+  EFI_GUID    ProducerName;\r
+  UINT16      Instance;\r
+  UINT16      SubInstance;\r
+} EFI_INTER_LINK_DATA;\r
+\r
+\r
+//\r
+// EXP data\r
+//\r
+\r
+typedef struct {\r
+  UINT16    Value;\r
+  UINT16    Exponent;\r
+} EFI_EXP_BASE2_DATA;\r
+\r
+\r
+typedef EFI_EXP_BASE10_DATA   EFI_PROCESSOR_MAX_CORE_FREQUENCY_DATA;\r
+\r
+typedef EFI_EXP_BASE10_DATA   EFI_PROCESSOR_MAX_FSB_FREQUENCY_DATA;\r
+\r
+typedef EFI_EXP_BASE10_DATA   EFI_PROCESSOR_CORE_FREQUENCY_DATA;\r
+\r
+typedef EFI_EXP_BASE10_DATA  *EFI_PROCESSOR_CORE_FREQUENCY_LIST_DATA;\r
+\r
+typedef EFI_EXP_BASE10_DATA  *EFI_PROCESSOR_FSB_FREQUENCY_LIST_DATA;\r
+\r
+typedef EFI_EXP_BASE10_DATA   EFI_PROCESSOR_FSB_FREQUENCY_DATA;\r
+\r
+typedef STRING_REF            EFI_PROCESSOR_VERSION_DATA;\r
+\r
+typedef STRING_REF            EFI_PROCESSOR_MANUFACTURER_DATA;\r
+\r
+typedef STRING_REF            EFI_PROCESSOR_SERIAL_NUMBER_DATA;\r
+\r
+typedef STRING_REF            EFI_PROCESSOR_ASSET_TAG_DATA;\r
+\r
+typedef struct {\r
+  UINT32  ProcessorSteppingId:4;\r
+  UINT32  ProcessorModel:     4;\r
+  UINT32  ProcessorFamily:    4;\r
+  UINT32  ProcessorType:      2;\r
+  UINT32  ProcessorReserved1: 2;\r
+  UINT32  ProcessorXModel:    4;\r
+  UINT32  ProcessorXFamily:   8;\r
+  UINT32  ProcessorReserved2: 4;\r
+} EFI_PROCESSOR_SIGNATURE;\r
+\r
+typedef struct {\r
+  UINT32  ProcessorBrandIndex :8;\r
+  UINT32  ProcessorClflush    :8;\r
+  UINT32  ProcessorReserved   :8;\r
+  UINT32  ProcessorDfltApicId :8;\r
+} EFI_PROCESSOR_MISC_INFO;\r
+\r
+typedef struct {\r
+  UINT32  ProcessorFpu:       1;\r
+  UINT32  ProcessorVme:       1;\r
+  UINT32  ProcessorDe:        1;\r
+  UINT32  ProcessorPse:       1;\r
+  UINT32  ProcessorTsc:       1;\r
+  UINT32  ProcessorMsr:       1;\r
+  UINT32  ProcessorPae:       1;\r
+  UINT32  ProcessorMce:       1;\r
+  UINT32  ProcessorCx8:       1;\r
+  UINT32  ProcessorApic:      1;\r
+  UINT32  ProcessorReserved1: 1;\r
+  UINT32  ProcessorSep:       1;\r
+  UINT32  ProcessorMtrr:      1;\r
+  UINT32  ProcessorPge:       1;\r
+  UINT32  ProcessorMca:       1;\r
+  UINT32  ProcessorCmov:      1;\r
+  UINT32  ProcessorPat:       1;\r
+  UINT32  ProcessorPse36:     1;\r
+  UINT32  ProcessorPsn:       1;\r
+  UINT32  ProcessorClfsh:     1;\r
+  UINT32  ProcessorReserved2: 1;\r
+  UINT32  ProcessorDs:        1;\r
+  UINT32  ProcessorAcpi:      1;\r
+  UINT32  ProcessorMmx:       1;\r
+  UINT32  ProcessorFxsr:      1;\r
+  UINT32  ProcessorSse:       1;\r
+  UINT32  ProcessorSse2:      1;\r
+  UINT32  ProcessorSs:        1;\r
+  UINT32  ProcessorReserved3: 1;\r
+  UINT32  ProcessorTm:        1;\r
+  UINT32  ProcessorReserved4: 2;\r
+} EFI_PROCESSOR_FEATURE_FLAGS;\r
+\r
+typedef struct {\r
+  EFI_PROCESSOR_SIGNATURE     Signature;\r
+  EFI_PROCESSOR_MISC_INFO     MiscInfo;\r
+  UINT32                      Reserved;\r
+  EFI_PROCESSOR_FEATURE_FLAGS FeatureFlags;\r
+} EFI_PROCESSOR_ID_DATA;\r
+\r
+typedef enum {\r
+  EfiProcessorOther    = 1,\r
+  EfiProcessorUnknown  = 2,\r
+  EfiCentralProcessor  = 3,\r
+  EfiMathProcessor     = 4,\r
+  EfiDspProcessor      = 5,\r
+  EfiVideoProcessor    = 6\r
+} EFI_PROCESSOR_TYPE_DATA;\r
+\r
+typedef enum {\r
+  EfiProcessorFamilyOther               = 1,\r
+  EfiProcessorFamilyUnknown             = 2,\r
+  EfiProcessorFamily8086                = 3,\r
+  EfiProcessorFamily80286               = 4,\r
+  EfiProcessorFamilyIntel386            = 5,\r
+  EfiProcessorFamilyIntel486            = 6,\r
+  EfiProcessorFamily8087                = 7,\r
+  EfiProcessorFamily80287               = 8,\r
+  EfiProcessorFamily80387               = 9,\r
+  EfiProcessorFamily80487               = 0x0A,\r
+  EfiProcessorFamilyPentium             = 0x0B,\r
+  EfiProcessorFamilyPentiumPro          = 0x0C,\r
+  EfiProcessorFamilyPentiumII           = 0x0D,\r
+  EfiProcessorFamilyPentiumMMX          = 0x0E,\r
+  EfiProcessorFamilyCeleron             = 0x0F,\r
+  EfiProcessorFamilyPentiumIIXeon       = 0x10,\r
+  EfiProcessorFamilyPentiumIII          = 0x11,\r
+  EfiProcessorFamilyM1                  = 0x12,\r
+  EfiProcessorFamilyM1Reserved1         = 0x13,\r
+  EfiProcessorFamilyM1Reserved2         = 0x14,\r
+  EfiProcessorFamilyM1Reserved3         = 0x15,\r
+  EfiProcessorFamilyM1Reserved4         = 0x16,\r
+  EfiProcessorFamilyM1Reserved5         = 0x17,\r
+  EfiProcessorFamilyM1Reserved6         = 0x18,\r
+  EfiProcessorFamilyK5                  = 0x19,\r
+  EfiProcessorFamilyK5Reserved1         = 0x1A,\r
+  EfiProcessorFamilyK5Reserved2         = 0x1B,\r
+  EfiProcessorFamilyK5Reserved3         = 0x1C,\r
+  EfiProcessorFamilyK5Reserved4         = 0x1D,\r
+  EfiProcessorFamilyK5Reserved5         = 0x1E,\r
+  EfiProcessorFamilyK5Reserved6         = 0x1F,\r
+  EfiProcessorFamilyPowerPC             = 0x20,\r
+  EfiProcessorFamilyPowerPC601          = 0x21,\r
+  EfiProcessorFamilyPowerPC603          = 0x22,\r
+  EfiProcessorFamilyPowerPC603Plus      = 0x23,\r
+  EfiProcessorFamilyPowerPC604          = 0x24,\r
+  EfiProcessorFamilyAlpha2              = 0x30,\r
+  EfiProcessorFamilyMips                = 0x40,\r
+  EfiProcessorFamilySparc               = 0x50,\r
+  EfiProcessorFamily68040               = 0x60,\r
+  EfiProcessorFamily68xxx               = 0x61,\r
+  EfiProcessorFamily68000               = 0x62,\r
+  EfiProcessorFamily68010               = 0x63,\r
+  EfiProcessorFamily68020               = 0x64,\r
+  EfiProcessorFamily68030               = 0x65,\r
+  EfiProcessorFamilyHobbit              = 0x70,\r
+  EfiProcessorFamilyWeitek              = 0x80,\r
+  EfiProcessorFamilyPARISC              = 0x90,\r
+  EfiProcessorFamilyV30                 = 0xA0,\r
+  EfiProcessorFamilyPentiumIIIXeon      = 0xB0,\r
+  EfiProcessorFamilyPentiumIIISpeedStep = 0xB1,\r
+  EfiProcessorFamilyPentium4            = 0xB2,\r
+  EfiProcessorFamilyIntelXeon           = 0xB3,\r
+  EfiProcessorFamilyAS400               = 0xB4,\r
+  EfiProcessorFamilyIntelXeonMP         = 0xB5,\r
+  EfiProcessorFamilyAMDAthlonXP         = 0xB6,\r
+  EfiProcessorFamilyAMDAthlonMP         = 0xB7,\r
+  EfiProcessorFamilyIntelPentiumM       = 0xB9,\r
+  EfiProcessorFamilyIntelCeleronD       = 0xBA,\r
+  EfiProcessorFamilyIntelPentiumD       = 0xBB,\r
+  EfiProcessorFamilyIntelPentiumEx      = 0xBC,\r
+  EfiProcessorFamilyIBM390              = 0xC8,\r
+  EfiProcessorFamilyG4                  = 0xC9,\r
+  EfiProcessorFamilyG5                  = 0xCA,\r
+  EfiProcessorFamilyi860                = 0xFA,\r
+  EfiProcessorFamilyi960                = 0xFB\r
+} EFI_PROCESSOR_FAMILY_DATA;\r
+\r
+typedef EFI_EXP_BASE10_DATA EFI_PROCESSOR_VOLTAGE_DATA;\r
+\r
+typedef EFI_PHYSICAL_ADDRESS EFI_PROCESSOR_APIC_BASE_ADDRESS_DATA;\r
+\r
+typedef UINT32 EFI_PROCESSOR_APIC_ID_DATA;\r
+\r
+typedef UINT32 EFI_PROCESSOR_APIC_VERSION_NUMBER_DATA;\r
+\r
+typedef enum {\r
+  EfiProcessorIa32Microcode    = 1,\r
+  EfiProcessorIpfPalAMicrocode = 2,\r
+  EfiProcessorIpfPalBMicrocode = 3\r
+} EFI_PROCESSOR_MICROCODE_TYPE;\r
+\r
+typedef struct {\r
+  EFI_PROCESSOR_MICROCODE_TYPE  ProcessorMicrocodeType;\r
+  UINT32                        ProcessorMicrocodeRevisionNumber;\r
+} EFI_PROCESSOR_MICROCODE_REVISION_DATA;\r
+\r
+typedef struct {\r
+  UINT32      CpuStatus                 :3;\r
+  UINT32      Reserved1                 :3;\r
+  UINT32      SocketPopulated           :1;\r
+  UINT32      Reserved2                 :1;\r
+  UINT32      ApicEnable                :1;\r
+  UINT32      BootApplicationProcessor  :1;\r
+  UINT32      Reserved3                 :22;\r
+} EFI_PROCESSOR_STATUS_DATA;\r
+\r
+typedef enum {\r
+  EfiCpuStatusUnknown        = 0,\r
+  EfiCpuStatusEnabled        = 1,\r
+  EfiCpuStatusDisabledByUser = 2,\r
+  EfiCpuStatusDisabledbyBios = 3,\r
+  EfiCpuStatusIdle           = 4,\r
+  EfiCpuStatusOther          = 7\r
+} EFI_CPU_STATUS;\r
+\r
+typedef enum {\r
+  EfiProcessorSocketOther            = 1,\r
+  EfiProcessorSocketUnknown          = 2,\r
+  EfiProcessorSocketDaughterBoard    = 3,\r
+  EfiProcessorSocketZIF              = 4,\r
+  EfiProcessorSocketReplacePiggyBack = 5,\r
+  EfiProcessorSocketNone             = 6,\r
+  EfiProcessorSocketLIF              = 7,\r
+  EfiProcessorSocketSlot1            = 8,\r
+  EfiProcessorSocketSlot2            = 9,\r
+  EfiProcessorSocket370Pin           = 0xA,\r
+  EfiProcessorSocketSlotA            = 0xB,\r
+  EfiProcessorSocketSlotM            = 0xC,\r
+  EfiProcessorSocket423              = 0xD,\r
+  EfiProcessorSocketA462             = 0xE,\r
+  EfiProcessorSocket478              = 0xF,\r
+  EfiProcessorSocket754              = 0x10,\r
+  EfiProcessorSocket940              = 0x11,\r
+  EfiProcessorSocket939              = 0x12,\r
+  EfiProcessorSocketmPGA604          = 0x13,\r
+  EfiProcessorSocketLGA771           = 0x14,\r
+  EfiProcessorSocketLGA775           = 0x15\r
+\r
+} EFI_PROCESSOR_SOCKET_TYPE_DATA;\r
+\r
+typedef STRING_REF EFI_PROCESSOR_SOCKET_NAME_DATA;\r
+\r
+typedef EFI_INTER_LINK_DATA EFI_CACHE_ASSOCIATION_DATA;\r
+\r
+typedef enum {\r
+  EfiProcessorHealthy        = 1,\r
+  EfiProcessorPerfRestricted = 2,\r
+  EfiProcessorFuncRestricted = 3\r
+} EFI_PROCESSOR_HEALTH_STATUS;\r
+\r
+typedef UINTN   EFI_PROCESSOR_PACKAGE_NUMBER_DATA;\r
+\r
+\r
+typedef enum {\r
+  ProcessorCoreFrequencyRecordType     = 1,\r
+  ProcessorFsbFrequencyRecordType      = 2,\r
+  ProcessorVersionRecordType           = 3,\r
+  ProcessorManufacturerRecordType      = 4,\r
+  ProcessorSerialNumberRecordType      = 5,\r
+  ProcessorIdRecordType                = 6,\r
+  ProcessorTypeRecordType              = 7,\r
+  ProcessorFamilyRecordType            = 8,\r
+  ProcessorVoltageRecordType           = 9,\r
+  ProcessorApicBaseAddressRecordType   = 10,\r
+  ProcessorApicIdRecordType            = 11,\r
+  ProcessorApicVersionNumberRecordType = 12,\r
+  CpuUcodeRevisionDataRecordType       = 13,\r
+  ProcessorStatusRecordType            = 14,\r
+  ProcessorSocketTypeRecordType        = 15,\r
+  ProcessorSocketNameRecordType        = 16,\r
+  CacheAssociationRecordType           = 17,\r
+  ProcessorMaxCoreFrequencyRecordType  = 18,\r
+  ProcessorAssetTagRecordType          = 19,\r
+  ProcessorMaxFsbFrequencyRecordType   = 20,\r
+  ProcessorPackageNumberRecordType     = 21,\r
+  ProcessorCoreFrequencyListRecordType = 22,\r
+  ProcessorFsbFrequencyListRecordType  = 23,\r
+  ProcessorHealthStatusRecordType      = 24\r
+} EFI_CPU_VARIABLE_RECORD_TYPE;\r
+\r
+typedef union {\r
+  EFI_PROCESSOR_CORE_FREQUENCY_LIST_DATA  ProcessorCoreFrequencyList;\r
+  EFI_PROCESSOR_FSB_FREQUENCY_LIST_DATA   ProcessorFsbFrequencyList;\r
+  EFI_PROCESSOR_SERIAL_NUMBER_DATA        ProcessorSerialNumber;\r
+  EFI_PROCESSOR_CORE_FREQUENCY_DATA       ProcessorCoreFrequency;\r
+  EFI_PROCESSOR_FSB_FREQUENCY_DATA        ProcessorFsbFrequency;\r
+  EFI_PROCESSOR_MAX_CORE_FREQUENCY_DATA   ProcessorMaxCoreFrequency;\r
+  EFI_PROCESSOR_MAX_FSB_FREQUENCY_DATA    ProcessorMaxFsbFrequency;\r
+  EFI_PROCESSOR_VERSION_DATA              ProcessorVersion;\r
+  EFI_PROCESSOR_MANUFACTURER_DATA         ProcessorManufacturer;\r
+  EFI_PROCESSOR_ID_DATA                   ProcessorId;\r
+  EFI_PROCESSOR_TYPE_DATA                 ProcessorType;\r
+  EFI_PROCESSOR_FAMILY_DATA               ProcessorFamily;\r
+  EFI_PROCESSOR_VOLTAGE_DATA              ProcessorVoltage;\r
+  EFI_PROCESSOR_APIC_BASE_ADDRESS_DATA    ProcessorApicBase;\r
+  EFI_PROCESSOR_APIC_ID_DATA              ProcessorApicId;\r
+  EFI_PROCESSOR_APIC_VERSION_NUMBER_DATA  ProcessorApicVersionNumber;\r
+  EFI_PROCESSOR_MICROCODE_REVISION_DATA   CpuUcodeRevisionData;\r
+  EFI_PROCESSOR_STATUS_DATA               ProcessorStatus;\r
+  EFI_PROCESSOR_SOCKET_TYPE_DATA          ProcessorSocketType;\r
+  EFI_PROCESSOR_SOCKET_NAME_DATA          ProcessorSocketName;\r
+  EFI_PROCESSOR_ASSET_TAG_DATA            ProcessorAssetTag;\r
+  EFI_PROCESSOR_HEALTH_STATUS             ProcessorHealthStatus;\r
+  EFI_PROCESSOR_PACKAGE_NUMBER_DATA       ProcessorPackageNumber;\r
+} EFI_CPU_VARIABLE_RECORD;\r
+\r
+typedef struct {\r
+  EFI_SUBCLASS_TYPE1_HEADER      DataRecordHeader;\r
+  EFI_CPU_VARIABLE_RECORD        VariableRecord;\r
+} EFI_CPU_DATA_RECORD;\r
+\r
+#define EFI_CACHE_SUBCLASS_VERSION    0x00010000\r
+\r
+\r
+typedef EFI_EXP_BASE2_DATA  EFI_CACHE_SIZE_DATA;\r
+\r
+typedef EFI_EXP_BASE2_DATA  EFI_MAXIMUM_CACHE_SIZE_DATA;\r
+\r
+typedef EFI_EXP_BASE10_DATA EFI_CACHE_SPEED_DATA;\r
+\r
+typedef STRING_REF          EFI_CACHE_SOCKET_DATA;\r
+\r
+typedef struct {\r
+  UINT32  Other         :1;\r
+  UINT32  Unknown       :1;\r
+  UINT32  NonBurst      :1;\r
+  UINT32  Burst         :1;\r
+  UINT32  PipelineBurst :1;\r
+  UINT32  Asynchronous  :1;\r
+  UINT32  Synchronous   :1;\r
+  UINT32  Reserved      :25;\r
+} EFI_CACHE_SRAM_TYPE_DATA;\r
+\r
+typedef enum {\r
+  EfiCacheErrorOther     = 1,\r
+  EfiCacheErrorUnknown   = 2,\r
+  EfiCacheErrorNone      = 3,\r
+  EfiCacheErrorParity    = 4,\r
+  EfiCacheErrorSingleBit = 5,\r
+  EfiCacheErrorMultiBit  = 6\r
+} EFI_CACHE_ERROR_TYPE_DATA;\r
+\r
+typedef enum {\r
+  EfiCacheTypeOther       = 1,\r
+  EfiCacheTypeUnknown     = 2,\r
+  EfiCacheTypeInstruction = 3,\r
+  EfiCacheTypeData        = 4,\r
+  EfiCacheTypeUnified     = 5\r
+} EFI_CACHE_TYPE_DATA;\r
+\r
+typedef enum {\r
+  EfiCacheAssociativityOther        = 1,\r
+  EfiCacheAssociativityUnknown      = 2,\r
+  EfiCacheAssociativityDirectMapped = 3,\r
+  EfiCacheAssociativity2Way         = 4,\r
+  EfiCacheAssociativity4Way         = 5,\r
+  EfiCacheAssociativityFully        = 6,\r
+  EfiCacheAssociativity8Way         = 7,\r
+  EfiCacheAssociativity16Way        = 8\r
+} EFI_CACHE_ASSOCIATIVITY_DATA;\r
+\r
+typedef struct {\r
+  UINT32    Level           :3;\r
+  UINT32    Socketed        :1;\r
+  UINT32    Reserved2       :1;\r
+  UINT32    Location        :2;\r
+  UINT32    Enable          :1;\r
+  UINT32    OperationalMode :2;\r
+  UINT32    Reserved1       :22;\r
+} EFI_CACHE_CONFIGURATION_DATA;\r
+\r
+#define EFI_CACHE_L1      1\r
+#define EFI_CACHE_L2      2\r
+#define EFI_CACHE_L3      3\r
+#define EFI_CACHE_L4      4\r
+#define EFI_CACHE_LMAX    EFI_CACHE_L4\r
+\r
+#define EFI_CACHE_SOCKETED      1\r
+#define EFI_CACHE_NOT_SOCKETED  0\r
+\r
+typedef enum {\r
+  EfiCacheInternal = 0,\r
+  EfiCacheExternal = 1,\r
+  EfiCacheReserved = 2,\r
+  EfiCacheUnknown  = 3\r
+} EFI_CACHE_LOCATION;\r
+\r
+#define EFI_CACHE_ENABLED    1\r
+#define EFI_CACHE_DISABLED   0\r
+\r
+typedef enum {\r
+  EfiCacheWriteThrough = 0,\r
+  EfiCacheWriteBack    = 1,\r
+  EfiCacheDynamicMode  = 2,\r
+  EfiCacheUnknownMode  = 3\r
+} EFI_CACHE_OPERATIONAL_MODE;\r
+\r
+\r
+\r
+typedef enum {\r
+  CacheSizeRecordType              = 1,\r
+  MaximumSizeCacheRecordType       = 2,\r
+  CacheSpeedRecordType             = 3,\r
+  CacheSocketRecordType            = 4,\r
+  CacheSramTypeRecordType          = 5,\r
+  CacheInstalledSramTypeRecordType = 6,\r
+  CacheErrorTypeRecordType         = 7,\r
+  CacheTypeRecordType              = 8,\r
+  CacheAssociativityRecordType     = 9,\r
+  CacheConfigRecordType            = 10\r
+} EFI_CACHE_VARIABLE_RECORD_TYPE;\r
+\r
+\r
+typedef union {\r
+  EFI_CACHE_SIZE_DATA             CacheSize;\r
+  EFI_MAXIMUM_CACHE_SIZE_DATA     MaximumCacheSize;\r
+  EFI_CACHE_SPEED_DATA            CacheSpeed;\r
+  EFI_CACHE_SOCKET_DATA           CacheSocket;\r
+  EFI_CACHE_SRAM_TYPE_DATA        CacheSramType;\r
+  EFI_CACHE_SRAM_TYPE_DATA        CacheInstalledSramType;\r
+  EFI_CACHE_ERROR_TYPE_DATA       CacheErrorType;\r
+  EFI_CACHE_TYPE_DATA             CacheType;\r
+  EFI_CACHE_ASSOCIATIVITY_DATA    CacheAssociativity;\r
+  EFI_CACHE_CONFIGURATION_DATA    CacheConfig;\r
+  EFI_CACHE_ASSOCIATION_DATA      CacheAssociation;\r
+} EFI_CACHE_VARIABLE_RECORD;\r
+\r
+typedef struct {\r
+   EFI_SUBCLASS_TYPE1_HEADER      DataRecordHeader;\r
+   EFI_CACHE_VARIABLE_RECORD      VariableRecord;\r
+} EFI_CACHE_DATA_RECORD;\r
+\r
+#define EFI_MEMORY_SUBCLASS_VERSION     0x0100\r
+\r
+\r
+#define EFI_MEMORY_SIZE_RECORD_NUMBER                 0x00000001\r
+\r
+typedef enum _EFI_MEMORY_REGION_TYPE {\r
+  EfiMemoryRegionMemory                       = 0x01,\r
+  EfiMemoryRegionReserved                     = 0x02,\r
+  EfiMemoryRegionAcpi                         = 0x03,\r
+  EfiMemoryRegionNvs                          = 0x04\r
+} EFI_MEMORY_REGION_TYPE;\r
+\r
+typedef struct {\r
+  UINT32                      ProcessorNumber;\r
+  UINT16                      StartBusNumber;\r
+  UINT16                      EndBusNumber;\r
+  EFI_MEMORY_REGION_TYPE      MemoryRegionType;\r
+  EFI_EXP_BASE2_DATA          MemorySize;\r
+  EFI_PHYSICAL_ADDRESS        MemoryStartAddress;\r
+} EFI_MEMORY_SIZE_DATA;\r
+\r
+\r
+#define EFI_MEMORY_ARRAY_LOCATION_RECORD_NUMBER       0x00000002\r
+\r
+typedef enum _EFI_MEMORY_ARRAY_LOCATION {\r
+  EfiMemoryArrayLocationOther                 = 0x01,\r
+  EfiMemoryArrayLocationUnknown               = 0x02,\r
+  EfiMemoryArrayLocationSystemBoard           = 0x03,\r
+  EfiMemoryArrayLocationIsaAddonCard          = 0x04,\r
+  EfiMemoryArrayLocationEisaAddonCard         = 0x05,\r
+  EfiMemoryArrayLocationPciAddonCard          = 0x06,\r
+  EfiMemoryArrayLocationMcaAddonCard          = 0x07,\r
+  EfiMemoryArrayLocationPcmciaAddonCard       = 0x08,\r
+  EfiMemoryArrayLocationProprietaryAddonCard  = 0x09,\r
+  EfiMemoryArrayLocationNuBus                 = 0x0A,\r
+  EfiMemoryArrayLocationPc98C20AddonCard      = 0xA0,\r
+  EfiMemoryArrayLocationPc98C24AddonCard      = 0xA1,\r
+  EfiMemoryArrayLocationPc98EAddonCard        = 0xA2,\r
+  EfiMemoryArrayLocationPc98LocalBusAddonCard = 0xA3\r
+} EFI_MEMORY_ARRAY_LOCATION;\r
+\r
+typedef enum _EFI_MEMORY_ARRAY_USE {\r
+  EfiMemoryArrayUseOther                      = 0x01,\r
+  EfiMemoryArrayUseUnknown                    = 0x02,\r
+  EfiMemoryArrayUseSystemMemory               = 0x03,\r
+  EfiMemoryArrayUseVideoMemory                = 0x04,\r
+  EfiMemoryArrayUseFlashMemory                = 0x05,\r
+  EfiMemoryArrayUseNonVolatileRam             = 0x06,\r
+  EfiMemoryArrayUseCacheMemory                = 0x07,\r
+} EFI_MEMORY_ARRAY_USE;\r
+\r
+typedef enum _EFI_MEMORY_ERROR_CORRECTION {\r
+  EfiMemoryErrorCorrectionOther               = 0x01,\r
+  EfiMemoryErrorCorrectionUnknown             = 0x02,\r
+  EfiMemoryErrorCorrectionNone                = 0x03,\r
+  EfiMemoryErrorCorrectionParity              = 0x04,\r
+  EfiMemoryErrorCorrectionSingleBitEcc        = 0x05,\r
+  EfiMemoryErrorCorrectionMultiBitEcc         = 0x06,\r
+  EfiMemoryErrorCorrectionCrc                 = 0x07,\r
+} EFI_MEMORY_ERROR_CORRECTION;\r
+\r
+typedef struct {\r
+  EFI_MEMORY_ARRAY_LOCATION   MemoryArrayLocation;\r
+  EFI_MEMORY_ARRAY_USE        MemoryArrayUse;\r
+  EFI_MEMORY_ERROR_CORRECTION MemoryErrorCorrection;\r
+  EFI_EXP_BASE2_DATA          MaximumMemoryCapacity;\r
+  UINT16                      NumberMemoryDevices;\r
+} EFI_MEMORY_ARRAY_LOCATION_DATA;\r
+\r
+\r
+#define EFI_MEMORY_ARRAY_LINK_RECORD_NUMBER           0x00000003\r
+\r
+typedef enum _EFI_MEMORY_FORM_FACTOR {\r
+  EfiMemoryFormFactorOther                    = 0x01,\r
+  EfiMemoryFormFactorUnknown                  = 0x02,\r
+  EfiMemoryFormFactorSimm                     = 0x03,\r
+  EfiMemoryFormFactorSip                      = 0x04,\r
+  EfiMemoryFormFactorChip                     = 0x05,\r
+  EfiMemoryFormFactorDip                      = 0x06,\r
+  EfiMemoryFormFactorZip                      = 0x07,\r
+  EfiMemoryFormFactorProprietaryCard          = 0x08,\r
+  EfiMemoryFormFactorDimm                     = 0x09,\r
+  EfiMemoryFormFactorTsop                     = 0x0A,\r
+  EfiMemoryFormFactorRowOfChips               = 0x0B,\r
+  EfiMemoryFormFactorRimm                     = 0x0C,\r
+  EfiMemoryFormFactorSodimm                   = 0x0D,\r
+  EfiMemoryFormFactorSrimm                    = 0x0E,\r
+  EfiMemoryFormFactorFbDimm                   = 0x0F\r
+} EFI_MEMORY_FORM_FACTOR;\r
+\r
+typedef enum _EFI_MEMORY_ARRAY_TYPE {\r
+  EfiMemoryTypeOther                          = 0x01,\r
+  EfiMemoryTypeUnknown                        = 0x02,\r
+  EfiMemoryTypeDram                           = 0x03,\r
+  EfiMemoryTypeEdram                          = 0x04,\r
+  EfiMemoryTypeVram                           = 0x05,\r
+  EfiMemoryTypeSram                           = 0x06,\r
+  EfiMemoryTypeRam                            = 0x07,\r
+  EfiMemoryTypeRom                            = 0x08,\r
+  EfiMemoryTypeFlash                          = 0x09,\r
+  EfiMemoryTypeEeprom                         = 0x0A,\r
+  EfiMemoryTypeFeprom                         = 0x0B,\r
+  EfiMemoryTypeEprom                          = 0x0C,\r
+  EfiMemoryTypeCdram                          = 0x0D,\r
+  EfiMemoryType3Dram                          = 0x0E,\r
+  EfiMemoryTypeSdram                          = 0x0F,\r
+  EfiMemoryTypeSgram                          = 0x10,\r
+  EfiMemoryTypeRdram                          = 0x11,\r
+  EfiMemoryTypeDdr                            = 0x12,\r
+  EfiMemoryTypeDdr2                           = 0x13,\r
+  EfiMemoryTypeDdr2FbDimm                     = 0x14\r
+} EFI_MEMORY_ARRAY_TYPE;\r
+\r
+typedef struct {\r
+  UINT32                      Reserved        :1;\r
+  UINT32                      Other           :1;\r
+  UINT32                      Unknown         :1;\r
+  UINT32                      FastPaged       :1;\r
+  UINT32                      StaticColumn    :1;\r
+  UINT32                      PseudoStatic    :1;\r
+  UINT32                      Rambus          :1;\r
+  UINT32                      Synchronous     :1;\r
+  UINT32                      Cmos            :1;\r
+  UINT32                      Edo             :1;\r
+  UINT32                      WindowDram      :1;\r
+  UINT32                      CacheDram       :1;\r
+  UINT32                      Nonvolatile     :1;\r
+  UINT32                      Reserved1       :19;\r
+} EFI_MEMORY_TYPE_DETAIL;\r
+\r
+typedef enum {\r
+  EfiMemoryStateEnabled      = 0,\r
+  EfiMemoryStateUnknown      = 1,\r
+  EfiMemoryStateUnsupported  = 2,\r
+  EfiMemoryStateError        = 3,\r
+  EfiMemoryStateAbsent       = 4,\r
+  EfiMemoryStateDisabled     = 5,\r
+  EfiMemoryStatePartial      = 6\r
+} EFI_MEMORY_STATE;\r
+\r
+typedef struct {\r
+  STRING_REF                  MemoryDeviceLocator;\r
+  STRING_REF                  MemoryBankLocator;\r
+  STRING_REF                  MemoryManufacturer;\r
+  STRING_REF                  MemorySerialNumber;\r
+  STRING_REF                  MemoryAssetTag;\r
+  STRING_REF                  MemoryPartNumber;\r
+  EFI_INTER_LINK_DATA         MemoryArrayLink;\r
+  EFI_INTER_LINK_DATA         MemorySubArrayLink;\r
+  UINT16                      MemoryTotalWidth;\r
+  UINT16                      MemoryDataWidth;\r
+  EFI_EXP_BASE2_DATA          MemoryDeviceSize;\r
+  EFI_MEMORY_FORM_FACTOR      MemoryFormFactor;\r
+  UINT8                       MemoryDeviceSet;\r
+  EFI_MEMORY_ARRAY_TYPE       MemoryType;\r
+  EFI_MEMORY_TYPE_DETAIL      MemoryTypeDetail;\r
+  EFI_EXP_BASE10_DATA         MemorySpeed;\r
+  EFI_MEMORY_STATE            MemoryState;\r
+} EFI_MEMORY_ARRAY_LINK_DATA;\r
+\r
+\r
+#define EFI_MEMORY_ARRAY_START_ADDRESS_RECORD_NUMBER  0x00000004\r
+\r
+typedef struct {\r
+  EFI_PHYSICAL_ADDRESS        MemoryArrayStartAddress;\r
+  EFI_PHYSICAL_ADDRESS        MemoryArrayEndAddress;\r
+  EFI_INTER_LINK_DATA         PhysicalMemoryArrayLink;\r
+  UINT16                      MemoryArrayPartitionWidth;\r
+} EFI_MEMORY_ARRAY_START_ADDRESS_DATA;\r
+\r
+\r
+#define EFI_MEMORY_DEVICE_START_ADDRESS_RECORD_NUMBER 0x00000005\r
+\r
+typedef struct {\r
+  EFI_PHYSICAL_ADDRESS        MemoryDeviceStartAddress;\r
+  EFI_PHYSICAL_ADDRESS        MemoryDeviceEndAddress;\r
+  EFI_INTER_LINK_DATA         PhysicalMemoryDeviceLink;\r
+  EFI_INTER_LINK_DATA         PhysicalMemoryArrayLink;\r
+  UINT8                       MemoryDevicePartitionRowPosition;\r
+  UINT8                       MemoryDeviceInterleavePosition;\r
+  UINT8                       MemoryDeviceInterleaveDataDepth;\r
+} EFI_MEMORY_DEVICE_START_ADDRESS_DATA;\r
+\r
+\r
+//\r
+//  Memory. Channel Device Type -  SMBIOS Type 37\r
+//\r
+\r
+#define EFI_MEMORY_CHANNEL_TYPE_RECORD_NUMBER         0x00000006\r
+\r
+typedef enum _EFI_MEMORY_CHANNEL_TYPE {\r
+  EfiMemoryChannelTypeOther                   = 1,\r
+  EfiMemoryChannelTypeUnknown                 = 2,\r
+  EfiMemoryChannelTypeRambus                  = 3,\r
+  EfiMemoryChannelTypeSyncLink                = 4\r
+} EFI_MEMORY_CHANNEL_TYPE;\r
+\r
+typedef struct {\r
+  EFI_MEMORY_CHANNEL_TYPE     MemoryChannelType;\r
+  UINT8                       MemoryChannelMaximumLoad;\r
+  UINT8                       MemoryChannelDeviceCount;\r
+} EFI_MEMORY_CHANNEL_TYPE_DATA;\r
+\r
+#define EFI_MEMORY_CHANNEL_DEVICE_RECORD_NUMBER       0x00000007\r
+\r
+typedef struct {\r
+  UINT8                       DeviceId;\r
+  EFI_INTER_LINK_DATA         DeviceLink;\r
+  UINT8                       MemoryChannelDeviceLoad;\r
+} EFI_MEMORY_CHANNEL_DEVICE_DATA;\r
+\r
+\r
+\r
+typedef union _EFI_MEMORY_SUBCLASS_RECORDS {\r
+  EFI_MEMORY_SIZE_DATA                  SizeData;\r
+  EFI_MEMORY_ARRAY_LOCATION_DATA        ArrayLocationData;\r
+  EFI_MEMORY_ARRAY_LINK_DATA            ArrayLink;\r
+  EFI_MEMORY_ARRAY_START_ADDRESS_DATA   ArrayStartAddress;\r
+  EFI_MEMORY_DEVICE_START_ADDRESS_DATA  DeviceStartAddress;\r
+  EFI_MEMORY_CHANNEL_TYPE_DATA          ChannelTypeData;\r
+  EFI_MEMORY_CHANNEL_DEVICE_DATA        ChannelDeviceData;\r
+} EFI_MEMORY_SUBCLASS_RECORDS;\r
+\r
+typedef struct {\r
+  EFI_SUBCLASS_TYPE1_HEADER             Header;\r
+  EFI_MEMORY_SUBCLASS_RECORDS           Record;\r
+} EFI_MEMORY_SUBCLASS_DRIVER_DATA;\r
+\r
+#define EFI_MISC_SUBCLASS_VERSION     0x0100\r
+\r
+#pragma pack(1)\r
+//\r
+//////////////////////////////////////////////////////////////////////////////\r
+//\r
+// Last PCI Bus Number\r
+//\r
+#define EFI_MISC_LAST_PCI_BUS_RECORD_NUMBER  0x00000001\r
+\r
+typedef struct {\r
+  UINT8   LastPciBus;\r
+} EFI_MISC_LAST_PCI_BUS_DATA;\r
+\r
+//\r
+//////////////////////////////////////////////////////////////////////////////\r
+//\r
+// Misc. BIOS Vendor - SMBIOS Type 0\r
+//\r
+#define EFI_MISC_BIOS_VENDOR_RECORD_NUMBER  0x00000002\r
+\r
+typedef struct {\r
+  UINT64  Reserved1                         :2;\r
+  UINT64  Unknown                           :1;\r
+  UINT64  BiosCharacteristicsNotSupported   :1;\r
+  UINT64  IsaIsSupported                    :1;\r
+  UINT64  McaIsSupported                    :1;\r
+  UINT64  EisaIsSupported                   :1;\r
+  UINT64  PciIsSupported                    :1;\r
+  UINT64  PcmciaIsSupported                 :1;\r
+  UINT64  PlugAndPlayIsSupported            :1;\r
+  UINT64  ApmIsSupported                    :1;\r
+  UINT64  BiosIsUpgradable                  :1;\r
+  UINT64  BiosShadowingAllowed              :1;\r
+  UINT64  VlVesaIsSupported                 :1;\r
+  UINT64  EscdSupportIsAvailable            :1;\r
+  UINT64  BootFromCdIsSupported             :1;\r
+  UINT64  SelectableBootIsSupported         :1;\r
+  UINT64  RomBiosIsSocketed                 :1;\r
+  UINT64  BootFromPcmciaIsSupported         :1;\r
+  UINT64  EDDSpecificationIsSupported       :1;\r
+  UINT64  JapaneseNecFloppyIsSupported      :1;\r
+  UINT64  JapaneseToshibaFloppyIsSupported  :1;\r
+  UINT64  Floppy525_360IsSupported          :1;\r
+  UINT64  Floppy525_12IsSupported           :1;\r
+  UINT64  Floppy35_720IsSupported           :1;\r
+  UINT64  Floppy35_288IsSupported           :1;\r
+  UINT64  PrintScreenIsSupported            :1;\r
+  UINT64  Keyboard8042IsSupported           :1;\r
+  UINT64  SerialIsSupported                 :1;\r
+  UINT64  PrinterIsSupported                :1;\r
+  UINT64  CgaMonoIsSupported                :1;\r
+  UINT64  NecPc98                           :1;\r
+  UINT64  AcpiIsSupported                   :1;\r
+  UINT64  UsbLegacyIsSupported              :1;\r
+  UINT64  AgpIsSupported                    :1;\r
+  UINT64  I20BootIsSupported                :1;\r
+  UINT64  Ls120BootIsSupported              :1;\r
+  UINT64  AtapiZipDriveBootIsSupported      :1;\r
+  UINT64  Boot1394IsSupported               :1;\r
+  UINT64  SmartBatteryIsSupported           :1;\r
+  UINT64  BiosBootSpecIsSupported           :1;\r
+  UINT64  FunctionKeyNetworkBootIsSupported :1;\r
+  UINT64  Reserved                          :22;\r
+} EFI_MISC_BIOS_CHARACTERISTICS;\r
+\r
+typedef struct {\r
+  UINT64  BiosReserved                      :16;\r
+  UINT64  SystemReserved                    :16;\r
+  UINT64  Reserved                          :32;\r
+} EFI_MISC_BIOS_CHARACTERISTICS_EXTENSION;\r
+\r
+typedef struct {\r
+  STRING_REF                      BiosVendor;\r
+  STRING_REF                      BiosVersion;\r
+  STRING_REF                      BiosReleaseDate;\r
+  EFI_PHYSICAL_ADDRESS            BiosStartingAddress;\r
+  EFI_EXP_BASE2_DATA              BiosPhysicalDeviceSize;\r
+  EFI_MISC_BIOS_CHARACTERISTICS   BiosCharacteristics1;\r
+  EFI_MISC_BIOS_CHARACTERISTICS_EXTENSION  BiosCharacteristics2;\r
+  UINT8                           BiosMajorRelease;\r
+  UINT8                           BiosMinorRelease;\r
+  UINT8                           BiosEmbeddedFirmwareMajorRelease;\r
+  UINT8                           BiosEmbeddedFirmwareMinorRelease;\r
+} EFI_MISC_BIOS_VENDOR_DATA;\r
+\r
+//\r
+//////////////////////////////////////////////////////////////////////////////\r
+//\r
+// Misc. System Manufacturer - SMBIOS Type 1\r
+//\r
+#define EFI_MISC_SYSTEM_MANUFACTURER_RECORD_NUMBER 0x00000003\r
+\r
+typedef enum {\r
+  EfiSystemWakeupTypeReserved        = 0,\r
+  EfiSystemWakeupTypeOther           = 1,\r
+  EfiSystemWakeupTypeUnknown         = 2,\r
+  EfiSystemWakeupTypeApmTimer        = 3,\r
+  EfiSystemWakeupTypeModemRing       = 4,\r
+  EfiSystemWakeupTypeLanRemote       = 5,\r
+  EfiSystemWakeupTypePowerSwitch     = 6,\r
+  EfiSystemWakeupTypePciPme          = 7,\r
+  EfiSystemWakeupTypeAcPowerRestored = 8,\r
+} EFI_MISC_SYSTEM_WAKEUP_TYPE;\r
+\r
+typedef struct {\r
+  STRING_REF                      SystemManufacturer;\r
+  STRING_REF                      SystemProductName;\r
+  STRING_REF                      SystemVersion;\r
+  STRING_REF                      SystemSerialNumber;\r
+  EFI_GUID                        SystemUuid;\r
+  EFI_MISC_SYSTEM_WAKEUP_TYPE     SystemWakeupType;\r
+  STRING_REF                      SystemSKUNumber;\r
+  STRING_REF                      SystemFamily;\r
+} EFI_MISC_SYSTEM_MANUFACTURER_DATA;\r
+\r
+//\r
+//////////////////////////////////////////////////////////////////////////////\r
+//\r
+// Misc. Base Board Manufacturer - SMBIOS Type 2\r
+//\r
+#define EFI_MISC_BASE_BOARD_MANUFACTURER_RECORD_NUMBER 0x00000004\r
+\r
+typedef struct {\r
+  UINT32  Motherboard           :1;\r
+  UINT32  RequiresDaughterCard  :1;\r
+  UINT32  Removable             :1;\r
+  UINT32  Replaceable           :1;\r
+  UINT32  HotSwappable          :1;\r
+  UINT32  Reserved              :27;\r
+} EFI_BASE_BOARD_FEATURE_FLAGS;\r
+\r
+typedef enum {\r
+  EfiBaseBoardTypeUnknown                = 1,\r
+  EfiBaseBoardTypeOther                  = 2,\r
+  EfiBaseBoardTypeServerBlade            = 3,\r
+  EfiBaseBoardTypeConnectivitySwitch     = 4,\r
+  EfiBaseBoardTypeSystemManagementModule = 5,\r
+  EfiBaseBoardTypeProcessorModule        = 6,\r
+  EfiBaseBoardTypeIOModule               = 7,\r
+  EfiBaseBoardTypeMemoryModule           = 8,\r
+  EfiBaseBoardTypeDaughterBoard          = 9,\r
+  EfiBaseBoardTypeMotherBoard            = 0xA,\r
+  EfiBaseBoardTypeProcessorMemoryModule  = 0xB,\r
+  EfiBaseBoardTypeProcessorIOModule      = 0xC,\r
+  EfiBaseBoardTypeInterconnectBoard      = 0xD,\r
+} EFI_BASE_BOARD_TYPE;\r
+\r
+typedef struct {\r
+  STRING_REF                      BaseBoardManufacturer;\r
+  STRING_REF                      BaseBoardProductName;\r
+  STRING_REF                      BaseBoardVersion;\r
+  STRING_REF                      BaseBoardSerialNumber;\r
+  STRING_REF                      BaseBoardAssetTag;\r
+  STRING_REF                      BaseBoardChassisLocation;\r
+  EFI_BASE_BOARD_FEATURE_FLAGS    BaseBoardFeatureFlags;\r
+  EFI_BASE_BOARD_TYPE             BaseBoardType;\r
+  EFI_INTER_LINK_DATA             BaseBoardChassisLink;\r
+  UINT32                          BaseBoardNumberLinks;\r
+  EFI_INTER_LINK_DATA             LinkN;\r
+} EFI_MISC_BASE_BOARD_MANUFACTURER_DATA;\r
+\r
+//\r
+//////////////////////////////////////////////////////////////////////////////\r
+//\r
+// Misc. System/Chassis Enclosure - SMBIOS Type 3\r
+//\r
+#define EFI_MISC_CHASSIS_MANUFACTURER_RECORD_NUMBER  0x00000005\r
+\r
+typedef enum {\r
+  EfiMiscChassisTypeOther               = 0x1,\r
+  EfiMiscChassisTypeUnknown             = 0x2,\r
+  EfiMiscChassisTypeDeskTop             = 0x3,\r
+  EfiMiscChassisTypeLowProfileDesktop   = 0x4,\r
+  EfiMiscChassisTypePizzaBox            = 0x5,\r
+  EfiMiscChassisTypeMiniTower           = 0x6,\r
+  EfiMiscChassisTypeTower               = 0x7,\r
+  EfiMiscChassisTypePortable            = 0x8,\r
+  EfiMiscChassisTypeLapTop              = 0x9,\r
+  EfiMiscChassisTypeNotebook            = 0xA,\r
+  EfiMiscChassisTypeHandHeld            = 0xB,\r
+  EfiMiscChassisTypeDockingStation      = 0xC,\r
+  EfiMiscChassisTypeAllInOne            = 0xD,\r
+  EfiMiscChassisTypeSubNotebook         = 0xE,\r
+  EfiMiscChassisTypeSpaceSaving         = 0xF,\r
+  EfiMiscChassisTypeLunchBox            = 0x10,\r
+  EfiMiscChassisTypeMainServerChassis   = 0x11,\r
+  EfiMiscChassisTypeExpansionChassis    = 0x12,\r
+  EfiMiscChassisTypeSubChassis          = 0x13,\r
+  EfiMiscChassisTypeBusExpansionChassis = 0x14,\r
+  EfiMiscChassisTypePeripheralChassis   = 0x15,\r
+  EfiMiscChassisTypeRaidChassis         = 0x16,\r
+  EfiMiscChassisTypeRackMountChassis    = 0x17,\r
+  EfiMiscChassisTypeSealedCasePc        = 0x18,\r
+  EfiMiscChassisMultiSystemChassis      = 0x19,\r
+} EFI_MISC_CHASSIS_TYPE;\r
+\r
+typedef struct {\r
+  UINT32  ChassisType       :16;\r
+  UINT32  ChassisLockPresent:1;\r
+  UINT32  Reserved          :15;\r
+} EFI_MISC_CHASSIS_STATUS;\r
+\r
+typedef enum {\r
+  EfiChassisStateOther           = 0x01,\r
+  EfiChassisStateUnknown         = 0x02,\r
+  EfiChassisStateSafe            = 0x03,\r
+  EfiChassisStateWarning         = 0x04,\r
+  EfiChassisStateCritical        = 0x05,\r
+  EfiChassisStateNonRecoverable  = 0x06,\r
+} EFI_MISC_CHASSIS_STATE;\r
+\r
+typedef enum {\r
+  EfiChassisSecurityStatusOther                          = 0x01,\r
+  EfiChassisSecurityStatusUnknown                        = 0x02,\r
+  EfiChassisSecurityStatusNone                           = 0x03,\r
+  EfiChassisSecurityStatusExternalInterfaceLockedOut     = 0x04,\r
+  EfiChassisSecurityStatusExternalInterfaceLockedEnabled = 0x05,\r
+} EFI_MISC_CHASSIS_SECURITY_STATE;\r
+\r
+typedef struct {\r
+  UINT32  RecordType  :1;\r
+  UINT32  Reserved    :24;\r
+} EFI_MISC_ELEMENT_TYPE;\r
+\r
+typedef struct {\r
+  EFI_MISC_ELEMENT_TYPE   ChassisElementType;\r
+  EFI_INTER_LINK_DATA     ChassisElementStructure;\r
+  EFI_BASE_BOARD_TYPE     ChassisBaseBoard;\r
+  UINT32                  ChassisElementMinimum;\r
+  UINT32                  ChassisElementMaximum;\r
+} EFI_MISC_ELEMENTS;\r
+\r
+typedef struct {\r
+  STRING_REF                      ChassisManufacturer;\r
+  STRING_REF                      ChassisVersion;\r
+  STRING_REF                      ChassisSerialNumber;\r
+  STRING_REF                      ChassisAssetTag;\r
+  EFI_MISC_CHASSIS_STATUS         ChassisType;\r
+  EFI_MISC_CHASSIS_STATE          ChassisBootupState;\r
+  EFI_MISC_CHASSIS_STATE          ChassisPowerSupplyState;\r
+  EFI_MISC_CHASSIS_STATE          ChassisThermalState;\r
+  EFI_MISC_CHASSIS_SECURITY_STATE ChassisSecurityState;\r
+  UINT32                          ChassisOemDefined;\r
+  UINT32                          ChassisHeight;\r
+  UINT32                          ChassisNumberPowerCords;\r
+  UINT32                          ChassisElementCount;\r
+  UINT32                          ChassisElementRecordLength;//\r
+  EFI_MISC_ELEMENTS               ChassisElements;\r
+} EFI_MISC_CHASSIS_MANUFACTURER_DATA;\r
+\r
+//\r
+//////////////////////////////////////////////////////////////////////////////\r
+//\r
+// Misc. Port Connector Information - SMBIOS Type 8\r
+//\r
+#define EFI_MISC_PORT_INTERNAL_CONNECTOR_DESIGNATOR_RECORD_NUMBER 0x00000006\r
+\r
+typedef enum {\r
+  EfiPortConnectorTypeNone                   = 0x00,\r
+  EfiPortConnectorTypeCentronics             = 0x01,\r
+  EfiPortConnectorTypeMiniCentronics         = 0x02,\r
+  EfiPortConnectorTypeProprietary            = 0x03,\r
+  EfiPortConnectorTypeDB25Male               = 0x04,\r
+  EfiPortConnectorTypeDB25Female             = 0x05,\r
+  EfiPortConnectorTypeDB15Male               = 0x06,\r
+  EfiPortConnectorTypeDB15Female             = 0x07,\r
+  EfiPortConnectorTypeDB9Male                = 0x08,\r
+  EfiPortConnectorTypeDB9Female              = 0x09,\r
+  EfiPortConnectorTypeRJ11                   = 0x0A,\r
+  EfiPortConnectorTypeRJ45                   = 0x0B,\r
+  EfiPortConnectorType50PinMiniScsi          = 0x0C,\r
+  EfiPortConnectorTypeMiniDin                = 0x0D,\r
+  EfiPortConnectorTypeMicriDin               = 0x0E,\r
+  EfiPortConnectorTypePS2                    = 0x0F,\r
+  EfiPortConnectorTypeInfrared               = 0x10,\r
+  EfiPortConnectorTypeHpHil                  = 0x11,\r
+  EfiPortConnectorTypeUsb                    = 0x12,\r
+  EfiPortConnectorTypeSsaScsi                = 0x13,\r
+  EfiPortConnectorTypeCircularDin8Male       = 0x14,\r
+  EfiPortConnectorTypeCircularDin8Female     = 0x15,\r
+  EfiPortConnectorTypeOnboardIde             = 0x16,\r
+  EfiPortConnectorTypeOnboardFloppy          = 0x17,\r
+  EfiPortConnectorType9PinDualInline         = 0x18,\r
+  EfiPortConnectorType25PinDualInline        = 0x19,\r
+  EfiPortConnectorType50PinDualInline        = 0x1A,\r
+  EfiPortConnectorType68PinDualInline        = 0x1B,\r
+  EfiPortConnectorTypeOnboardSoundInput      = 0x1C,\r
+  EfiPortConnectorTypeMiniCentronicsType14   = 0x1D,\r
+  EfiPortConnectorTypeMiniCentronicsType26   = 0x1E,\r
+  EfiPortConnectorTypeHeadPhoneMiniJack      = 0x1F,\r
+  EfiPortConnectorTypeBNC                    = 0x20,\r
+  EfiPortConnectorType1394                   = 0x21,\r
+  EfiPortConnectorTypePC98                   = 0xA0,\r
+  EfiPortConnectorTypePC98Hireso             = 0xA1,\r
+  EfiPortConnectorTypePCH98                  = 0xA2,\r
+  EfiPortConnectorTypePC98Note               = 0xA3,\r
+  EfiPortConnectorTypePC98Full               = 0xA4,\r
+  EfiPortConnectorTypeOther                  = 0xFF,\r
+} EFI_MISC_PORT_CONNECTOR_TYPE;\r
+\r
+typedef enum {\r
+  EfiPortTypeNone                      = 0x00,\r
+  EfiPortTypeParallelXtAtCompatible    = 0x01,\r
+  EfiPortTypeParallelPortPs2           = 0x02,\r
+  EfiPortTypeParallelPortEcp           = 0x03,\r
+  EfiPortTypeParallelPortEpp           = 0x04,\r
+  EfiPortTypeParallelPortEcpEpp        = 0x05,\r
+  EfiPortTypeSerialXtAtCompatible      = 0x06,\r
+  EfiPortTypeSerial16450Compatible     = 0x07,\r
+  EfiPortTypeSerial16550Compatible     = 0x08,\r
+  EfiPortTypeSerial16550ACompatible    = 0x09,\r
+  EfiPortTypeScsi                      = 0x0A,\r
+  EfiPortTypeMidi                      = 0x0B,\r
+  EfiPortTypeJoyStick                  = 0x0C,\r
+  EfiPortTypeKeyboard                  = 0x0D,\r
+  EfiPortTypeMouse                     = 0x0E,\r
+  EfiPortTypeSsaScsi                   = 0x0F,\r
+  EfiPortTypeUsb                       = 0x10,\r
+  EfiPortTypeFireWire                  = 0x11,\r
+  EfiPortTypePcmciaTypeI               = 0x12,\r
+  EfiPortTypePcmciaTypeII              = 0x13,\r
+  EfiPortTypePcmciaTypeIII             = 0x14,\r
+  EfiPortTypeCardBus                   = 0x15,\r
+  EfiPortTypeAccessBusPort             = 0x16,\r
+  EfiPortTypeScsiII                    = 0x17,\r
+  EfiPortTypeScsiWide                  = 0x18,\r
+  EfiPortTypePC98                      = 0x19,\r
+  EfiPortTypePC98Hireso                = 0x1A,\r
+  EfiPortTypePCH98                     = 0x1B,\r
+  EfiPortTypeVideoPort                 = 0x1C,\r
+  EfiPortTypeAudioPort                 = 0x1D,\r
+  EfiPortTypeModemPort                 = 0x1E,\r
+  EfiPortTypeNetworkPort               = 0x1F,\r
+  EfiPortType8251Compatible            = 0xA0,\r
+  EfiPortType8251FifoCompatible        = 0xA1,\r
+  EfiPortTypeOther                     = 0xFF,\r
+} EFI_MISC_PORT_TYPE;\r
+\r
+typedef struct {\r
+  STRING_REF                    PortInternalConnectorDesignator;\r
+  STRING_REF                    PortExternalConnectorDesignator;\r
+  EFI_MISC_PORT_CONNECTOR_TYPE  PortInternalConnectorType;\r
+  EFI_MISC_PORT_CONNECTOR_TYPE  PortExternalConnectorType;\r
+  EFI_MISC_PORT_TYPE            PortType;\r
+  EFI_MISC_PORT_DEVICE_PATH     PortPath;\r
+} EFI_MISC_PORT_INTERNAL_CONNECTOR_DESIGNATOR_DATA;\r
+\r
+//\r
+//////////////////////////////////////////////////////////////////////////////\r
+//\r
+// Misc. System Slots - SMBIOS Type 9\r
+//\r
+#define EFI_MISC_SYSTEM_SLOT_DESIGNATION_RECORD_NUMBER 0x00000007\r
+\r
+typedef enum {\r
+  EfiSlotTypeOther                        = 0x01,\r
+  EfiSlotTypeUnknown                      = 0x02,\r
+  EfiSlotTypeIsa                          = 0x03,\r
+  EfiSlotTypeMca                          = 0x04,\r
+  EfiSlotTypeEisa                         = 0x05,\r
+  EfiSlotTypePci                          = 0x06,\r
+  EfiSlotTypePcmcia                       = 0x07,\r
+  EfiSlotTypeVlVesa                       = 0x08,\r
+  EfiSlotTypeProprietary                  = 0x09,\r
+  EfiSlotTypeProcessorCardSlot            = 0x0A,\r
+  EfiSlotTypeProprietaryMemoryCardSlot    = 0x0B,\r
+  EfiSlotTypeIORiserCardSlot              = 0x0C,\r
+  EfiSlotTypeNuBus                        = 0x0D,\r
+  EfiSlotTypePci66MhzCapable              = 0x0E,\r
+  EfiSlotTypeAgp                          = 0x0F,\r
+  EfiSlotTypeApg2X                        = 0x10,\r
+  EfiSlotTypeAgp4X                        = 0x11,\r
+  EfiSlotTypePciX                         = 0x12,\r
+  EfiSlotTypeAgp4x                        = 0x13,\r
+  EfiSlotTypePC98C20                      = 0xA0,\r
+  EfiSlotTypePC98C24                      = 0xA1,\r
+  EfiSlotTypePC98E                        = 0xA2,\r
+  EfiSlotTypePC98LocalBus                 = 0xA3,\r
+  EfiSlotTypePC98Card                     = 0xA4,\r
+  EfiSlotTypePciExpress                   = 0xA5\r
+} EFI_MISC_SLOT_TYPE;\r
+\r
+typedef enum {\r
+  EfiSlotDataBusWidthOther      = 0x01,\r
+  EfiSlotDataBusWidthUnknown    = 0x02,\r
+  EfiSlotDataBusWidth8Bit       = 0x03,\r
+  EfiSlotDataBusWidth16Bit      = 0x04,\r
+  EfiSlotDataBusWidth32Bit      = 0x05,\r
+  EfiSlotDataBusWidth64Bit      = 0x06,\r
+  EfiSlotDataBusWidth128Bit     = 0x07,\r
+} EFI_MISC_SLOT_DATA_BUS_WIDTH;\r
+\r
+typedef enum {\r
+  EfiSlotUsageOther     = 1,\r
+  EfiSlotUsageUnknown   = 2,\r
+  EfiSlotUsageAvailable = 3,\r
+  EfiSlotUsageInUse     = 4,\r
+} EFI_MISC_SLOT_USAGE;\r
+\r
+typedef enum {\r
+  EfiSlotLengthOther   = 1,\r
+  EfiSlotLengthUnknown = 2,\r
+  EfiSlotLengthShort   = 3,\r
+  EfiSlotLengthLong    = 4\r
+} EFI_MISC_SLOT_LENGTH;\r
+\r
+typedef struct {\r
+  UINT32  CharacteristicsUnknown  :1;\r
+  UINT32  Provides50Volts         :1;\r
+  UINT32  Provides33Volts         :1;\r
+  UINT32  SharedSlot              :1;\r
+  UINT32  PcCard16Supported       :1;\r
+  UINT32  CardBusSupported        :1;\r
+  UINT32  ZoomVideoSupported      :1;\r
+  UINT32  ModemRingResumeSupported:1;\r
+  UINT32  PmeSignalSupported      :1;\r
+  UINT32  HotPlugDevicesSupported :1;\r
+  UINT32  SmbusSignalSupported    :1;\r
+  UINT32  Reserved                :21;\r
+} EFI_MISC_SLOT_CHARACTERISTICS;\r
+\r
+typedef struct {\r
+  STRING_REF                    SlotDesignation;\r
+  EFI_MISC_SLOT_TYPE            SlotType;\r
+  EFI_MISC_SLOT_DATA_BUS_WIDTH  SlotDataBusWidth;\r
+  EFI_MISC_SLOT_USAGE           SlotUsage;\r
+  EFI_MISC_SLOT_LENGTH          SlotLength;\r
+  UINT16                        SlotId;\r
+  EFI_MISC_SLOT_CHARACTERISTICS SlotCharacteristics;\r
+  EFI_DEVICE_PATH_PROTOCOL      SlotDevicePath;\r
+} EFI_MISC_SYSTEM_SLOT_DESIGNATION_DATA;\r
+\r
+//\r
+//////////////////////////////////////////////////////////////////////////////\r
+//\r
+// Misc. Onboard Device - SMBIOS Type 10\r
+//\r
+#define EFI_MISC_ONBOARD_DEVICE_RECORD_NUMBER 0x00000008\r
+\r
+typedef enum {\r
+  EfiOnBoardDeviceTypeOther          = 1,\r
+  EfiOnBoardDeviceTypeUnknown        = 2,\r
+  EfiOnBoardDeviceTypeVideo          = 3,\r
+  EfiOnBoardDeviceTypeScsiController = 4,\r
+  EfiOnBoardDeviceTypeEthernet       = 5,\r
+  EfiOnBoardDeviceTypeTokenRing      = 6,\r
+  EfiOnBoardDeviceTypeSound          = 7,\r
+} EFI_MISC_ONBOARD_DEVICE_TYPE;\r
+\r
+typedef struct {\r
+  UINT32  DeviceType    :16;\r
+  UINT32  DeviceEnabled :1;\r
+  UINT32  Reserved      :15;\r
+} EFI_MISC_ONBOARD_DEVICE_STATUS;\r
+\r
+typedef struct {\r
+  STRING_REF                           OnBoardDeviceDescription;\r
+  EFI_MISC_ONBOARD_DEVICE_STATUS       OnBoardDeviceStatus;\r
+  EFI_DEVICE_PATH_PROTOCOL             OnBoardDevicePath;\r
+} EFI_MISC_ONBOARD_DEVICE_DATA;\r
+\r
+//\r
+//////////////////////////////////////////////////////////////////////////////\r
+//\r
+// Misc. BIOS Language Information - SMBIOS Type 11\r
+//\r
+#define EFI_MISC_OEM_STRING_RECORD_NUMBER 0x00000009\r
+\r
+typedef struct {\r
+  STRING_REF                          OemStringRef[1];\r
+} EFI_MISC_OEM_STRING_DATA;\r
+\r
+//\r
+//////////////////////////////////////////////////////////////////////////////\r
+//\r
+// Misc. System Options - SMBIOS Type 12\r
+//\r
+typedef struct {\r
+  STRING_REF                          SystemOptionStringRef[1];\r
+} EFI_MISC_SYSTEM_OPTION_STRING_DATA;\r
+\r
+#define EFI_MISC_SYSTEM_OPTION_STRING_RECORD_NUMBER 0x0000000A\r
+\r
+//\r
+//////////////////////////////////////////////////////////////////////////////\r
+//\r
+// Misc. Number of Installable Languages - SMBIOS Type 13\r
+//\r
+#define EFI_MISC_NUMBER_OF_INSTALLABLE_LANGUAGES_RECORD_NUMBER 0x0000000B\r
+\r
+typedef struct {\r
+  UINT32                              AbbreviatedLanguageFormat :1;\r
+  UINT32                              Reserved                  :31;\r
+} EFI_MISC_LANGUAGE_FLAGS;\r
+\r
+typedef struct {\r
+  UINT16                              NumberOfInstallableLanguages;\r
+  EFI_MISC_LANGUAGE_FLAGS             LanguageFlags;\r
+  UINT16                              CurrentLanguageNumber;\r
+} EFI_MISC_NUMBER_OF_INSTALLABLE_LANGUAGES_DATA;\r
+\r
+//\r
+//////////////////////////////////////////////////////////////////////////////\r
+//\r
+// Misc. System Language String\r
+//\r
+#define EFI_MISC_SYSTEM_LANGUAGE_STRING_RECORD_NUMBER 0x0000000C\r
+\r
+typedef struct {\r
+  UINT16                              LanguageId;\r
+  STRING_REF                          SystemLanguageString;\r
+} EFI_MISC_SYSTEM_LANGUAGE_STRING_DATA;\r
+\r
+//\r
+//////////////////////////////////////////////////////////////////////////////\r
+//\r
+// Group Associations - SMBIOS Type 14\r
+//\r
+#define EFI_MISC_GROUP_NAME_RECORD_NUMBER          0x0000000D\r
+\r
+typedef struct {\r
+  STRING_REF               GroupName;\r
+  UINT16                   NumberGroupItems;\r
+  UINT16                   GroupId;\r
+} EFI_MISC_GROUP_NAME_DATA;\r
+\r
+//\r
+//////////////////////////////////////////////////////////////////////////////\r
+//\r
+// Group Item Set Element\r
+//\r
+#define EFI_MISC_GROUP_ITEM_SET_RECORD_NUMBER      0x0000000E\r
+\r
+typedef struct {\r
+  EFI_GUID                 SubClass;\r
+  EFI_INTER_LINK_DATA      GroupLink;\r
+  UINT16                   GroupId;\r
+  UINT16                   GroupElementId;\r
+} EFI_MISC_GROUP_ITEM_SET_DATA;\r
+\r
+//  Misc. System Event Log  - SMBIOS Type 15\r
+//\r
+#define EFI_MISC_SYSTEM_EVENT_LOG_RECORD_NUMBER 0x0000000D\r
+typedef struct {\r
+  UINT16                LogAreaLength;\r
+  UINT16                LogHeaderStartOffset;\r
+  UINT16                LogDataStartOffset;\r
+  UINT8                 AccessMethod;\r
+  UINT8                 LogStatus;\r
+  UINT32                LogChangeToken;\r
+  UINT32                AccessMethodAddress;\r
+  UINT8                 LogHeaderFormat;\r
+  UINT8                 NumberOfSupportedLogType;\r
+  UINT8                 LengthOfLogDescriptor;\r
+} EFI_MISC_SYSTEM_EVENT_LOG_DATA;\r
+\r
+//\r
+// Access Method.\r
+//  0x00~0x04:  as following definition\r
+//  0x05~0x7f:  Available for future assignment.\r
+//  0x80~0xff:  BIOS Vendor/OEM-specific.\r
+//\r
+#define ACCESS_INDEXIO_1INDEX8BIT_DATA8BIT    0x00\r
+#define ACCESS_INDEXIO_2INDEX8BIT_DATA8BIT    0X01\r
+#define ACCESS_INDEXIO_1INDEX16BIT_DATA8BIT   0X02\r
+#define ACCESS_MEMORY_MAPPED                  0x03\r
+#define ACCESS_GPNV                           0x04\r
+\r
+//\r
+//////////////////////////////////////////////////////////////////////////////\r
+//\r
+//  Misc. Pointing Device Type - SMBIOS Type 21\r
+//\r
+#define EFI_MISC_POINTING_DEVICE_TYPE_RECORD_NUMBER 0x0000000F\r
+\r
+typedef enum {\r
+  EfiPointingDeviceTypeOther         = 0x01,\r
+  EfiPointingDeviceTypeUnknown       = 0x02,\r
+  EfiPointingDeviceTypeMouse         = 0x03,\r
+  EfiPointingDeviceTypeTrackBall     = 0x04,\r
+  EfiPointingDeviceTypeTrackPoint    = 0x05,\r
+  EfiPointingDeviceTypeGlidePoint    = 0x06,\r
+  EfiPointingDeviceTouchPad          = 0x07,\r
+  EfiPointingDeviceTouchScreen       = 0x08,\r
+  EfiPointingDeviceOpticalSensor     = 0x09,\r
+} EFI_MISC_POINTING_DEVICE_TYPE;\r
+\r
+typedef enum {\r
+  EfiPointingDeviceInterfaceOther              = 0x01,\r
+  EfiPointingDeviceInterfaceUnknown            = 0x02,\r
+  EfiPointingDeviceInterfaceSerial             = 0x03,\r
+  EfiPointingDeviceInterfacePs2                = 0x04,\r
+  EfiPointingDeviceInterfaceInfrared           = 0x05,\r
+  EfiPointingDeviceInterfaceHpHil              = 0x06,\r
+  EfiPointingDeviceInterfaceBusMouse           = 0x07,\r
+  EfiPointingDeviceInterfaceADB                = 0x08,\r
+  EfiPointingDeviceInterfaceBusMouseDB9        = 0xA0,\r
+  EfiPointingDeviceInterfaceBusMouseMicroDin   = 0xA1,\r
+  EfiPointingDeviceInterfaceUsb                = 0xA2,\r
+} EFI_MISC_POINTING_DEVICE_INTERFACE;\r
+\r
+typedef struct {\r
+  EFI_MISC_POINTING_DEVICE_TYPE       PointingDeviceType;\r
+  EFI_MISC_POINTING_DEVICE_INTERFACE  PointingDeviceInterface;\r
+  UINT16                              NumberPointingDeviceButtons;\r
+  EFI_DEVICE_PATH_PROTOCOL            PointingDevicePath;\r
+} EFI_MISC_PORTING_DEVICE_TYPE_DATA;\r
+\r
+//\r
+//////////////////////////////////////////////////////////////////////////////\r
+//\r
+// Portable Battery - SMBIOS Type 22\r
+//\r
+#define EFI_MISC_BATTERY_LOCATION_RECORD_NUMBER  0x00000010\r
+\r
+typedef enum {\r
+  EfiBatteryDeviceChemistryTypeOther               = 0x01,\r
+  EfiBatteryDeviceChemistryTypeUnknown             = 0x02,\r
+  EfiBatteryDeviceChemistryTypeLeadAcid            = 0x03,\r
+  EfiBatteryDeviceChemistryTypeNickelCadmium       = 0x04,\r
+  EfiBatteryDeviceChemistryTypeNickelMetalHydride  = 0x05,\r
+  EfiBatteryDeviceChemistryTypeLithiumIon          = 0x06,\r
+  EfiBatteryDeviceChemistryTypeZincAir             = 0x07,\r
+  EfiBatteryDeviceChemistryTypeLithiumPolymer      = 0x08,\r
+} EFI_MISC_BATTERY_DEVICE_CHEMISTRY;\r
+\r
+typedef struct  {\r
+  UINT32 Date              :5;\r
+  UINT32 Month             :4;\r
+  UINT32 Year              :7;\r
+  UINT32 Reserved          :16;\r
+} EFI_MISC_BATTERY_SBDS_MANUFACTURE_DATE;\r
+\r
+typedef struct {\r
+  STRING_REF                         BatteryLocation;\r
+  STRING_REF                         BatteryManufacturer;\r
+  STRING_REF                         BatteryManufactureDate;\r
+  STRING_REF                         BatterySerialNumber;\r
+  STRING_REF                         BatteryDeviceName;\r
+  STRING_REF                         BatterySbdsVersionNumber;\r
+  STRING_REF                         BatterySbdsDeviceChemistry;\r
+  EFI_MISC_BATTERY_DEVICE_CHEMISTRY  BatteryDeviceChemistry;\r
+  EFI_EXP_BASE10_DATA                BatteryDesignCapacity;\r
+  EFI_EXP_BASE10_DATA                BatteryDesignVoltage;\r
+  UINT16                             BatteryMaximumError;\r
+  UINT16                             BatterySbdsSerialNumber;\r
+  EFI_MISC_BATTERY_SBDS_MANUFACTURE_DATE\r
+                                     BatterySbdsManufacturingDate;\r
+  UINT32                             BatteryOemSpecific;\r
+} EFI_MISC_BATTERY_LOCATION_DATA;\r
+\r
+//\r
+//////////////////////////////////////////////////////////////////////////////\r
+//\r
+// Misc. Reset Capabilities - SMBIOS Type 23\r
+//\r
+#define EFI_MISC_RESET_CAPABILITIES_RECORD_NUMBER 0x00000011\r
+\r
+typedef struct {\r
+  UINT32  Status              :1;\r
+  UINT32  BootOption          :2;\r
+  UINT32  BootOptionOnLimit   :2;\r
+  UINT32  WatchdogTimerPresent:1;\r
+  UINT32  Reserved            :26;\r
+} EFI_MISC_RESET_CAPABILITIES_TYPE;\r
+\r
+typedef struct {\r
+  EFI_MISC_RESET_CAPABILITIES_TYPE  ResetCapabilities;\r
+  UINT16                            ResetCount;\r
+  UINT16                            ResetLimit;\r
+  UINT16                            ResetTimerInterval;\r
+  UINT16                            ResetTimeout;\r
+} EFI_MISC_RESET_CAPABILITIES;\r
+\r
+typedef struct {\r
+    EFI_MISC_RESET_CAPABILITIES   ResetCapabilities;\r
+    UINT16                        ResetCount;\r
+    UINT16                        ResetLimit;\r
+    UINT16                        ResetTimerInterval;\r
+    UINT16                        ResetTimeout;\r
+} EFI_MISC_RESET_CAPABILITIES_DATA;\r
+\r
+//\r
+//////////////////////////////////////////////////////////////////////////////\r
+//\r
+// Misc. Hardware Security - SMBIOS Type 24\r
+//\r
+#define EFI_MISC_HARDWARE_SECURITY_RECORD_NUMBER 0x00000012\r
+\r
+typedef enum {\r
+  EfiHardwareSecurityStatusDisabled       = 0,\r
+  EfiHardwareSecurityStatusEnabled        = 1,\r
+  EfiHardwareSecurityStatusNotImplemented = 2,\r
+  EfiHardwareSecurityStatusUnknown        = 3\r
+} EFI_MISC_HARDWARE_SECURITY_STATUS;\r
+\r
+typedef struct {\r
+  EFI_MISC_HARDWARE_SECURITY_STATUS   FrontPanelResetStatus       :2;\r
+  EFI_MISC_HARDWARE_SECURITY_STATUS   AdministratorPasswordStatus :2;\r
+  EFI_MISC_HARDWARE_SECURITY_STATUS   KeyboardPasswordStatus      :2;\r
+  EFI_MISC_HARDWARE_SECURITY_STATUS   PowerOnPasswordStatus       :2;\r
+  EFI_MISC_HARDWARE_SECURITY_STATUS   Reserved                    :24;\r
+} EFI_MISC_HARDWARE_SECURITY_SETTINGS;\r
+\r
+typedef struct {\r
+  EFI_MISC_HARDWARE_SECURITY_SETTINGS HardwareSecuritySettings;\r
+} EFI_MISC_HARDWARE_SECURITY_SETTINGS_DATA;\r
+\r
+//\r
+//////////////////////////////////////////////////////////////////////////////\r
+//\r
+// System Power Controls - SMBIOS Type 25\r
+//\r
+#define EFI_MISC_SCHEDULED_POWER_ON_MONTH_RECORD_NUMBER  0x00000013\r
+\r
+typedef struct {\r
+  UINT16             ScheduledPoweronMonth;\r
+  UINT16             ScheduledPoweronDayOfMonth;\r
+  UINT16             ScheduledPoweronHour;\r
+  UINT16             ScheduledPoweronMinute;\r
+  UINT16             ScheduledPoweronSecond;\r
+} EFI_MISC_SCHEDULED_POWER_ON_MONTH_DATA;\r
+\r
+//\r
+//////////////////////////////////////////////////////////////////////////////\r
+//\r
+// Voltage Probe - SMBIOS Type 26\r
+//\r
+#define EFI_MISC_VOLTAGE_PROBE_DESCRIPTION_RECORD_NUMBER  0x00000014\r
+\r
+typedef struct {\r
+  UINT32 VoltageProbeSite        :5;\r
+  UINT32 VoltageProbeStatus      :3;\r
+  UINT32 Reserved                :24;\r
+} EFI_MISC_VOLTAGE_PROBE_LOCATION;\r
+\r
+typedef struct {\r
+  STRING_REF                      VoltageProbeDescription;\r
+  EFI_MISC_VOLTAGE_PROBE_LOCATION VoltageProbeLocation;\r
+  EFI_EXP_BASE10_DATA             VoltageProbeMaximumValue;\r
+  EFI_EXP_BASE10_DATA             VoltageProbeMinimumValue;\r
+  EFI_EXP_BASE10_DATA             VoltageProbeResolution;\r
+  EFI_EXP_BASE10_DATA             VoltageProbeTolerance;\r
+  EFI_EXP_BASE10_DATA             VoltageProbeAccuracy;\r
+  EFI_EXP_BASE10_DATA             VoltageProbeNominalValue;\r
+  EFI_EXP_BASE10_DATA             MDLowerNoncriticalThreshold;\r
+  EFI_EXP_BASE10_DATA             MDUpperNoncriticalThreshold;\r
+  EFI_EXP_BASE10_DATA             MDLowerCriticalThreshold;\r
+  EFI_EXP_BASE10_DATA             MDUpperCriticalThreshold;\r
+  EFI_EXP_BASE10_DATA             MDLowerNonrecoverableThreshold;\r
+  EFI_EXP_BASE10_DATA             MDUpperNonrecoverableThreshold;\r
+  UINT32                          VoltageProbeOemDefined;\r
+} EFI_MISC_VOLTAGE_PROBE_DESCRIPTION_DATA;\r
+\r
+//\r
+//////////////////////////////////////////////////////////////////////////////\r
+//\r
+// Cooling Device - SMBIOS Type 27\r
+//\r
+#define EFI_MISC_COOLING_DEVICE_TEMP_LINK_RECORD_NUMBER   0x00000015\r
+\r
+typedef struct {\r
+  UINT32 CoolingDevice                 :5;\r
+  UINT32 CoolingDeviceStatus           :3;\r
+  UINT32 Reserved                      :24;\r
+} EFI_MISC_COOLING_DEVICE_TYPE;\r
+\r
+typedef struct {\r
+  EFI_MISC_COOLING_DEVICE_TYPE   CoolingDeviceType;\r
+  EFI_INTER_LINK_DATA            CoolingDeviceTemperatureLink;\r
+  UINT16                         CoolingDeviceUnitGroup;\r
+  EFI_EXP_BASE10_DATA            CoolingDeviceNominalSpeed;\r
+  UINT32                         CoolingDeviceOemDefined;\r
+} EFI_MISC_COOLING_DEVICE_TEMP_LINK_DATA;\r
+\r
+//\r
+//////////////////////////////////////////////////////////////////////////////\r
+//\r
+// Temperature Probe - SMBIOS Type 28\r
+//\r
+#define EFI_MISC_TEMPERATURE_PROBE_DESCRIPTION_RECORD_NUMBER   0x00000016\r
+\r
+typedef struct {\r
+  UINT32 TemperatureProbeSite          :5;\r
+  UINT32 TemperatureProbeStatus        :3;\r
+  UINT32 Reserved                      :24;\r
+} EFI_MISC_TEMPERATURE_PROBE_LOCATION;\r
+\r
+typedef struct {\r
+  STRING_REF               TemperatureProbeDescription;\r
+  EFI_MISC_TEMPERATURE_PROBE_LOCATION\r
+                           TemperatureProbeLocation;\r
+  EFI_EXP_BASE10_DATA      TemperatureProbeMaximumValue;\r
+  EFI_EXP_BASE10_DATA      TemperatureProbeMinimumValue;\r
+  EFI_EXP_BASE10_DATA      TemperatureProbeResolution;\r
+  EFI_EXP_BASE10_DATA      TemperatureProbeTolerance;\r
+  EFI_EXP_BASE10_DATA      TemperatureProbeAccuracy;\r
+  EFI_EXP_BASE10_DATA      TemperatureProbeNominalValue;\r
+  EFI_EXP_BASE10_DATA      MDLowerNoncriticalThreshold;\r
+  EFI_EXP_BASE10_DATA      MDUpperNoncriticalThreshold;\r
+  EFI_EXP_BASE10_DATA      MDLowerCriticalThreshold;\r
+  EFI_EXP_BASE10_DATA      MDUpperCriticalThreshold;\r
+  EFI_EXP_BASE10_DATA      MDLowerNonrecoverableThreshold;\r
+  EFI_EXP_BASE10_DATA      MDUpperNonrecoverableThreshold;\r
+  UINT32                   TemperatureProbeOemDefined;\r
+} EFI_MISC_TEMPERATURE_PROBE_DESCRIPTION_DATA;\r
+\r
+//\r
+//////////////////////////////////////////////////////////////////////////////\r
+//\r
+// Electrical Current Probe - SMBIOS Type 29\r
+//\r
+\r
+#define EFI_MISC_ELECTRICAL_CURRENT_PROBE_DESCRIPTION_RECORD_NUMBER  0x00000017\r
+\r
+typedef struct {\r
+  UINT32 ElectricalCurrentProbeSite    :5;\r
+  UINT32 ElectricalCurrentProbeStatus  :3;\r
+  UINT32 Reserved                      :24;\r
+} EFI_MISC_ELECTRICAL_CURRENT_PROBE_LOCATION;\r
+\r
+typedef struct {\r
+  STRING_REF               ElectricalCurrentProbeDescription;\r
+  EFI_MISC_ELECTRICAL_CURRENT_PROBE_LOCATION\r
+                           ElectricalCurrentProbeLocation;\r
+  EFI_EXP_BASE10_DATA      ElectricalCurrentProbeMaximumValue;\r
+  EFI_EXP_BASE10_DATA      ElectricalCurrentProbeMinimumValue;\r
+  EFI_EXP_BASE10_DATA      ElectricalCurrentProbeResolution;\r
+  EFI_EXP_BASE10_DATA      ElectricalCurrentProbeTolerance;\r
+  EFI_EXP_BASE10_DATA      ElectricalCurrentProbeAccuracy;\r
+  EFI_EXP_BASE10_DATA      ElectricalCurrentProbeNominalValue;\r
+  EFI_EXP_BASE10_DATA      MDLowerNoncriticalThreshold;\r
+  EFI_EXP_BASE10_DATA      MDUpperNoncriticalThreshold;\r
+  EFI_EXP_BASE10_DATA      MDLowerCriticalThreshold;\r
+  EFI_EXP_BASE10_DATA      MDUpperCriticalThreshold;\r
+  EFI_EXP_BASE10_DATA      MDLowerNonrecoverableThreshold;\r
+  EFI_EXP_BASE10_DATA      MDUpperNonrecoverableThreshold;\r
+  UINT32                   ElectricalCurrentProbeOemDefined;\r
+} EFI_MISC_ELECTRICAL_CURRENT_PROBE_DESCRIPTION_DATA;\r
+\r
+//\r
+//////////////////////////////////////////////////////////////////////////////\r
+//\r
+// Out-of-Band Remote Access - SMBIOS Type 30\r
+//\r
+\r
+#define EFI_MISC_REMOTE_ACCESS_MANUFACTURER_DESCRIPTION_RECORD_NUMBER  0x00000018\r
+\r
+typedef struct  {\r
+  UINT32 InboundConnectionEnabled            :1;\r
+  UINT32 OutboundConnectionEnabled           :1;\r
+  UINT32 Reserved                            :30;\r
+} EFI_MISC_REMOTE_ACCESS_CONNECTIONS;\r
+\r
+typedef struct {\r
+  STRING_REF                             RemoteAccessManufacturerNameDescription;\r
+  EFI_MISC_REMOTE_ACCESS_CONNECTIONS     RemoteAccessConnections;\r
+} EFI_MISC_REMOTE_ACCESS_MANUFACTURER_DESCRIPTION_DATA;\r
+\r
+//\r
+//////////////////////////////////////////////////////////////////////////////\r
+//\r
+// Misc. BIS Entry Point - SMBIOS Type 31\r
+//\r
+#define EFI_MISC_BIS_ENTRY_POINT_RECORD_NUMBER          0x00000019\r
+\r
+typedef struct {\r
+  EFI_PHYSICAL_ADDRESS       BisEntryPoint;\r
+} EFI_MISC_BIS_ENTRY_POINT_DATA;\r
+\r
+//\r
+//////////////////////////////////////////////////////////////////////////////\r
+//\r
+// Misc. Boot Information - SMBIOS Type 32\r
+//\r
+#define EFI_MISC_BOOT_INFORMATION_STATUS_RECORD_NUMBER  0x0000001A\r
+\r
+typedef enum {\r
+  EfiBootInformationStatusNoError                  = 0x00,\r
+  EfiBootInformationStatusNoBootableMedia          = 0x01,\r
+  EfiBootInformationStatusNormalOSFailedLoading    = 0x02,\r
+  EfiBootInformationStatusFirmwareDetectedFailure  = 0x03,\r
+  EfiBootInformationStatusOSDetectedFailure        = 0x04,\r
+  EfiBootInformationStatusUserRequestedBoot        = 0x05,\r
+  EfiBootInformationStatusSystemSecurityViolation  = 0x06,\r
+  EfiBootInformationStatusPreviousRequestedImage   = 0x07,\r
+  EfiBootInformationStatusWatchdogTimerExpired     = 0x08,\r
+  EfiBootInformationStatusStartReserved            = 0x09,\r
+  EfiBootInformationStatusStartOemSpecific         = 0x80,\r
+  EfiBootInformationStatusStartProductSpecific     = 0xC0,\r
+} EFI_MISC_BOOT_INFORMATION_STATUS_DATA_TYPE;\r
+\r
+typedef struct {\r
+  EFI_MISC_BOOT_INFORMATION_STATUS_DATA_TYPE BootInformationStatus;\r
+  UINT8                                      BootInformationData[9];\r
+} EFI_MISC_BOOT_INFORMATION_STATUS_DATA;\r
+\r
+//\r
+//////////////////////////////////////////////////////////////////////////////\r
+//\r
+// Management Device - SMBIOS Type 34\r
+//\r
+#define EFI_MISC_MANAGEMENT_DEVICE_DESCRIPTION_RECORD_NUMBER   0x0000001B\r
+\r
+typedef enum {\r
+  EfiManagementDeviceTypeOther      = 0x01,\r
+  EfiManagementDeviceTypeUnknown    = 0x02,\r
+  EfiManagementDeviceTypeLm75       = 0x03,\r
+  EfiManagementDeviceTypeLm78       = 0x04,\r
+  EfiManagementDeviceTypeLm79       = 0x05,\r
+  EfiManagementDeviceTypeLm80       = 0x06,\r
+  EfiManagementDeviceTypeLm81       = 0x07,\r
+  EfiManagementDeviceTypeAdm9240    = 0x08,\r
+  EfiManagementDeviceTypeDs1780     = 0x09,\r
+  EfiManagementDeviceTypeMaxim1617  = 0x0A,\r
+  EfiManagementDeviceTypeGl518Sm    = 0x0B,\r
+  EfiManagementDeviceTypeW83781D    = 0x0C,\r
+  EfiManagementDeviceTypeHt82H791   = 0x0D,\r
+} EFI_MISC_MANAGEMENT_DEVICE_TYPE;\r
+\r
+typedef enum {\r
+  EfiManagementDeviceAddressTypeOther   = 1,\r
+  EfiManagementDeviceAddressTypeUnknown = 2,\r
+  EfiManagementDeviceAddressTypeIOPort  = 3,\r
+  EfiManagementDeviceAddressTypeMemory  = 4,\r
+  EfiManagementDeviceAddressTypeSmbus   = 5\r
+} EFI_MISC_MANAGEMENT_DEVICE_ADDRESS_TYPE;\r
+\r
+typedef struct {\r
+  STRING_REF                       ManagementDeviceDescription;\r
+  EFI_MISC_MANAGEMENT_DEVICE_TYPE  ManagementDeviceType;\r
+  UINTN                            ManagementDeviceAddress;\r
+  EFI_MISC_MANAGEMENT_DEVICE_ADDRESS_TYPE\r
+                                   ManagementDeviceAddressType;\r
+} EFI_MISC_MANAGEMENT_DEVICE_DESCRIPTION_DATA;\r
+\r
+//\r
+//////////////////////////////////////////////////////////////////////////////\r
+//\r
+// Management Device Component - SMBIOS Type 35\r
+//\r
+\r
+#define EFI_MISC_MANAGEMENT_DEVICE_COMPONENT_DESCRIPTION_RECORD_NUMBER  0x0000001C\r
+\r
+typedef struct {\r
+  STRING_REF               ManagementDeviceComponentDescription;\r
+  EFI_INTER_LINK_DATA      ManagementDeviceLink;\r
+  EFI_INTER_LINK_DATA      ManagementDeviceComponentLink;\r
+} EFI_MISC_MANAGEMENT_DEVICE_COMPONENT_DESCRIPTION_DATA;\r
+\r
+//\r
+//////////////////////////////////////////////////////////////////////////////\r
+//\r
+// IPMI Data Record - SMBIOS Type 38\r
+//\r
+typedef enum {\r
+  EfiIpmiOther = 0,\r
+  EfiIpmiKcs   = 1,\r
+  EfiIpmiSmic  = 2,\r
+  EfiIpmiBt    = 3,\r
+} EFI_MISC_IPMI_INTERFACE_TYPE;\r
+\r
+typedef struct {\r
+  UINT16  IpmiSpecLeastSignificantDigit:4;\r
+  UINT16  IpmiSpecMostSignificantDigit: 4;\r
+  UINT16  Reserved:                     8;\r
+} EFI_MISC_IPMI_SPECIFICATION_REVISION;\r
+\r
+typedef struct {\r
+  EFI_MISC_IPMI_INTERFACE_TYPE          IpmiInterfaceType;\r
+  EFI_MISC_IPMI_SPECIFICATION_REVISION  IpmiSpecificationRevision;\r
+  UINT16                                IpmiI2CSlaveAddress;\r
+  UINT16                                IpmiNvDeviceAddress;\r
+  UINT64                                IpmiBaseAddress;\r
+  EFI_DEVICE_PATH_PROTOCOL              IpmiDevicePath;\r
+} EFI_MISC_IPMI_INTERFACE_TYPE_DATA;\r
+\r
+#define EFI_MISC_IPMI_INTERFACE_TYPE_RECORD_NUMBER  0x0000001D\r
+\r
+//\r
+//////////////////////////////////////////////////////////////////////////////\r
+//\r
+//System Power supply Record - SMBIOS Type 39\r
+//\r
+typedef struct {\r
+  UINT16  PowerSupplyHotReplaceable  :1;\r
+  UINT16  PowerSupplyPresent         :1;\r
+  UINT16  PowerSupplyUnplugged       :1;\r
+  UINT16  InputVoltageRangeSwitch    :4;\r
+  UINT16  PowerSupplyStatus          :3;\r
+  UINT16  PowerSupplyType            :4;\r
+  UINT16  Reserved                   :2;\r
+} POWER_SUPPLY_CHARACTERISTICS;\r
+\r
+typedef struct {\r
+  UINT16                          PowerUnitGroup;\r
+  STRING_REF                      PowerSupplyLocation;\r
+  STRING_REF                      PowerSupplyDeviceName;\r
+  STRING_REF                      PowerSupplyManufacturer;\r
+  STRING_REF                      PowerSupplySerialNumber;\r
+  STRING_REF                      PowerSupplyAssetTagNumber;\r
+  STRING_REF                      PowerSupplyModelPartNumber;\r
+  STRING_REF                      PowerSupplyRevisionLevel;\r
+  UINT16                          PowerSupplyMaxPowerCapacity;\r
+  POWER_SUPPLY_CHARACTERISTICS    PowerSupplyCharacteristics;\r
+  EFI_INTER_LINK_DATA             PowerSupplyInputVoltageProbeLink;\r
+  EFI_INTER_LINK_DATA             PowerSupplyCoolingDeviceLink;\r
+  EFI_INTER_LINK_DATA             PowerSupplyInputCurrentProbeLink;\r
+} EFI_MISC_SYSTEM_POWER_SUPPLY_DATA;\r
+\r
+#define EFI_MISC_SYSTEM_POWER_SUPPLY_RECORD_NUMBER 0x0000001E\r
+\r
+//\r
+//////////////////////////////////////////////////////////////////////////////\r
+//\r
+// OEM Data Record - SMBIOS Type 0x80-0xFF\r
+//\r
+typedef struct {\r
+  UINT8       Type;\r
+  UINT8       Length;\r
+  UINT16      Handle;\r
+} SMBIOS_STRUCTURE_HDR;\r
+\r
+typedef struct {\r
+  SMBIOS_STRUCTURE_HDR          Header;\r
+  UINT8                         RawData[1];\r
+} EFI_MISC_SMBIOS_STRUCT_ENCAPSULATION_DATA;\r
+\r
+#define EFI_MISC_SMBIOS_STRUCT_ENCAP_RECORD_NUMBER  0x0000001F\r
+\r
+//\r
+// Declare the following strutures alias to use them more conviniently.\r
+//\r
+typedef EFI_MISC_LAST_PCI_BUS_DATA                        EFI_MISC_LAST_PCI_BUS;\r
+typedef EFI_MISC_BIOS_VENDOR_DATA                         EFI_MISC_BIOS_VENDOR;\r
+typedef EFI_MISC_SYSTEM_MANUFACTURER_DATA                 EFI_MISC_SYSTEM_MANUFACTURER;\r
+typedef EFI_MISC_BASE_BOARD_MANUFACTURER_DATA             EFI_MISC_BASE_BOARD_MANUFACTURER;\r
+typedef EFI_MISC_CHASSIS_MANUFACTURER_DATA                EFI_MISC_CHASSIS_MANUFACTURER;\r
+typedef EFI_MISC_PORT_INTERNAL_CONNECTOR_DESIGNATOR_DATA  EFI_MISC_PORT_INTERNAL_CONNECTOR_DESIGNATOR;\r
+typedef EFI_MISC_SYSTEM_SLOT_DESIGNATION_DATA             EFI_MISC_SYSTEM_SLOT_DESIGNATION;\r
+typedef EFI_MISC_ONBOARD_DEVICE_DATA                      EFI_MISC_ONBOARD_DEVICE;\r
+typedef EFI_MISC_PORTING_DEVICE_TYPE_DATA                 EFI_MISC_ONBOARD_DEVICE_TYPE_DATA;\r
+typedef EFI_MISC_OEM_STRING_DATA                          EFI_MISC_OEM_STRING;\r
+typedef EFI_MISC_SYSTEM_OPTION_STRING_DATA                EFI_MISC_SYSTEM_OPTION_STRING;\r
+typedef EFI_MISC_NUMBER_OF_INSTALLABLE_LANGUAGES_DATA     EFI_MISC_NUMBER_OF_INSTALLABLE_LANGUAGES;\r
+typedef EFI_MISC_SYSTEM_LANGUAGE_STRING_DATA              EFI_MISC_SYSTEM_LANGUAGE_STRING;\r
+typedef EFI_MISC_SYSTEM_EVENT_LOG_DATA                    EFI_MISC_SYSTEM_EVENT_LOG;\r
+typedef EFI_MISC_BIS_ENTRY_POINT_DATA                     EFI_MISC_BIS_ENTRY_POINT;\r
+typedef EFI_MISC_BOOT_INFORMATION_STATUS_DATA             EFI_MISC_BOOT_INFORMATION_STATUS;\r
+typedef EFI_MISC_SYSTEM_POWER_SUPPLY_DATA                 EFI_MISC_SYSTEM_POWER_SUPPLY;\r
+typedef EFI_MISC_SMBIOS_STRUCT_ENCAPSULATION_DATA         EFI_MISC_SMBIOS_STRUCT_ENCAPSULATION;\r
+\r
+typedef union {\r
+  EFI_MISC_LAST_PCI_BUS_DATA                         LastPciBus;\r
+  EFI_MISC_BIOS_VENDOR_DATA                          MiscBiosVendor;\r
+  EFI_MISC_SYSTEM_MANUFACTURER_DATA                  MiscSystemManufacturer;\r
+  EFI_MISC_BASE_BOARD_MANUFACTURER_DATA              MiscBaseBoardManufacturer;\r
+  EFI_MISC_CHASSIS_MANUFACTURER_DATA                 MiscChassisManufacturer;\r
+  EFI_MISC_PORT_INTERNAL_CONNECTOR_DESIGNATOR_DATA   MiscPortInternalConnectorDesignator;\r
+  EFI_MISC_SYSTEM_SLOT_DESIGNATION_DATA              MiscSystemSlotDesignation;\r
+  EFI_MISC_ONBOARD_DEVICE_DATA                       MiscOnboardDevice;\r
+  EFI_MISC_OEM_STRING_DATA                           MiscOemString;\r
+  EFI_MISC_SYSTEM_OPTION_STRING_DATA                 MiscOptionString;\r
+  EFI_MISC_NUMBER_OF_INSTALLABLE_LANGUAGES_DATA      NumberOfInstallableLanguages;\r
+  EFI_MISC_SYSTEM_LANGUAGE_STRING_DATA               MiscSystemLanguageString;\r
+  EFI_MISC_SYSTEM_EVENT_LOG_DATA                     MiscSystemEventLog;\r
+  EFI_MISC_GROUP_NAME_DATA                           MiscGroupNameData;\r
+  EFI_MISC_GROUP_ITEM_SET_DATA                       MiscGroupItemSetData;\r
+  EFI_MISC_PORTING_DEVICE_TYPE_DATA                  MiscPortingDeviceTypeData;\r
+  EFI_MISC_RESET_CAPABILITIES_DATA                   MiscResetCapablilitiesData;\r
+  EFI_MISC_HARDWARE_SECURITY_SETTINGS_DATA           MiscHardwareSecuritySettingsData;\r
+  EFI_MISC_SCHEDULED_POWER_ON_MONTH_DATA             MiscScheduledPowerOnMonthData;\r
+  EFI_MISC_VOLTAGE_PROBE_DESCRIPTION_DATA            MiscVoltagePorbeDescriptionData;\r
+  EFI_MISC_COOLING_DEVICE_TEMP_LINK_DATA             MiscCoolingDeviceTempLinkData;\r
+  EFI_MISC_TEMPERATURE_PROBE_DESCRIPTION_DATA        MiscTemperatureProbeDescriptionData;\r
+  EFI_MISC_ELECTRICAL_CURRENT_PROBE_DESCRIPTION_DATA MiscElectricalCurrentProbeDescriptionData;\r
+  EFI_MISC_REMOTE_ACCESS_MANUFACTURER_DESCRIPTION_DATA\r
+                                                     MiscRemoteAccessManufacturerDescriptionData;\r
+  EFI_MISC_BIS_ENTRY_POINT_DATA                      MiscBisEntryPoint;\r
+  EFI_MISC_BOOT_INFORMATION_STATUS_DATA              MiscBootInformationStatus;\r
+  EFI_MISC_MANAGEMENT_DEVICE_DESCRIPTION_DATA        MiscMangementDeviceDescriptionData;\r
+  EFI_MISC_MANAGEMENT_DEVICE_COMPONENT_DESCRIPTION_DATA\r
+                                                     MiscmangementDeviceComponentDescriptionData;\r
+  EFI_MISC_IPMI_INTERFACE_TYPE_DATA                  MiscIpmiInterfaceTypeData;\r
+  EFI_MISC_SYSTEM_POWER_SUPPLY_DATA                  MiscPowerSupplyInfo;\r
+  EFI_MISC_SMBIOS_STRUCT_ENCAPSULATION_DATA          MiscSmbiosStructEncapsulation;\r
+} EFI_MISC_SUBCLASS_RECORDS;\r
+\r
+//\r
+//\r
+//\r
+typedef struct {\r
+  EFI_SUBCLASS_TYPE1_HEADER       Header;\r
+  EFI_MISC_SUBCLASS_RECORDS       Record;\r
+} EFI_MISC_SUBCLASS_DRIVER_DATA;\r
+\r
+#pragma pack()\r
+\r
+//\r
+// Sub Class Header type1\r
+//\r
+\r
+#define EFI_SUBCLASS_INSTANCE_RESERVED       0\r
+#define EFI_SUBCLASS_INSTANCE_NON_APPLICABLE 0xFFFF  //16 bit\r
+\r
+#endif\r
diff --git a/IntelFrameworkPkg/Include/Common/FrameworkDxeCis.h b/IntelFrameworkPkg/Include/Common/FrameworkDxeCis.h
new file mode 100644 (file)
index 0000000..93e3639
--- /dev/null
@@ -0,0 +1,68 @@
+/** @file\r
+  Include file that supportes Framework extension to the EFI 1.10 spec.\r
+\r
+  This include file must only contain things defined in the Framework\r
+  specifications. If a code construct is defined in the Framework specification\r
+  it must be included by this include file.\r
+\r
+  Copyright (c) 2007, Intel Corporation\r
+  All rights reserved. This program and the accompanying materials\r
+  are licensed and made available under the terms and conditions of the BSD License\r
+  which accompanies this distribution.  The full text of the license may be found at\r
+  http://opensource.org/licenses/bsd-license.php\r
+\r
+  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
+  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
+\r
+  Module Name:    FrameworkDxeCis.h\r
+\r
+**/\r
+\r
+#ifndef _FRAMEWORK_DXE_CIS_H_\r
+#define _FRAMEWORK_DXE_CIS_H_\r
+\r
+#include <PiDxe.h>\r
+\r
+typedef struct {\r
+  EFI_TABLE_HEADER              Hdr;\r
+\r
+  //\r
+  // Time services\r
+  //\r
+  EFI_GET_TIME                  GetTime;\r
+  EFI_SET_TIME                  SetTime;\r
+  EFI_GET_WAKEUP_TIME           GetWakeupTime;\r
+  EFI_SET_WAKEUP_TIME           SetWakeupTime;\r
+\r
+  //\r
+  // Virtual memory services\r
+  //\r
+  EFI_SET_VIRTUAL_ADDRESS_MAP   SetVirtualAddressMap;\r
+  EFI_CONVERT_POINTER           ConvertPointer;\r
+\r
+  //\r
+  // Variable services\r
+  //\r
+  EFI_GET_VARIABLE              GetVariable;\r
+  EFI_GET_NEXT_VARIABLE_NAME    GetNextVariableName;\r
+  EFI_SET_VARIABLE              SetVariable;\r
+\r
+  //\r
+  // Misc\r
+  //\r
+  EFI_GET_NEXT_HIGH_MONO_COUNT  GetNextHighMonotonicCount;\r
+  EFI_RESET_SYSTEM              ResetSystem;\r
+\r
+  //\r
+  // Framework extension to EFI 1.10 runtime table\r
+  // It was moved to a protocol to not conflict with UEFI 2.0\r
+  //\r
+  EFI_REPORT_STATUS_CODE        ReportStatusCode;\r
+} FRAMEWORK_EFI_RUNTIME_SERVICES;\r
+\r
+#define EFI_EVENT_RUNTIME_CONTEXT       0x20000000\r
+#define EFI_EVENT_NOTIFY_SIGNAL_ALL     0x00000400\r
+#define EFI_EVENT_SIGNAL_READY_TO_BOOT  0x00000203\r
+#define EFI_EVENT_SIGNAL_LEGACY_BOOT    0x00000204\r
+\r
+#endif\r
diff --git a/IntelFrameworkPkg/Include/Common/FrameworkFirmwareFileSystem.h b/IntelFrameworkPkg/Include/Common/FrameworkFirmwareFileSystem.h
new file mode 100644 (file)
index 0000000..c5868e0
--- /dev/null
@@ -0,0 +1,31 @@
+/** @file\r
+  This file defines the data structures that comprise the FFS file system.\r
+\r
+  Copyright (c) 2007, Intel Corporation\r
+  All rights reserved. This program and the accompanying materials\r
+  are licensed and made available under the terms and conditions of the BSD License\r
+  which accompanies this distribution.  The full text of the license may be found at\r
+  http://opensource.org/licenses/bsd-license.php\r
+\r
+  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
+  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
+\r
+  Module Name:  FrameworkFirmwareFileSystem.h\r
+\r
+  @par Revision Reference:\r
+  These definitions are from Firmware File System Spec 0.9 but not in PI specs.\r
+\r
+**/\r
+\r
+#ifndef _FRAMEWORK_FIRMWARE_FILE_SYSTEM_H_\r
+#define _FRAMEWORK_FIRMWARE_FILE_SYSTEM_H_\r
+\r
+#include <PiFirmwareFileSystem.h>\r
+\r
+typedef UINT16                      EFI_FFS_FILE_TAIL;\r
+\r
+#define FFS_ATTRIB_TAIL_PRESENT     0x01\r
+#define FFS_ATTRIB_RECOVERY         0x02\r
+#define FFS_ATTRIB_HEADER_EXTENSION 0x04\r
+\r
+#endif\r
diff --git a/IntelFrameworkPkg/Include/Common/FrameworkHob.h b/IntelFrameworkPkg/Include/Common/FrameworkHob.h
new file mode 100644 (file)
index 0000000..346c954
--- /dev/null
@@ -0,0 +1,36 @@
+/** @file\r
+  This file defines the data structures per HOB specification v0.9.\r
+\r
+  Copyright (c) 2007, Intel Corporation\r
+  All rights reserved. This program and the accompanying materials\r
+  are licensed and made available under the terms and conditions of the BSD License\r
+  which accompanies this distribution.  The full text of the license may be found at\r
+  http://opensource.org/licenses/bsd-license.php\r
+\r
+  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
+  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
+\r
+  Module Name:  FrameworkFirmwareFileSystem.h\r
+\r
+  @par Revision Reference:\r
+  These definitions are from HOB Spec 0.9 but not adopted by PI specs.\r
+\r
+**/\r
+\r
+#ifndef _FRAMEWORK_HOB_H_\r
+#define _FRAMEWORK_HOB_H_\r
+\r
+#include <PiHob.h>\r
+\r
+//\r
+// Capsule volume HOB -- identical to a firmware volume\r
+//\r
+#define EFI_HOB_TYPE_CV 0x0008\r
+\r
+typedef struct {\r
+  EFI_HOB_GENERIC_HEADER  Header;\r
+  EFI_PHYSICAL_ADDRESS    BaseAddress;\r
+  UINT64                  Length;\r
+} EFI_HOB_CAPSULE_VOLUME;\r
+\r
+#endif\r
diff --git a/IntelFrameworkPkg/Include/Common/FrameworkLegacy16.h b/IntelFrameworkPkg/Include/Common/FrameworkLegacy16.h
new file mode 100644 (file)
index 0000000..ff7f2c0
--- /dev/null
@@ -0,0 +1,425 @@
+/** @file\r
+  API between 16-bit Legacy BIOS and EFI\r
+\r
+  We need to figure out what the 16-bit code is going to use to\r
+  represent these data structures. Is a pointer SEG:OFF or 32-bit...\r
+\r
+  Copyright (c) 2007, Intel Corporation\r
+  All rights reserved. This program and the accompanying materials\r
+  are licensed and made available under the terms and conditions of the BSD License\r
+  which accompanies this distribution.  The full text of the license may be found at\r
+  http://opensource.org/licenses/bsd-license.php\r
+\r
+  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
+  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
+\r
+  Module Name:  FrameworkLegacy16.h\r
+\r
+  @par Revision Reference:\r
+  These definitions are from Compatibility Support Module Spec Version 0.96.\r
+\r
+**/\r
+\r
+#ifndef _FRAMEWORK_LEGACY_16_H_\r
+#define _FRAMEWORK_LEGACY_16_H_\r
+\r
+#include <Base.h>\r
+\r
+//\r
+// All structures defined in this header file are packed on byte boundary\r
+//\r
+#pragma pack(1)\r
+\r
+///////////////////////////////////////////////////////////////////////////////\r
+// EFI_COMPATIBILITY16_TABLE is located at a 16-byte boundary starting with the\r
+// signature "$EFI"\r
+///////////////////////////////////////////////////////////////////////////////\r
+\r
+#define EFI_COMPATIBILITY16_TABLE_SIGNATURE EFI_SIGNATURE_32('$', 'E', 'F', 'I')\r
+\r
+typedef struct {\r
+  UINT32  Signature;      // "$EFI"\r
+  UINT8   TableChecksum;\r
+  UINT8   TableLength;\r
+  UINT8   EfiMajorRevision;\r
+  UINT8   EfiMinorRevision;\r
+  UINT8   TableMajorRevision;\r
+  UINT8   TableMinorRevision;\r
+  UINT16  Reserved;\r
+  UINT16  Compatibility16CallSegment;\r
+  UINT16  Compatibility16CallOffset;\r
+  UINT16  PnPInstallationCheckSegment;\r
+  UINT16  PnPInstallationCheckOffset;\r
+  UINT32  EfiSystemTable; // The physical address of EFI_SYSTEM_TABLE\r
+  UINT32  OemIdStringPointer;\r
+  UINT32  AcpiRsdPtrPointer;\r
+  UINT16  OemRevision;\r
+  UINT32  E820Pointer;\r
+  UINT32  E820Length;\r
+  UINT32  IrqRoutingTablePointer;\r
+  UINT32  IrqRoutingTableLength;\r
+  UINT32  MpTablePtr;\r
+  UINT32  MpTableLength;\r
+  UINT16  OemIntSegment;\r
+  UINT16  OemIntOffset;\r
+  UINT16  Oem32Segment;\r
+  UINT16  Oem32Offset;\r
+  UINT16  Oem16Segment;\r
+  UINT16  Oem16Offset;\r
+  UINT16  TpmSegment;\r
+  UINT16  TpmOffset;\r
+  UINT32  IbvPointer;\r
+  UINT32  PciExpressBase;\r
+  UINT8   LastPciBus;\r
+} EFI_COMPATIBILITY16_TABLE;\r
+\r
+///////////////////////////////////////////////////////////////////////////////\r
+// Functions provided by the CSM binary\r
+///////////////////////////////////////////////////////////////////////////////\r
+typedef enum {\r
+  Legacy16InitializeYourself    = 0x0000,\r
+  Legacy16UpdateBbs             = 0x0001,\r
+  Legacy16PrepareToBoot         = 0x0002,\r
+  Legacy16Boot                  = 0x0003,\r
+  Legacy16RetrieveLastBootDevice= 0x0004,\r
+  Legacy16DispatchOprom         = 0x0005,\r
+  Legacy16GetTableAddress       = 0x0006,\r
+  Legacy16SetKeyboardLeds       = 0x0007,\r
+  Legacy16InstallPciHandler     = 0x0008\r
+} EFI_COMPATIBILITY_FUNCTIONS;\r
+\r
+///////////////////////////////////////////////////////////////////////////////\r
+// EFI_TO_COMPATIBILITY16_INIT_TABLE\r
+///////////////////////////////////////////////////////////////////////////////\r
+typedef struct {\r
+  UINT32  BiosLessThan1MB;\r
+  UINT32  HiPmmMemory;\r
+  UINT32  HiPmmMemorySizeInBytes;\r
+  UINT16  ReverseThunkCallSegment;\r
+  UINT16  ReverseThunkCallOffset;\r
+  UINT32  NumberE820Entries;\r
+  UINT32  OsMemoryAbove1Mb;\r
+  UINT32  ThunkStart;\r
+  UINT32  ThunkSizeInBytes;\r
+  UINT32  LowPmmMemory;\r
+  UINT32  LowPmmMemorySizeInBytes;\r
+} EFI_TO_COMPATIBILITY16_INIT_TABLE;\r
+\r
+///////////////////////////////////////////////////////////////////////////////\r
+// EFI_TO_COMPATIBILITY16_BOOT_TABLE\r
+///////////////////////////////////////////////////////////////////////////////\r
+\r
+//\r
+// DEVICE_PRODUCER_SERIAL & its modes\r
+//\r
+typedef struct {\r
+  UINT16      Address;\r
+  UINT8       Irq;\r
+  SERIAL_MODE Mode;\r
+} DEVICE_PRODUCER_SERIAL;\r
+\r
+#define DEVICE_SERIAL_MODE_NORMAL               0x00\r
+#define DEVICE_SERIAL_MODE_IRDA                 0x01\r
+#define DEVICE_SERIAL_MODE_ASK_IR               0x02\r
+#define DEVICE_SERIAL_MODE_DUPLEX_HALF          0x00\r
+#define DEVICE_SERIAL_MODE_DUPLEX_FULL          0x10\r
+\r
+//\r
+// DEVICE_PRODUCER_PARALLEL & its modes\r
+//\r
+typedef struct {\r
+  UINT16        Address;\r
+  UINT8         Irq;\r
+  UINT8         Dma;\r
+  PARALLEL_MODE Mode;\r
+} DEVICE_PRODUCER_PARALLEL;\r
+\r
+#define DEVICE_PARALLEL_MODE_MODE_OUTPUT_ONLY   0x00\r
+#define DEVICE_PARALLEL_MODE_MODE_BIDIRECTIONAL 0x01\r
+#define DEVICE_PARALLEL_MODE_MODE_EPP           0x02\r
+#define DEVICE_PARALLEL_MODE_MODE_ECP           0x03\r
+\r
+//\r
+// DEVICE_PRODUCER_FLOPPY\r
+//\r
+typedef struct {\r
+  UINT16  Address;\r
+  UINT8   Irq;\r
+  UINT8   Dma;\r
+  UINT8   NumberOfFloppy;\r
+} DEVICE_PRODUCER_FLOPPY;\r
+\r
+//\r
+// LEGACY_DEVICE_FLAGS\r
+//\r
+typedef struct {\r
+  UINT32  A20Kybd : 1;\r
+  UINT32  A20Port90 : 1;\r
+  UINT32  Reserved : 30;\r
+} LEGACY_DEVICE_FLAGS;\r
+\r
+//\r
+// DEVICE_PRODUCER_DATA_HEADER\r
+//\r
+typedef struct {\r
+  DEVICE_PRODUCER_SERIAL    Serial[4];\r
+  DEVICE_PRODUCER_PARALLEL  Parallel[3];\r
+  DEVICE_PRODUCER_FLOPPY    Floppy;\r
+  UINT8                     MousePresent;\r
+  LEGACY_DEVICE_FLAGS       Flags;\r
+} DEVICE_PRODUCER_DATA_HEADER;\r
+\r
+//\r
+// ATAPI_IDENTIFY\r
+//\r
+typedef struct {\r
+  UINT16  Raw[256];\r
+} ATAPI_IDENTIFY;\r
+\r
+//\r
+// HDD_INFO & its status\r
+//\r
+typedef struct {\r
+  UINT16          Status;\r
+  UINT32          Bus;\r
+  UINT32          Device;\r
+  UINT32          Function;\r
+  UINT16          CommandBaseAddress;\r
+  UINT16          ControlBaseAddress;\r
+  UINT16          BusMasterAddress;\r
+  UINT8           HddIrq;\r
+  ATAPI_IDENTIFY  IdentifyDrive[2];\r
+} HDD_INFO;\r
+\r
+#define HDD_PRIMARY               0x01\r
+#define HDD_SECONDARY             0x02\r
+#define HDD_MASTER_ATAPI_CDROM    0x04\r
+#define HDD_SLAVE_ATAPI_CDROM     0x08\r
+#define HDD_MASTER_IDE            0x20\r
+#define HDD_SLAVE_IDE             0x40\r
+#define HDD_MASTER_ATAPI_ZIPDISK  0x10\r
+#define HDD_SLAVE_ATAPI_ZIPDISK   0x80\r
+\r
+//\r
+// BBS_STATUS_FLAGS\r
+//\r
+typedef struct {\r
+  UINT16  OldPosition : 4;\r
+  UINT16  Reserved1 : 4;\r
+  UINT16  Enabled : 1;\r
+  UINT16  Failed : 1;\r
+  UINT16  MediaPresent : 2;\r
+  UINT16  Reserved2 : 4;\r
+} BBS_STATUS_FLAGS;\r
+\r
+//\r
+// BBS_TABLE, device type values & boot priority values\r
+//\r
+typedef struct {\r
+  UINT16            BootPriority;\r
+  UINT32            Bus;\r
+  UINT32            Device;\r
+  UINT32            Function;\r
+  UINT8             Class;\r
+  UINT8             SubClass;\r
+  UINT16            MfgStringOffset;\r
+  UINT16            MfgStringSegment;\r
+  UINT16            DeviceType;\r
+  BBS_STATUS_FLAGS  StatusFlags;\r
+  UINT16            BootHandlerOffset;\r
+  UINT16            BootHandlerSegment;\r
+  UINT16            DescStringOffset;\r
+  UINT16            DescStringSegment;\r
+  UINT32            InitPerReserved;\r
+  UINT32            AdditionalIrq13Handler;\r
+  UINT32            AdditionalIrq18Handler;\r
+  UINT32            AdditionalIrq19Handler;\r
+  UINT32            AdditionalIrq40Handler;\r
+  UINT8             AssignedDriveNumber;\r
+  UINT32            AdditionalIrq41Handler;\r
+  UINT32            AdditionalIrq46Handler;\r
+  UINT32            IBV1;\r
+  UINT32            IBV2;\r
+} BBS_TABLE;\r
+\r
+#define BBS_FLOPPY        0x01\r
+#define BBS_HARDDISK      0x02\r
+#define BBS_CDROM         0x03\r
+#define BBS_PCMCIA        0x04\r
+#define BBS_USB           0x05\r
+#define BBS_EMBED_NETWORK 0x06\r
+#define BBS_BEV_DEVICE    0x80\r
+#define BBS_UNKNOWN       0xff\r
+\r
+#define BBS_DO_NOT_BOOT_FROM    0xFFFC\r
+#define BBS_LOWEST_PRIORITY     0xFFFD\r
+#define BBS_UNPRIORITIZED_ENTRY 0xFFFE\r
+#define BBS_IGNORE_ENTRY        0xFFFF\r
+\r
+//\r
+// SMM_ATTRIBUTES & relating type, port and data size constants\r
+//\r
+typedef struct {\r
+  UINT16  Type : 3;\r
+  UINT16  PortGranularity : 3;\r
+  UINT16  DataGranularity : 3;\r
+  UINT16  Reserved : 7;\r
+} SMM_ATTRIBUTES;\r
+\r
+#define STANDARD_IO       0x00\r
+#define STANDARD_MEMORY   0x01\r
+\r
+#define PORT_SIZE_8       0x00\r
+#define PORT_SIZE_16      0x01\r
+#define PORT_SIZE_32      0x02\r
+#define PORT_SIZE_64      0x03\r
+\r
+#define DATA_SIZE_8       0x00\r
+#define DATA_SIZE_16      0x01\r
+#define DATA_SIZE_32      0x02\r
+#define DATA_SIZE_64      0x03\r
+\r
+//\r
+// SMM_FUNCTION & relating constants\r
+//\r
+typedef struct {\r
+  UINT16  Function : 15;\r
+  UINT16  Owner : 1;\r
+} SMM_FUNCTION;\r
+\r
+#define INT15_D042        0x0000\r
+#define GET_USB_BOOT_INFO 0x0001\r
+#define DMI_PNP_50_57     0x0002\r
+\r
+#define STANDARD_OWNER    0x0\r
+#define OEM_OWNER         0x1\r
+\r
+//\r
+// SMM_ENTRY\r
+//\r
+// This structure assumes both port and data sizes are 1. SmmAttribute must be\r
+// properly to reflect that assumption.\r
+//\r
+typedef struct {\r
+  SMM_ATTRIBUTES  SmmAttributes;\r
+  SMM_FUNCTION    SmmFunction;\r
+  UINT8           SmmPort;\r
+  UINT8           SmmData;\r
+} SMM_ENTRY;\r
+\r
+//\r
+// SMM_TABLE\r
+//\r
+typedef struct {\r
+  UINT16    NumSmmEntries;\r
+  SMM_ENTRY SmmEntry;\r
+} SMM_TABLE;\r
+\r
+//\r
+// UDC_ATTRIBUTES\r
+//\r
+typedef struct {\r
+  UINT8 DirectoryServiceValidity : 1;\r
+  UINT8 RabcaUsedFlag : 1;\r
+  UINT8 ExecuteHddDiagnosticsFlag : 1;\r
+  UINT8 Reserved : 5;\r
+} UDC_ATTRIBUTES;\r
+\r
+//\r
+// UD_TABLE\r
+//\r
+typedef struct {\r
+  UDC_ATTRIBUTES  Attributes;\r
+  UINT8           DeviceNumber;\r
+  UINT8           BbsTableEntryNumberForParentDevice;\r
+  UINT8           BbsTableEntryNumberForBoot;\r
+  UINT8           BbsTableEntryNumberForHddDiag;\r
+  UINT8           BeerData[128];\r
+  UINT8           ServiceAreaData[64];\r
+} UD_TABLE;\r
+\r
+//\r
+// EFI_TO_COMPATIBILITY16_BOOT_TABLE\r
+//\r
+#define EFI_TO_LEGACY_MAJOR_VERSION 0x02\r
+#define EFI_TO_LEGACY_MINOR_VERSION 0x00\r
+#define MAX_IDE_CONTROLLER          8\r
+\r
+typedef struct {\r
+  UINT16                      MajorVersion;\r
+  UINT16                      MinorVersion;\r
+  UINT32                      AcpiTable;   // 4 GB range\r
+  UINT32                      SmbiosTable; // 4 GB range\r
+  UINT32                      SmbiosTableLength;\r
+\r
+  //\r
+  // Legacy SIO state\r
+  //\r
+  DEVICE_PRODUCER_DATA_HEADER SioData;\r
+\r
+  UINT16                      DevicePathType;\r
+  UINT16                      PciIrqMask;\r
+  UINT32                      NumberE820Entries;\r
+\r
+  //\r
+  // Controller & Drive Identify[2] per controller information\r
+  //\r
+  HDD_INFO                    HddInfo[MAX_IDE_CONTROLLER];\r
+\r
+  UINT32                      NumberBbsEntries;\r
+  UINT32                      BbsTable;\r
+  UINT32                      SmmTable;\r
+  UINT32                      OsMemoryAbove1Mb;\r
+  UINT32                      UnconventionalDeviceTable;\r
+} EFI_TO_COMPATIBILITY16_BOOT_TABLE;\r
+\r
+///////////////////////////////////////////////////////////////////////////////\r
+// EFI_DISPATCH_OPROM_TABLE\r
+///////////////////////////////////////////////////////////////////////////////\r
+\r
+typedef struct {\r
+  UINT16  PnPInstallationCheckSegment;\r
+  UINT16  PnPInstallationCheckOffset;\r
+  UINT16  OpromSegment;\r
+  UINT8   PciBus;\r
+  UINT8   PciDeviceFunction;\r
+  UINT8   NumberBbsEntries;\r
+  VOID    *BbsTablePointer; /// @bug: variable size on 32/64-bit systems.\r
+} EFI_DISPATCH_OPROM_TABLE;\r
+\r
+///////////////////////////////////////////////////////////////////////////////\r
+// EFI_LEGACY_INSTALL_PCI_HANDLER\r
+///////////////////////////////////////////////////////////////////////////////\r
+typedef struct {\r
+  UINT8   PciBus;\r
+  UINT8   PciDeviceFun;\r
+  UINT8   PciSegment;\r
+  UINT8   PciClass;\r
+  UINT8   PciSubclass;\r
+  UINT8   PciInterface;\r
+\r
+  //\r
+  // Primary section\r
+  //\r
+  UINT8   PrimaryIrq;\r
+  UINT8   PrimaryReserved;\r
+  UINT16  PrimaryControl;\r
+  UINT16  PrimaryBase;\r
+  UINT16  PrimaryBusMaster;\r
+\r
+  //\r
+  // Secondary Section\r
+  //\r
+  UINT8   SecondaryIrq;\r
+  UINT8   SecondaryReserved;\r
+  UINT16  SecondaryControl;\r
+  UINT16  SecondaryBase;\r
+  UINT16  SecondaryBusMaster;\r
+} EFI_LEGACY_INSTALL_PCI_HANDLER;\r
+\r
+//\r
+// Restore default pack value\r
+//\r
+#pragma pack()\r
+\r
+#endif\r
diff --git a/IntelFrameworkPkg/Include/Common/FrameworkSmmCis.h b/IntelFrameworkPkg/Include/Common/FrameworkSmmCis.h
new file mode 100644 (file)
index 0000000..695a6a1
--- /dev/null
@@ -0,0 +1,480 @@
+/** @file\r
+  Include file matches things in the Smm CIS spec.\r
+\r
+  Copyright (c) 2007, Intel Corporation\r
+  All rights reserved. This program and the accompanying materials\r
+  are licensed and made available under the terms and conditions of the BSD License\r
+  which accompanies this distribution.  The full text of the license may be found at\r
+  http://opensource.org/licenses/bsd-license.php\r
+\r
+  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
+  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
+\r
+  Module Name:  FrameworkSmmCis.h\r
+\r
+  @par Revision Reference:\r
+  Version 0.9.\r
+\r
+**/\r
+\r
+#ifndef _FRAMEWORK_SMM_CIS_H_\r
+#define _FRAMEWORK_SMM_CIS_H_\r
+\r
+#include <PiDxe.h>\r
+\r
+#define EFI_SMM_CPU_IO_GUID \\r
+  { \\r
+    0x5f439a0b, 0x45d8, 0x4682, {0xa4, 0xf4, 0xf0, 0x57, 0x6b, 0x51, 0x34, 0x41 } \\r
+  }\r
+\r
+typedef struct _EFI_SMM_SYSTEM_TABLE      EFI_SMM_SYSTEM_TABLE;\r
+typedef struct _EFI_SMM_CPU_IO_INTERFACE  EFI_SMM_CPU_IO_INTERFACE;\r
+\r
+\r
+//\r
+// SMM Base specification constant and types\r
+//\r
+#define SMM_SMST_SIGNATURE            EFI_SIGNATURE_32 ('S', 'M', 'S', 'T')\r
+#define EFI_SMM_SYSTEM_TABLE_REVISION (0 << 16) | (0x09)\r
+\r
+//\r
+// *******************************************************\r
+// EFI_SMM_IO_WIDTH\r
+// *******************************************************\r
+//\r
+typedef enum {\r
+  SMM_IO_UINT8  = 0,\r
+  SMM_IO_UINT16 = 1,\r
+  SMM_IO_UINT32 = 2,\r
+  SMM_IO_UINT64 = 3\r
+} EFI_SMM_IO_WIDTH;\r
+\r
+/**\r
+  Provides the basic memory and I/O interfaces that are used to\r
+  abstract accesses to devices.\r
+\r
+  @param  This             The EFI_SMM_CPU_IO_INTERFACE instance.\r
+  @param  Width            Signifies the width of the I/O operations.\r
+  @param  Address          The base address of the I/O operations.\r
+  @param  Count            The number of I/O operations to perform.\r
+  @param  Buffer           For read operations, the destination buffer to store the results.\r
+                           For write operations, the source buffer from which to write data.\r
+\r
+  @retval EFI_SUCCESS           The data was read from or written to the device.\r
+  @retval EFI_UNSUPPORTED       The Address is not valid for this system.\r
+  @retval EFI_INVALID_PARAMETER Width or Count, or both, were invalid.\r
+  @retval EFI_OUT_OF_RESOURCES  The request could not be completed due to a lack of resources.\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_SMM_CPU_IO) (\r
+  IN EFI_SMM_CPU_IO_INTERFACE         *This,\r
+  IN EFI_SMM_IO_WIDTH                 Width,\r
+  IN UINT64                           Address,\r
+  IN UINTN                            Count,\r
+  IN OUT VOID                         *Buffer\r
+  );\r
+\r
+typedef struct {\r
+  EFI_SMM_CPU_IO  Read;\r
+  EFI_SMM_CPU_IO  Write;\r
+} EFI_SMM_IO_ACCESS;\r
+\r
+struct _EFI_SMM_CPU_IO_INTERFACE {\r
+  EFI_SMM_IO_ACCESS Mem;\r
+  EFI_SMM_IO_ACCESS Io;\r
+};\r
+\r
+/**\r
+  Allocates pool memory from SMRAM for IA-32 or runtime memory for\r
+  the Itanium processor family.\r
+\r
+  @param  PoolType         The type of pool to allocate.The only supported type is EfiRuntimeServicesData\r
+  @param  Size             The number of bytes to allocate from the pool.\r
+  @param  Buffer           A pointer to a pointer to the allocated buffer if the call\r
+                           succeeds; undefined otherwise.\r
+\r
+  @retval EFI_SUCCESS           The requested number of bytes was allocated.\r
+  @retval EFI_OUT_OF_RESOURCES  The pool requested could not be allocated.\r
+  @retval EFI_UNSUPPORTED       In runtime.\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_SMMCORE_ALLOCATE_POOL) (\r
+  IN EFI_MEMORY_TYPE                PoolType,\r
+  IN UINTN                          Size,\r
+  OUT VOID                          **Buffer\r
+  );\r
+\r
+/**\r
+  Returns pool memory to the system.\r
+\r
+  @param  Buffer           Pointer to the buffer to free.\r
+\r
+  @retval EFI_SUCCESS           The memory was returned to the system.\r
+  @retval EFI_INVALID_PARAMETER Buffer was invalid.\r
+  @retval EFI_UNSUPPORTED       In runtime.\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_SMMCORE_FREE_POOL) (\r
+  IN VOID                   *Buffer\r
+  );\r
+\r
+/**\r
+  Allocates memory pages from the system.\r
+\r
+  @param  Type             The type of allocation to perform.\r
+  @param  MemoryType       The only supported type is EfiRuntimeServicesData\r
+  @param  NumberofPages    The number of contiguous 4 KB pages to allocate\r
+  @param  Memory           Pointer to a physical address. On input, the way in which\r
+                           the address is used depends on the value of Type. On output, the address\r
+                           is set to the base of the page range that was allocated.\r
+\r
+  @retval EFI_SUCCESS           The requested pages were allocated.\r
+  @retval EFI_OUT_OF_RESOURCES  The pages requested could not be allocated.\r
+  @retval EFI_NOT_FOUND         The requested pages could not be found.\r
+  @retval EFI_INVALID_PARAMETER Type is not AllocateAnyPages or AllocateMaxAddress\r
+                                or AllocateAddress. Or MemoryType is in the range EfiMaxMemoryType..0x7FFFFFFF.\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_SMMCORE_ALLOCATE_PAGES) (\r
+  IN EFI_ALLOCATE_TYPE      Type,\r
+  IN EFI_MEMORY_TYPE        MemoryType,\r
+  IN UINTN                  NumberOfPages,\r
+  OUT EFI_PHYSICAL_ADDRESS  *Memory\r
+  );\r
+\r
+/**\r
+  Frees memory pages for the system.\r
+\r
+  @param  Memory           The base physical address of the pages to be freed\r
+  @param  NumberOfPages    The number of contiguous 4 KB pages to free.\r
+\r
+  @retval EFI_SUCCESS           The requested memory pages were freed.\r
+  @retval EFI_INVALID_PARAMETER Memory is not a page-aligned address or NumberOfPages is invalid.\r
+  @retval EFI_NOT_FOUND         The requested memory pages were not allocated with SmmAllocatePages().\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_SMMCORE_FREE_PAGES) (\r
+  IN EFI_PHYSICAL_ADDRESS   Memory,\r
+  IN UINTN                  NumberOfPages\r
+  );\r
+\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_SMM_STARTUP_THIS_AP) (\r
+  IN  EFI_AP_PROCEDURE                    Procedure,\r
+  IN  UINTN                               CpuNumber,\r
+  IN  OUT VOID                            *ProcArguments OPTIONAL\r
+  );\r
+\r
+typedef struct {\r
+  UINT8                 Reserved1[248];\r
+  UINT32                SMBASE;\r
+  UINT32                SMMRevId;\r
+  UINT16                IORestart;\r
+  UINT16                AutoHALTRestart;\r
+  UINT8                 Reserved2[164];\r
+  UINT32                ES;\r
+  UINT32                CS;\r
+  UINT32                SS;\r
+  UINT32                DS;\r
+  UINT32                FS;\r
+  UINT32                GS;\r
+  UINT32                LDTBase;\r
+  UINT32                TR;\r
+  UINT32                DR7;\r
+  UINT32                DR6;\r
+  UINT32                EAX;\r
+  UINT32                ECX;\r
+  UINT32                EDX;\r
+  UINT32                EBX;\r
+  UINT32                ESP;\r
+  UINT32                EBP;\r
+  UINT32                ESI;\r
+  UINT32                EDI;\r
+  UINT32                EIP;\r
+  UINT32                EFLAGS;\r
+  UINT32                CR3;\r
+  UINT32                CR0;\r
+} EFI_SMI_CPU_SAVE_STATE;\r
+\r
+typedef struct {\r
+  UINT64   reserved;\r
+  UINT64   r1;\r
+  UINT64   r2;\r
+  UINT64   r3;\r
+  UINT64   r4;\r
+  UINT64   r5;\r
+  UINT64   r6;\r
+  UINT64   r7;\r
+  UINT64   r8;\r
+  UINT64   r9;\r
+  UINT64   r10;\r
+  UINT64   r11;\r
+  UINT64   r12;\r
+  UINT64   r13;\r
+  UINT64   r14;\r
+  UINT64   r15;\r
+  UINT64   r16;\r
+  UINT64   r17;\r
+  UINT64   r18;\r
+  UINT64   r19;\r
+  UINT64   r20;\r
+  UINT64   r21;\r
+  UINT64   r22;\r
+  UINT64   r23;\r
+  UINT64   r24;\r
+  UINT64   r25;\r
+  UINT64   r26;\r
+  UINT64   r27;\r
+  UINT64   r28;\r
+  UINT64   r29;\r
+  UINT64   r30;\r
+  UINT64   r31;\r
+\r
+  UINT64   pr;\r
+\r
+  UINT64   b0;\r
+  UINT64   b1;\r
+  UINT64   b2;\r
+  UINT64   b3;\r
+  UINT64   b4;\r
+  UINT64   b5;\r
+  UINT64   b6;\r
+  UINT64   b7;\r
+\r
+  // application registers\r
+  UINT64   ar_rsc;\r
+  UINT64   ar_bsp;\r
+  UINT64   ar_bspstore;\r
+  UINT64   ar_rnat;\r
+\r
+  UINT64   ar_fcr;\r
+\r
+  UINT64   ar_eflag;\r
+  UINT64   ar_csd;\r
+  UINT64   ar_ssd;\r
+  UINT64   ar_cflg;\r
+  UINT64   ar_fsr;\r
+  UINT64   ar_fir;\r
+  UINT64   ar_fdr;\r
+\r
+  UINT64   ar_ccv;\r
+\r
+  UINT64   ar_unat;\r
+\r
+  UINT64   ar_fpsr;\r
+\r
+  UINT64   ar_pfs;\r
+  UINT64   ar_lc;\r
+  UINT64   ar_ec;\r
+\r
+  // control registers\r
+  UINT64   cr_dcr;\r
+  UINT64   cr_itm;\r
+  UINT64   cr_iva;\r
+  UINT64   cr_pta;\r
+  UINT64   cr_ipsr;\r
+  UINT64   cr_isr;\r
+  UINT64   cr_iip;\r
+  UINT64   cr_ifa;\r
+  UINT64   cr_itir;\r
+  UINT64   cr_iipa;\r
+  UINT64   cr_ifs;\r
+  UINT64   cr_iim;\r
+  UINT64   cr_iha;\r
+\r
+  // debug registers\r
+  UINT64   dbr0;\r
+  UINT64   dbr1;\r
+  UINT64   dbr2;\r
+  UINT64   dbr3;\r
+  UINT64   dbr4;\r
+  UINT64   dbr5;\r
+  UINT64   dbr6;\r
+  UINT64   dbr7;\r
+\r
+  UINT64   ibr0;\r
+  UINT64   ibr1;\r
+  UINT64   ibr2;\r
+  UINT64   ibr3;\r
+  UINT64   ibr4;\r
+  UINT64   ibr5;\r
+  UINT64   ibr6;\r
+  UINT64   ibr7;\r
+\r
+  // virtual registers\r
+  UINT64   int_nat;         // nat bits for R1-R31\r
+\r
+} EFI_PMI_SYSTEM_CONTEXT;\r
+\r
+typedef union {\r
+  EFI_SMI_CPU_SAVE_STATE     Ia32SaveState;\r
+  EFI_PMI_SYSTEM_CONTEXT     ItaniumSaveState;\r
+} EFI_SMM_CPU_SAVE_STATE;\r
+\r
+typedef struct {\r
+  UINT16                Fcw;\r
+  UINT16                Fsw;\r
+  UINT16                Ftw;\r
+  UINT16                Opcode;\r
+  UINT32                Eip;\r
+  UINT16                Cs;\r
+  UINT16                Rsvd1;\r
+  UINT32                DataOffset;\r
+  UINT16                Ds;\r
+  UINT8                 Rsvd2[10];\r
+  UINT8                 St0Mm0[10], Rsvd3[6];\r
+  UINT8                 St0Mm1[10], Rsvd4[6];\r
+  UINT8                 St0Mm2[10], Rsvd5[6];\r
+  UINT8                 St0Mm3[10], Rsvd6[6];\r
+  UINT8                 St0Mm4[10], Rsvd7[6];\r
+  UINT8                 St0Mm5[10], Rsvd8[6];\r
+  UINT8                 St0Mm6[10], Rsvd9[6];\r
+  UINT8                 St0Mm7[10], Rsvd10[6];\r
+  UINT8                 Rsvd11[22*16];\r
+} EFI_SMI_OPTIONAL_FPSAVE_STATE;\r
+\r
+typedef struct {\r
+  UINT64   f2[2];\r
+  UINT64   f3[2];\r
+  UINT64   f4[2];\r
+  UINT64   f5[2];\r
+  UINT64   f6[2];\r
+  UINT64   f7[2];\r
+  UINT64   f8[2];\r
+  UINT64   f9[2];\r
+  UINT64   f10[2];\r
+  UINT64   f11[2];\r
+  UINT64   f12[2];\r
+  UINT64   f13[2];\r
+  UINT64   f14[2];\r
+  UINT64   f15[2];\r
+  UINT64   f16[2];\r
+  UINT64   f17[2];\r
+  UINT64   f18[2];\r
+  UINT64   f19[2];\r
+  UINT64   f20[2];\r
+  UINT64   f21[2];\r
+  UINT64   f22[2];\r
+  UINT64   f23[2];\r
+  UINT64   f24[2];\r
+  UINT64   f25[2];\r
+  UINT64   f26[2];\r
+  UINT64   f27[2];\r
+  UINT64   f28[2];\r
+  UINT64   f29[2];\r
+  UINT64   f30[2];\r
+  UINT64   f31[2];\r
+} EFI_PMI_OPTIONAL_FLOATING_POINT_CONTEXT;\r
+\r
+typedef union {\r
+  EFI_SMI_OPTIONAL_FPSAVE_STATE             Ia32FpSave;\r
+  EFI_PMI_OPTIONAL_FLOATING_POINT_CONTEXT   ItaniumFpSave;\r
+} EFI_SMM_FLOATING_POINT_SAVE_STATE;\r
+\r
+/**\r
+  This function is the main entry point for an SMM handler dispatch\r
+  or communicate-based callback.\r
+\r
+  @param  SmmImageHandle   A unique value returned by the SMM infrastructure\r
+                           in response to registration for a communicate-based callback or dispatch.\r
+  @param  CommunicationBuffer\r
+                           An optional buffer that will be populated\r
+                           by the SMM infrastructure in response to a non-SMM agent (preboot or runtime)\r
+                           invoking the EFI_SMM_BASE_PROTOCOL.Communicate() service.\r
+  @param  SourceSize       If CommunicationBuffer is non-NULL, this field\r
+                           indicates the size of the data payload in this buffer.\r
+\r
+  @return Status Code\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_SMM_HANDLER_ENTRY_POINT) (\r
+  IN EFI_HANDLE             SmmImageHandle,\r
+  IN OUT VOID               *CommunicationBuffer OPTIONAL,\r
+  IN OUT UINTN              *SourceSize OPTIONAL\r
+  );\r
+\r
+/**\r
+  The SmmInstallConfigurationTable() function is used to maintain the list\r
+  of configuration tables that are stored in the System Management System\r
+  Table.  The list is stored as an array of (GUID, Pointer) pairs.  The list\r
+  must be allocated from pool memory with PoolType set to EfiRuntimeServicesData.\r
+\r
+  @param  SystemTable      A pointer to the SMM System Table.\r
+  @param  Guid             A pointer to the GUID for the entry to add, update, or remove.\r
+  @param  Table            A pointer to the buffer of the table to add.\r
+  @param  TableSize        The size of the table to install.\r
+\r
+  @retval EFI_SUCCESS           The (Guid, Table) pair was added, updated, or removed.\r
+  @retval EFI_INVALID_PARAMETER Guid is not valid.\r
+  @retval EFI_NOT_FOUND         An attempt was made to delete a non-existent entry.\r
+  @retval EFI_OUT_OF_RESOURCES  There is not enough memory available to complete the operation.\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_SMM_INSTALL_CONFIGURATION_TABLE) (\r
+  IN EFI_SMM_SYSTEM_TABLE         *SystemTable,\r
+  IN EFI_GUID                     *Guid,\r
+  IN VOID                         *Table,\r
+  IN UINTN                        TableSize\r
+  );\r
+\r
+//\r
+// System Management System Table (SMST)\r
+//\r
+struct _EFI_SMM_SYSTEM_TABLE {\r
+  EFI_TABLE_HEADER                    Hdr;\r
+\r
+  CHAR16                              *SmmFirmwareVendor;\r
+  UINT32                              SmmFirmwareRevision;\r
+\r
+  EFI_SMM_INSTALL_CONFIGURATION_TABLE SmmInstallConfigurationTable;\r
+\r
+  //\r
+  // I/O Services\r
+  //\r
+  EFI_GUID                            EfiSmmCpuIoGuid;\r
+  EFI_SMM_CPU_IO_INTERFACE            SmmIo;\r
+\r
+  //\r
+  // Runtime memory service\r
+  //\r
+  EFI_SMMCORE_ALLOCATE_POOL           SmmAllocatePool;\r
+  EFI_SMMCORE_FREE_POOL               SmmFreePool;\r
+  EFI_SMMCORE_ALLOCATE_PAGES          SmmAllocatePages;\r
+  EFI_SMMCORE_FREE_PAGES              SmmFreePages;\r
+\r
+  //\r
+  // MP service\r
+  //\r
+  EFI_SMM_STARTUP_THIS_AP             SmmStartupThisAp;\r
+\r
+  //\r
+  // CPU information records\r
+  //\r
+  UINTN                               CurrentlyExecutingCpu;\r
+  UINTN                               NumberOfCpus;\r
+  EFI_SMM_CPU_SAVE_STATE              *CpuSaveState;\r
+  EFI_SMM_FLOATING_POINT_SAVE_STATE   *CpuOptionalFloatingPointState;\r
+\r
+  //\r
+  // Extensibility table\r
+  //\r
+  UINTN                               NumberOfTableEntries;\r
+  EFI_CONFIGURATION_TABLE             *SmmConfigurationTable;\r
+};\r
+\r
+#endif\r
diff --git a/IntelFrameworkPkg/Include/Common/FrameworkStatusCode.h b/IntelFrameworkPkg/Include/Common/FrameworkStatusCode.h
new file mode 100644 (file)
index 0000000..dccb951
--- /dev/null
@@ -0,0 +1,904 @@
+/** @file\r
+  Status Code Definitions, according to Intel Platform Innovation Framework\r
+  for EFI Status Codes Specification\r
+\r
+  The file is divided into sections for ease of use.\r
+\r
+<pre>\r
+  Section:    Contents:\r
+  1           General Status Code Definitions\r
+  2           Class definitions\r
+  3           Computing Unit Subclasses, Progress and Error Codes\r
+  4           Peripheral Subclasses, Progress and Error Codes.\r
+  5           IO Bus Subclasses, Progress and Error Codes.\r
+  6           Software Subclasses, Progress and Error Codes.\r
+  7           Debug Codes\r
+</pre>\r
+\r
+  Copyright (c) 2007, Intel Corporation\r
+  All rights reserved. This program and the accompanying materials\r
+  are licensed and made available under the terms and conditions of the BSD License\r
+  which accompanies this distribution.  The full text of the license may be found at\r
+  http://opensource.org/licenses/bsd-license.php\r
+\r
+  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
+  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
+\r
+  Module Name:  StatusCode.h\r
+\r
+  @par Revision Reference:\r
+  Version 0.92.\r
+\r
+**/\r
+\r
+#ifndef _FRAMEWORK_STATUS_CODE_H_\r
+#define _FRAMEWORK_STATUS_CODE_H_\r
+\r
+\r
+//\r
+// /////////////////////////////////////////////////////////////////////////////\r
+// Section 1\r
+////////////////////////////////////////////////////////////////////////////////\r
+\r
+//\r
+// Data Hub Status Code class record definition\r
+// This structure isn't adopted by PI, so is defined here.\r
+//\r
+typedef struct {\r
+  EFI_STATUS_CODE_TYPE  CodeType;\r
+  EFI_STATUS_CODE_VALUE Value;\r
+  UINT32                Instance;\r
+  EFI_GUID              CallerId;\r
+  EFI_STATUS_CODE_DATA  Data;\r
+} DATA_HUB_STATUS_CODE_DATA_RECORD;\r
+\r
+//\r
+// /////////////////////////////////////////////////////////////////////////////\r
+// Section 2\r
+///////////////////////////////////////////////////////////////////////////////\r
+//\r
+// Class definitions\r
+// Values of 4-127 are reserved for future use by this\r
+// specification.\r
+// Values in the range 127-255 are reserved for OEM use.\r
+//\r
+#define EFI_COMPUTING_UNIT  0x00000000\r
+#define EFI_PERIPHERAL      0x01000000\r
+#define EFI_IO_BUS          0x02000000\r
+#define EFI_SOFTWARE        0x03000000\r
+\r
+//\r
+// General partitioning scheme for Progress and Error Codes are\r
+// 0x0000-0x0FFF  - Shared by all sub-classes in a given class\r
+// 0x1000-0x7FFF  - Subclass Specific\r
+// 0x8000-0xFFFF  - OEM specific\r
+//\r
+#define EFI_SUBCLASS_SPECIFIC 0x1000\r
+#define EFI_OEM_SPECIFIC      0x8000\r
+\r
+//\r
+// /////////////////////////////////////////////////////////////////////////////\r
+// Section 3\r
+///////////////////////////////////////////////////////////////////////////////\r
+//\r
+// Computing Unit Subclass definitions.\r
+// Values of 8-127 are reserved for future use by this\r
+// specification.\r
+// Values of 128-255 are reserved for OEM use.\r
+//\r
+#define EFI_COMPUTING_UNIT_UNSPECIFIED        (EFI_COMPUTING_UNIT | 0x00000000)\r
+#define EFI_COMPUTING_UNIT_HOST_PROCESSOR     (EFI_COMPUTING_UNIT | 0x00010000)\r
+#define EFI_COMPUTING_UNIT_FIRMWARE_PROCESSOR (EFI_COMPUTING_UNIT | 0x00020000)\r
+#define EFI_COMPUTING_UNIT_IO_PROCESSOR       (EFI_COMPUTING_UNIT | 0x00030000)\r
+#define EFI_COMPUTING_UNIT_CACHE              (EFI_COMPUTING_UNIT | 0x00040000)\r
+#define EFI_COMPUTING_UNIT_MEMORY             (EFI_COMPUTING_UNIT | 0x00050000)\r
+#define EFI_COMPUTING_UNIT_CHIPSET            (EFI_COMPUTING_UNIT | 0x00060000)\r
+\r
+//\r
+// Computing Unit Class Progress Code definitions.\r
+// These are shared by all subclasses.\r
+//\r
+#define EFI_CU_PC_INIT_BEGIN  0x00000000\r
+#define EFI_CU_PC_INIT_END    0x00000001\r
+\r
+//\r
+// Computing Unit Unspecified Subclass Progress Code definitions.\r
+//\r
+//\r
+// Computing Unit Host Processor Subclass Progress Code definitions.\r
+//\r
+#define EFI_CU_HP_PC_POWER_ON_INIT          (EFI_SUBCLASS_SPECIFIC | 0x00000000)\r
+#define EFI_CU_HP_PC_CACHE_INIT             (EFI_SUBCLASS_SPECIFIC | 0x00000001)\r
+#define EFI_CU_HP_PC_RAM_INIT               (EFI_SUBCLASS_SPECIFIC | 0x00000002)\r
+#define EFI_CU_HP_PC_MEMORY_CONTROLLER_INIT (EFI_SUBCLASS_SPECIFIC | 0x00000003)\r
+#define EFI_CU_HP_PC_IO_INIT                (EFI_SUBCLASS_SPECIFIC | 0x00000004)\r
+#define EFI_CU_HP_PC_BSP_SELECT             (EFI_SUBCLASS_SPECIFIC | 0x00000005)\r
+#define EFI_CU_HP_PC_BSP_RESELECT           (EFI_SUBCLASS_SPECIFIC | 0x00000006)\r
+#define EFI_CU_HP_PC_AP_INIT                (EFI_SUBCLASS_SPECIFIC | 0x00000007)\r
+#define EFI_CU_HP_PC_SMM_INIT               (EFI_SUBCLASS_SPECIFIC | 0x00000008)\r
+\r
+//\r
+// Computing Unit Firmware Processor Subclass Progress Code definitions.\r
+//\r
+//\r
+// Computing Unit IO Processor Subclass Progress Code definitions.\r
+//\r
+//\r
+// Computing Unit Cache Subclass Progress Code definitions.\r
+//\r
+#define EFI_CU_CACHE_PC_PRESENCE_DETECT (EFI_SUBCLASS_SPECIFIC | 0x00000000)\r
+#define EFI_CU_CACHE_PC_CONFIGURATION   (EFI_SUBCLASS_SPECIFIC | 0x00000001)\r
+\r
+//\r
+// Computing Unit Memory Subclass Progress Code definitions.\r
+//\r
+#define EFI_CU_MEMORY_PC_SPD_READ         (EFI_SUBCLASS_SPECIFIC | 0x00000000)\r
+#define EFI_CU_MEMORY_PC_PRESENCE_DETECT  (EFI_SUBCLASS_SPECIFIC | 0x00000001)\r
+#define EFI_CU_MEMORY_PC_TIMING           (EFI_SUBCLASS_SPECIFIC | 0x00000002)\r
+#define EFI_CU_MEMORY_PC_CONFIGURING      (EFI_SUBCLASS_SPECIFIC | 0x00000003)\r
+#define EFI_CU_MEMORY_PC_OPTIMIZING       (EFI_SUBCLASS_SPECIFIC | 0x00000004)\r
+#define EFI_CU_MEMORY_PC_INIT             (EFI_SUBCLASS_SPECIFIC | 0x00000005)\r
+#define EFI_CU_MEMORY_PC_TEST             (EFI_SUBCLASS_SPECIFIC | 0x00000006)\r
+\r
+//\r
+// Computing Unit Chipset Subclass Progress Code definitions.\r
+//\r
+//\r
+// Computing Unit Class Error Code definitions.\r
+// These are shared by all subclasses.\r
+//\r
+#define EFI_CU_EC_NON_SPECIFIC    0x00000000\r
+#define EFI_CU_EC_DISABLED        0x00000001\r
+#define EFI_CU_EC_NOT_SUPPORTED   0x00000002\r
+#define EFI_CU_EC_NOT_DETECTED    0x00000003\r
+#define EFI_CU_EC_NOT_CONFIGURED  0x00000004\r
+\r
+//\r
+// Computing Unit Unspecified Subclass Error Code definitions.\r
+//\r
+//\r
+// Computing Unit Host Processor Subclass Error Code definitions.\r
+//\r
+#define EFI_CU_HP_EC_INVALID_TYPE         (EFI_SUBCLASS_SPECIFIC | 0x00000000)\r
+#define EFI_CU_HP_EC_INVALID_SPEED        (EFI_SUBCLASS_SPECIFIC | 0x00000001)\r
+#define EFI_CU_HP_EC_MISMATCH             (EFI_SUBCLASS_SPECIFIC | 0x00000002)\r
+#define EFI_CU_HP_EC_TIMER_EXPIRED        (EFI_SUBCLASS_SPECIFIC | 0x00000003)\r
+#define EFI_CU_HP_EC_SELF_TEST            (EFI_SUBCLASS_SPECIFIC | 0x00000004)\r
+#define EFI_CU_HP_EC_INTERNAL             (EFI_SUBCLASS_SPECIFIC | 0x00000005)\r
+#define EFI_CU_HP_EC_THERMAL              (EFI_SUBCLASS_SPECIFIC | 0x00000006)\r
+#define EFI_CU_HP_EC_LOW_VOLTAGE          (EFI_SUBCLASS_SPECIFIC | 0x00000007)\r
+#define EFI_CU_HP_EC_HIGH_VOLTAGE         (EFI_SUBCLASS_SPECIFIC | 0x00000008)\r
+#define EFI_CU_HP_EC_CACHE                (EFI_SUBCLASS_SPECIFIC | 0x00000009)\r
+#define EFI_CU_HP_EC_MICROCODE_UPDATE     (EFI_SUBCLASS_SPECIFIC | 0x0000000A)\r
+#define EFI_CU_HP_EC_CORRECTABLE          (EFI_SUBCLASS_SPECIFIC | 0x0000000B)\r
+#define EFI_CU_HP_EC_UNCORRECTABLE        (EFI_SUBCLASS_SPECIFIC | 0x0000000C)\r
+#define EFI_CU_HP_EC_NO_MICROCODE_UPDATE  (EFI_SUBCLASS_SPECIFIC | 0x0000000D)\r
+\r
+//\r
+// Computing Unit Firmware Processor Subclass Error Code definitions.\r
+//\r
+#define EFI_CU_FP_EC_HARD_FAIL  (EFI_SUBCLASS_SPECIFIC | 0x00000000)\r
+#define EFI_CU_FP_EC_SOFT_FAIL  (EFI_SUBCLASS_SPECIFIC | 0x00000001)\r
+#define EFI_CU_FP_EC_COMM_ERROR (EFI_SUBCLASS_SPECIFIC | 0x00000002)\r
+\r
+//\r
+// Computing Unit IO Processor Subclass Error Code definitions.\r
+//\r
+//\r
+// Computing Unit Cache Subclass Error Code definitions.\r
+//\r
+#define EFI_CU_CACHE_EC_INVALID_TYPE  (EFI_SUBCLASS_SPECIFIC | 0x00000000)\r
+#define EFI_CU_CACHE_EC_INVALID_SPEED (EFI_SUBCLASS_SPECIFIC | 0x00000001)\r
+#define EFI_CU_CACHE_EC_INVALID_SIZE  (EFI_SUBCLASS_SPECIFIC | 0x00000002)\r
+#define EFI_CU_CACHE_EC_MISMATCH      (EFI_SUBCLASS_SPECIFIC | 0x00000003)\r
+\r
+//\r
+// Computing Unit Memory Subclass Error Code definitions.\r
+//\r
+#define EFI_CU_MEMORY_EC_INVALID_TYPE   (EFI_SUBCLASS_SPECIFIC | 0x00000000)\r
+#define EFI_CU_MEMORY_EC_INVALID_SPEED  (EFI_SUBCLASS_SPECIFIC | 0x00000001)\r
+#define EFI_CU_MEMORY_EC_CORRECTABLE    (EFI_SUBCLASS_SPECIFIC | 0x00000002)\r
+#define EFI_CU_MEMORY_EC_UNCORRECTABLE  (EFI_SUBCLASS_SPECIFIC | 0x00000003)\r
+#define EFI_CU_MEMORY_EC_SPD_FAIL       (EFI_SUBCLASS_SPECIFIC | 0x00000004)\r
+#define EFI_CU_MEMORY_EC_INVALID_SIZE   (EFI_SUBCLASS_SPECIFIC | 0x00000005)\r
+#define EFI_CU_MEMORY_EC_MISMATCH       (EFI_SUBCLASS_SPECIFIC | 0x00000006)\r
+#define EFI_CU_MEMORY_EC_S3_RESUME_FAIL (EFI_SUBCLASS_SPECIFIC | 0x00000007)\r
+#define EFI_CU_MEMORY_EC_UPDATE_FAIL    (EFI_SUBCLASS_SPECIFIC | 0x00000008)\r
+#define EFI_CU_MEMORY_EC_NONE_DETECTED  (EFI_SUBCLASS_SPECIFIC | 0x00000009)\r
+#define EFI_CU_MEMORY_EC_NONE_USEFUL    (EFI_SUBCLASS_SPECIFIC | 0x0000000A)\r
+\r
+//\r
+// Computing Unit Chipset Subclass Error Code definitions.\r
+//\r
+\r
+///////////////////////////////////////////////////////////////////////////////\r
+// Section 4\r
+///////////////////////////////////////////////////////////////////////////////\r
+//\r
+// Peripheral Subclass definitions.\r
+// Values of 12-127 are reserved for future use by this\r
+// specification.\r
+// Values of 128-255 are reserved for OEM use.\r
+//\r
+#define EFI_PERIPHERAL_UNSPECIFIED      (EFI_PERIPHERAL | 0x00000000)\r
+#define EFI_PERIPHERAL_KEYBOARD         (EFI_PERIPHERAL | 0x00010000)\r
+#define EFI_PERIPHERAL_MOUSE            (EFI_PERIPHERAL | 0x00020000)\r
+#define EFI_PERIPHERAL_LOCAL_CONSOLE    (EFI_PERIPHERAL | 0x00030000)\r
+#define EFI_PERIPHERAL_REMOTE_CONSOLE   (EFI_PERIPHERAL | 0x00040000)\r
+#define EFI_PERIPHERAL_SERIAL_PORT      (EFI_PERIPHERAL | 0x00050000)\r
+#define EFI_PERIPHERAL_PARALLEL_PORT    (EFI_PERIPHERAL | 0x00060000)\r
+#define EFI_PERIPHERAL_FIXED_MEDIA      (EFI_PERIPHERAL | 0x00070000)\r
+#define EFI_PERIPHERAL_REMOVABLE_MEDIA  (EFI_PERIPHERAL | 0x00080000)\r
+#define EFI_PERIPHERAL_AUDIO_INPUT      (EFI_PERIPHERAL | 0x00090000)\r
+#define EFI_PERIPHERAL_AUDIO_OUTPUT     (EFI_PERIPHERAL | 0x000A0000)\r
+#define EFI_PERIPHERAL_LCD_DEVICE       (EFI_PERIPHERAL | 0x000B0000)\r
+#define EFI_PERIPHERAL_NETWORK          (EFI_PERIPHERAL | 0x000C0000)\r
+\r
+//\r
+// Peripheral Class Progress Code definitions.\r
+// These are shared by all subclasses.\r
+//\r
+#define EFI_P_PC_INIT             0x00000000\r
+#define EFI_P_PC_RESET            0x00000001\r
+#define EFI_P_PC_DISABLE          0x00000002\r
+#define EFI_P_PC_PRESENCE_DETECT  0x00000003\r
+#define EFI_P_PC_ENABLE           0x00000004\r
+#define EFI_P_PC_RECONFIG         0x00000005\r
+#define EFI_P_PC_DETECTED         0x00000006\r
+\r
+//\r
+// Peripheral Class Unspecified Subclass Progress Code definitions.\r
+//\r
+//\r
+// Peripheral Class Keyboard Subclass Progress Code definitions.\r
+//\r
+#define EFI_P_KEYBOARD_PC_CLEAR_BUFFER  (EFI_SUBCLASS_SPECIFIC | 0x00000000)\r
+#define EFI_P_KEYBOARD_PC_SELF_TEST     (EFI_SUBCLASS_SPECIFIC | 0x00000001)\r
+\r
+//\r
+// Peripheral Class Mouse Subclass Progress Code definitions.\r
+//\r
+#define EFI_P_MOUSE_PC_SELF_TEST  (EFI_SUBCLASS_SPECIFIC | 0x00000000)\r
+\r
+//\r
+// Peripheral Class Local Console Subclass Progress Code definitions.\r
+//\r
+//\r
+// Peripheral Class Remote Console Subclass Progress Code definitions.\r
+//\r
+//\r
+// Peripheral Class Serial Port Subclass Progress Code definitions.\r
+//\r
+#define EFI_P_SERIAL_PORT_PC_CLEAR_BUFFER (EFI_SUBCLASS_SPECIFIC | 0x00000000)\r
+\r
+//\r
+// Peripheral Class Parallel Port Subclass Progress Code definitions.\r
+//\r
+//\r
+// Peripheral Class Fixed Media Subclass Progress Code definitions.\r
+//\r
+//\r
+// Peripheral Class Removable Media Subclass Progress Code definitions.\r
+//\r
+//\r
+// Peripheral Class Audio Input Subclass Progress Code definitions.\r
+//\r
+//\r
+// Peripheral Class Audio Output Subclass Progress Code definitions.\r
+//\r
+//\r
+// Peripheral Class LCD Device Subclass Progress Code definitions.\r
+//\r
+//\r
+// Peripheral Class Network Subclass Progress Code definitions.\r
+//\r
+//\r
+// Peripheral Class Error Code definitions.\r
+// These are shared by all subclasses.\r
+//\r
+#define EFI_P_EC_NON_SPECIFIC       0x00000000\r
+#define EFI_P_EC_DISABLED           0x00000001\r
+#define EFI_P_EC_NOT_SUPPORTED      0x00000002\r
+#define EFI_P_EC_NOT_DETECTED       0x00000003\r
+#define EFI_P_EC_NOT_CONFIGURED     0x00000004\r
+#define EFI_P_EC_INTERFACE_ERROR    0x00000005\r
+#define EFI_P_EC_CONTROLLER_ERROR   0x00000006\r
+#define EFI_P_EC_INPUT_ERROR        0x00000007\r
+#define EFI_P_EC_OUTPUT_ERROR       0x00000008\r
+#define EFI_P_EC_RESOURCE_CONFLICT  0x00000009\r
+\r
+//\r
+// Peripheral Class Unspecified Subclass Error Code definitions.\r
+//\r
+//\r
+// Peripheral Class Keyboard Subclass Error Code definitions.\r
+//\r
+#define EFI_P_KEYBOARD_EC_LOCKED    (EFI_SUBCLASS_SPECIFIC | 0x00000000)\r
+#define EFI_P_KEYBOARD_EC_STUCK_KEY (EFI_SUBCLASS_SPECIFIC | 0x00000001)\r
+\r
+//\r
+// Peripheral Class Mouse Subclass Error Code definitions.\r
+//\r
+#define EFI_P_MOUSE_EC_LOCKED (EFI_SUBCLASS_SPECIFIC | 0x00000000)\r
+\r
+//\r
+// Peripheral Class Local Console Subclass Error Code definitions.\r
+//\r
+//\r
+// Peripheral Class Remote Console Subclass Error Code definitions.\r
+//\r
+//\r
+// Peripheral Class Serial Port Subclass Error Code definitions.\r
+//\r
+//\r
+// Peripheral Class Parallel Port Subclass Error Code definitions.\r
+//\r
+//\r
+// Peripheral Class Fixed Media Subclass Error Code definitions.\r
+//\r
+//\r
+// Peripheral Class Removable Media Subclass Error Code definitions.\r
+//\r
+//\r
+// Peripheral Class Audio Input Subclass Error Code definitions.\r
+//\r
+//\r
+// Peripheral Class Audio Output Subclass Error Code definitions.\r
+//\r
+//\r
+// Peripheral Class LCD Device Subclass Error Code definitions.\r
+//\r
+//\r
+// Peripheral Class Network Subclass Error Code definitions.\r
+//\r
+\r
+///////////////////////////////////////////////////////////////////////////////\r
+// Section 5\r
+///////////////////////////////////////////////////////////////////////////////\r
+//\r
+// IO Bus Subclass definitions.\r
+// Values of 14-127 are reserved for future use by this\r
+// specification.\r
+// Values of 128-255 are reserved for OEM use.\r
+//\r
+#define EFI_IO_BUS_UNSPECIFIED  (EFI_IO_BUS | 0x00000000)\r
+#define EFI_IO_BUS_PCI          (EFI_IO_BUS | 0x00010000)\r
+#define EFI_IO_BUS_USB          (EFI_IO_BUS | 0x00020000)\r
+#define EFI_IO_BUS_IBA          (EFI_IO_BUS | 0x00030000)\r
+#define EFI_IO_BUS_AGP          (EFI_IO_BUS | 0x00040000)\r
+#define EFI_IO_BUS_PC_CARD      (EFI_IO_BUS | 0x00050000)\r
+#define EFI_IO_BUS_LPC          (EFI_IO_BUS | 0x00060000)\r
+#define EFI_IO_BUS_SCSI         (EFI_IO_BUS | 0x00070000)\r
+#define EFI_IO_BUS_ATA_ATAPI    (EFI_IO_BUS | 0x00080000)\r
+#define EFI_IO_BUS_FC           (EFI_IO_BUS | 0x00090000)\r
+#define EFI_IO_BUS_IP_NETWORK   (EFI_IO_BUS | 0x000A0000)\r
+#define EFI_IO_BUS_SMBUS        (EFI_IO_BUS | 0x000B0000)\r
+#define EFI_IO_BUS_I2C          (EFI_IO_BUS | 0x000C0000)\r
+\r
+//\r
+// IO Bus Class Progress Code definitions.\r
+// These are shared by all subclasses.\r
+//\r
+#define EFI_IOB_PC_INIT     0x00000000\r
+#define EFI_IOB_PC_RESET    0x00000001\r
+#define EFI_IOB_PC_DISABLE  0x00000002\r
+#define EFI_IOB_PC_DETECT   0x00000003\r
+#define EFI_IOB_PC_ENABLE   0x00000004\r
+#define EFI_IOB_PC_RECONFIG 0x00000005\r
+#define EFI_IOB_PC_HOTPLUG  0x00000006\r
+\r
+//\r
+// IO Bus Class Unspecified Subclass Progress Code definitions.\r
+//\r
+//\r
+// IO Bus Class PCI Subclass Progress Code definitions.\r
+//\r
+#define EFI_IOB_PCI_PC_BUS_ENUM   (EFI_SUBCLASS_SPECIFIC | 0x00000000)\r
+#define EFI_IOB_PCI_PC_RES_ALLOC  (EFI_SUBCLASS_SPECIFIC | 0x00000001)\r
+#define EFI_IOB_PCI_PC_HPC_INIT   (EFI_SUBCLASS_SPECIFIC | 0x00000002)\r
+\r
+//\r
+// IO Bus Class USB Subclass Progress Code definitions.\r
+//\r
+//\r
+// IO Bus Class IBA Subclass Progress Code definitions.\r
+//\r
+//\r
+// IO Bus Class AGP Subclass Progress Code definitions.\r
+//\r
+//\r
+// IO Bus Class PC Card Subclass Progress Code definitions.\r
+//\r
+//\r
+// IO Bus Class LPC Subclass Progress Code definitions.\r
+//\r
+//\r
+// IO Bus Class SCSI Subclass Progress Code definitions.\r
+//\r
+//\r
+// IO Bus Class ATA/ATAPI Subclass Progress Code definitions.\r
+//\r
+#define EFI_IOB_ATA_BUS_SMART_ENABLE          (EFI_SUBCLASS_SPECIFIC | 0x00000000)\r
+#define EFI_IOB_ATA_BUS_SMART_DISABLE         (EFI_SUBCLASS_SPECIFIC | 0x00000001)\r
+#define EFI_IOB_ATA_BUS_SMART_OVERTHRESHOLD   (EFI_SUBCLASS_SPECIFIC | 0x00000002)\r
+#define EFI_IOB_ATA_BUS_SMART_UNDERTHRESHOLD  (EFI_SUBCLASS_SPECIFIC | 0x00000003)\r
+\r
+//\r
+// IO Bus Class FC Subclass Progress Code definitions.\r
+//\r
+//\r
+// IO Bus Class IP Network Subclass Progress Code definitions.\r
+//\r
+//\r
+// IO Bus Class SMBUS Subclass Progress Code definitions.\r
+//\r
+//\r
+// IO Bus Class I2C Subclass Progress Code definitions.\r
+//\r
+//\r
+// IO Bus Class Error Code definitions.\r
+// These are shared by all subclasses.\r
+//\r
+#define EFI_IOB_EC_NON_SPECIFIC       0x00000000\r
+#define EFI_IOB_EC_DISABLED           0x00000001\r
+#define EFI_IOB_EC_NOT_SUPPORTED      0x00000002\r
+#define EFI_IOB_EC_NOT_DETECTED       0x00000003\r
+#define EFI_IOB_EC_NOT_CONFIGURED     0x00000004\r
+#define EFI_IOB_EC_INTERFACE_ERROR    0x00000005\r
+#define EFI_IOB_EC_CONTROLLER_ERROR   0x00000006\r
+#define EFI_IOB_EC_READ_ERROR         0x00000007\r
+#define EFI_IOB_EC_WRITE_ERROR        0x00000008\r
+#define EFI_IOB_EC_RESOURCE_CONFLICT  0x00000009\r
+\r
+//\r
+// IO Bus Class Unspecified Subclass Error Code definitions.\r
+//\r
+//\r
+// IO Bus Class PCI Subclass Error Code definitions.\r
+//\r
+#define EFI_IOB_PCI_EC_PERR (EFI_SUBCLASS_SPECIFIC | 0x00000000)\r
+#define EFI_IOB_PCI_EC_SERR (EFI_SUBCLASS_SPECIFIC | 0x00000001)\r
+\r
+//\r
+// IO Bus Class USB Subclass Error Code definitions.\r
+//\r
+//\r
+// IO Bus Class IBA Subclass Error Code definitions.\r
+//\r
+//\r
+// IO Bus Class AGP Subclass Error Code definitions.\r
+//\r
+//\r
+// IO Bus Class PC Card Subclass Error Code definitions.\r
+//\r
+//\r
+// IO Bus Class LPC Subclass Error Code definitions.\r
+//\r
+//\r
+// IO Bus Class SCSI Subclass Error Code definitions.\r
+//\r
+//\r
+// IO Bus Class ATA/ATAPI Subclass Error Code definitions.\r
+//\r
+#define EFI_IOB_ATA_BUS_SMART_NOTSUPPORTED  (EFI_SUBCLASS_SPECIFIC | 0x00000000)\r
+#define EFI_IOB_ATA_BUS_SMART_DISABLED      (EFI_SUBCLASS_SPECIFIC | 0x00000001)\r
+\r
+//\r
+// IO Bus Class FC Subclass Error Code definitions.\r
+//\r
+//\r
+// IO Bus Class IP Network Subclass Error Code definitions.\r
+//\r
+//\r
+// IO Bus Class SMBUS Subclass Error Code definitions.\r
+//\r
+//\r
+// IO Bus Class I2C Subclass Error Code definitions.\r
+//\r
+\r
+///////////////////////////////////////////////////////////////////////////////\r
+// Section 6\r
+///////////////////////////////////////////////////////////////////////////////\r
+//\r
+// Software Subclass definitions.\r
+// Values of 14-127 are reserved for future use by this\r
+// specification.\r
+// Values of 128-255 are reserved for OEM use.\r
+//\r
+#define EFI_SOFTWARE_UNSPECIFIED          (EFI_SOFTWARE | 0x00000000)\r
+#define EFI_SOFTWARE_SEC                  (EFI_SOFTWARE | 0x00010000)\r
+#define EFI_SOFTWARE_PEI_CORE             (EFI_SOFTWARE | 0x00020000)\r
+#define EFI_SOFTWARE_PEI_MODULE           (EFI_SOFTWARE | 0x00030000)\r
+#define EFI_SOFTWARE_DXE_CORE             (EFI_SOFTWARE | 0x00040000)\r
+#define EFI_SOFTWARE_DXE_BS_DRIVER        (EFI_SOFTWARE | 0x00050000)\r
+#define EFI_SOFTWARE_DXE_RT_DRIVER        (EFI_SOFTWARE | 0x00060000)\r
+#define EFI_SOFTWARE_SMM_DRIVER           (EFI_SOFTWARE | 0x00070000)\r
+#define EFI_SOFTWARE_EFI_APPLICATION      (EFI_SOFTWARE | 0x00080000)\r
+#define EFI_SOFTWARE_EFI_OS_LOADER        (EFI_SOFTWARE | 0x00090000)\r
+#define EFI_SOFTWARE_RT                   (EFI_SOFTWARE | 0x000A0000)\r
+#define EFI_SOFTWARE_AL                   (EFI_SOFTWARE | 0x000B0000)\r
+#define EFI_SOFTWARE_EBC_EXCEPTION        (EFI_SOFTWARE | 0x000C0000)\r
+#define EFI_SOFTWARE_IA32_EXCEPTION       (EFI_SOFTWARE | 0x000D0000)\r
+#define EFI_SOFTWARE_IPF_EXCEPTION        (EFI_SOFTWARE | 0x000E0000)\r
+#define EFI_SOFTWARE_PEI_SERVICE          (EFI_SOFTWARE | 0x000F0000)\r
+#define EFI_SOFTWARE_EFI_BOOT_SERVICE     (EFI_SOFTWARE | 0x00100000)\r
+#define EFI_SOFTWARE_EFI_RUNTIME_SERVICE  (EFI_SOFTWARE | 0x00110000)\r
+#define EFI_SOFTWARE_EFI_DXE_SERVICE      (EFI_SOFTWARE | 0x00120000)\r
+#define EFI_SOFTWARE_X64_EXCEPTION        (EFI_SOFTWARE | 0x00130000)\r
+\r
+//\r
+// Software Class Progress Code definitions.\r
+// These are shared by all subclasses.\r
+//\r
+#define EFI_SW_PC_INIT                0x00000000\r
+#define EFI_SW_PC_LOAD                0x00000001\r
+#define EFI_SW_PC_INIT_BEGIN          0x00000002\r
+#define EFI_SW_PC_INIT_END            0x00000003\r
+#define EFI_SW_PC_AUTHENTICATE_BEGIN  0x00000004\r
+#define EFI_SW_PC_AUTHENTICATE_END    0x00000005\r
+#define EFI_SW_PC_INPUT_WAIT          0x00000006\r
+#define EFI_SW_PC_USER_SETUP          0x00000007\r
+\r
+//\r
+// Software Class Unspecified Subclass Progress Code definitions.\r
+//\r
+//\r
+// Software Class SEC Subclass Progress Code definitions.\r
+//\r
+#define EFI_SW_SEC_PC_ENTRY_POINT     (EFI_SUBCLASS_SPECIFIC | 0x00000000)\r
+#define EFI_SW_SEC_PC_HANDOFF_TO_NEXT (EFI_SUBCLASS_SPECIFIC | 0x00000001)\r
+\r
+//\r
+// Software Class PEI Core Subclass Progress Code definitions.\r
+//\r
+#define EFI_SW_PEI_CORE_PC_ENTRY_POINT      (EFI_SUBCLASS_SPECIFIC | 0x00000000)\r
+#define EFI_SW_PEI_CORE_PC_HANDOFF_TO_NEXT  (EFI_SUBCLASS_SPECIFIC | 0x00000001)\r
+#define EFI_SW_PEI_CORE_PC_RETURN_TO_LAST   (EFI_SUBCLASS_SPECIFIC | 0x00000002)\r
+\r
+//\r
+// Software Class PEI Module Subclass Progress Code definitions.\r
+//\r
+#define EFI_SW_PEIM_PC_RECOVERY_BEGIN (EFI_SUBCLASS_SPECIFIC | 0x00000000)\r
+#define EFI_SW_PEIM_PC_CAPSULE_LOAD   (EFI_SUBCLASS_SPECIFIC | 0x00000001)\r
+#define EFI_SW_PEIM_PC_CAPSULE_START  (EFI_SUBCLASS_SPECIFIC | 0x00000002)\r
+#define EFI_SW_PEIM_PC_RECOVERY_USER  (EFI_SUBCLASS_SPECIFIC | 0x00000003)\r
+#define EFI_SW_PEIM_PC_RECOVERY_AUTO  (EFI_SUBCLASS_SPECIFIC | 0x00000004)\r
+\r
+//\r
+// Software Class DXE Core Subclass Progress Code definitions.\r
+//\r
+#define EFI_SW_DXE_CORE_PC_ENTRY_POINT      (EFI_SUBCLASS_SPECIFIC | 0x00000000)\r
+#define EFI_SW_DXE_CORE_PC_HANDOFF_TO_NEXT  (EFI_SUBCLASS_SPECIFIC | 0x00000001)\r
+#define EFI_SW_DXE_CORE_PC_RETURN_TO_LAST   (EFI_SUBCLASS_SPECIFIC | 0x00000002)\r
+#define EFI_SW_DXE_CORE_PC_START_DRIVER     (EFI_SUBCLASS_SPECIFIC | 0x00000003)\r
+\r
+//\r
+// Software Class DXE BS Driver Subclass Progress Code definitions.\r
+//\r
+#define EFI_SW_DXE_BS_PC_LEGACY_OPROM_INIT            (EFI_SUBCLASS_SPECIFIC | 0x00000000)\r
+#define EFI_SW_DXE_BS_PC_READY_TO_BOOT_EVENT          (EFI_SUBCLASS_SPECIFIC | 0x00000001)\r
+#define EFI_SW_DXE_BS_PC_LEGACY_BOOT_EVENT            (EFI_SUBCLASS_SPECIFIC | 0x00000002)\r
+#define EFI_SW_DXE_BS_PC_EXIT_BOOT_SERVICES_EVENT     (EFI_SUBCLASS_SPECIFIC | 0x00000003)\r
+#define EFI_SW_DXE_BS_PC_VIRTUAL_ADDRESS_CHANGE_EVENT (EFI_SUBCLASS_SPECIFIC | 0x00000004)\r
+#define EFI_SW_DXE_BS_PC_BEGIN_CONNECTING_DRIVERS     (EFI_SUBCLASS_SPECIFIC | 0x00000005)\r
+#define EFI_SW_DXE_BS_PC_VERIFYING_PASSWORD           (EFI_SUBCLASS_SPECIFIC | 0x00000006)\r
+\r
+//\r
+// Software Class DXE RT Driver Subclass Progress Code definitions.\r
+//\r
+#define EFI_SW_DXE_RT_PC_S0 (EFI_SUBCLASS_SPECIFIC | 0x00000000)\r
+#define EFI_SW_DXE_RT_PC_S1 (EFI_SUBCLASS_SPECIFIC | 0x00000001)\r
+#define EFI_SW_DXE_RT_PC_S2 (EFI_SUBCLASS_SPECIFIC | 0x00000002)\r
+#define EFI_SW_DXE_RT_PC_S3 (EFI_SUBCLASS_SPECIFIC | 0x00000003)\r
+#define EFI_SW_DXE_RT_PC_S4 (EFI_SUBCLASS_SPECIFIC | 0x00000004)\r
+#define EFI_SW_DXE_RT_PC_S5 (EFI_SUBCLASS_SPECIFIC | 0x00000005)\r
+\r
+//\r
+// Software Class SMM Driver Subclass Progress Code definitions.\r
+//\r
+//\r
+// Software Class EFI Application Subclass Progress Code definitions.\r
+//\r
+//\r
+// Software Class EFI OS Loader Subclass Progress Code definitions.\r
+//\r
+//\r
+// Software Class EFI RT Subclass Progress Code definitions.\r
+//\r
+#define EFI_SW_RT_PC_ENTRY_POINT      (EFI_SUBCLASS_SPECIFIC | 0x00000000)\r
+#define EFI_SW_RT_PC_HANDOFF_TO_NEXT  (EFI_SUBCLASS_SPECIFIC | 0x00000001)\r
+#define EFI_SW_RT_PC_RETURN_TO_LAST   (EFI_SUBCLASS_SPECIFIC | 0x00000002)\r
+\r
+//\r
+// Software Class EFI AL Subclass Progress Code definitions.\r
+//\r
+#define EFI_SW_AL_PC_ENTRY_POINT    (EFI_SUBCLASS_SPECIFIC | 0x00000000)\r
+#define EFI_SW_AL_PC_RETURN_TO_LAST (EFI_SUBCLASS_SPECIFIC | 0x00000001)\r
+\r
+//\r
+// Software Class EBC Exception Subclass Progress Code definitions.\r
+//\r
+//\r
+// Software Class IA32 Exception Subclass Progress Code definitions.\r
+//\r
+//\r
+// Software Class X64 Exception Subclass Progress Code definitions.\r
+//\r
+//\r
+// Software Class IPF Exception Subclass Progress Code definitions.\r
+//\r
+//\r
+// Software Class PEI Services Subclass Progress Code definitions.\r
+//\r
+#define EFI_SW_PS_PC_INSTALL_PPI            (EFI_SUBCLASS_SPECIFIC | 0x00000000)\r
+#define EFI_SW_PS_PC_REINSTALL_PPI          (EFI_SUBCLASS_SPECIFIC | 0x00000001)\r
+#define EFI_SW_PS_PC_LOCATE_PPI             (EFI_SUBCLASS_SPECIFIC | 0x00000002)\r
+#define EFI_SW_PS_PC_NOTIFY_PPI             (EFI_SUBCLASS_SPECIFIC | 0x00000003)\r
+#define EFI_SW_PS_PC_GET_BOOT_MODE          (EFI_SUBCLASS_SPECIFIC | 0x00000004)\r
+#define EFI_SW_PS_PC_SET_BOOT_MODE          (EFI_SUBCLASS_SPECIFIC | 0x00000005)\r
+#define EFI_SW_PS_PC_GET_HOB_LIST           (EFI_SUBCLASS_SPECIFIC | 0x00000006)\r
+#define EFI_SW_PS_PC_CREATE_HOB             (EFI_SUBCLASS_SPECIFIC | 0x00000007)\r
+#define EFI_SW_PS_PC_FFS_FIND_NEXT_VOLUME   (EFI_SUBCLASS_SPECIFIC | 0x00000008)\r
+#define EFI_SW_PS_PC_FFS_FIND_NEXT_FILE     (EFI_SUBCLASS_SPECIFIC | 0x00000009)\r
+#define EFI_SW_PS_PC_FFS_FIND_SECTION_DATA  (EFI_SUBCLASS_SPECIFIC | 0x0000000A)\r
+#define EFI_SW_PS_PC_INSTALL_PEI_MEMORY     (EFI_SUBCLASS_SPECIFIC | 0x0000000B)\r
+#define EFI_SW_PS_PC_ALLOCATE_PAGES         (EFI_SUBCLASS_SPECIFIC | 0x0000000C)\r
+#define EFI_SW_PS_PC_ALLOCATE_POOL          (EFI_SUBCLASS_SPECIFIC | 0x0000000D)\r
+#define EFI_SW_PS_PC_COPY_MEM               (EFI_SUBCLASS_SPECIFIC | 0x0000000E)\r
+#define EFI_SW_PS_PC_SET_MEM                (EFI_SUBCLASS_SPECIFIC | 0x0000000F)\r
+\r
+//\r
+// Software Class EFI Boot Services Subclass Progress Code definitions.\r
+//\r
+#define EFI_SW_BS_PC_RAISE_TPL                      (EFI_SUBCLASS_SPECIFIC | 0x00000000)\r
+#define EFI_SW_BS_PC_RESTORE_TPL                    (EFI_SUBCLASS_SPECIFIC | 0x00000001)\r
+#define EFI_SW_BS_PC_ALLOCATE_PAGES                 (EFI_SUBCLASS_SPECIFIC | 0x00000002)\r
+#define EFI_SW_BS_PC_FREE_PAGES                     (EFI_SUBCLASS_SPECIFIC | 0x00000003)\r
+#define EFI_SW_BS_PC_GET_MEMORY_MAP                 (EFI_SUBCLASS_SPECIFIC | 0x00000004)\r
+#define EFI_SW_BS_PC_ALLOCATE_POOL                  (EFI_SUBCLASS_SPECIFIC | 0x00000005)\r
+#define EFI_SW_BS_PC_FREE_POOL                      (EFI_SUBCLASS_SPECIFIC | 0x00000006)\r
+#define EFI_SW_BS_PC_CREATE_EVENT                   (EFI_SUBCLASS_SPECIFIC | 0x00000007)\r
+#define EFI_SW_BS_PC_SET_TIMER                      (EFI_SUBCLASS_SPECIFIC | 0x00000008)\r
+#define EFI_SW_BS_PC_WAIT_FOR_EVENT                 (EFI_SUBCLASS_SPECIFIC | 0x00000009)\r
+#define EFI_SW_BS_PC_SIGNAL_EVENT                   (EFI_SUBCLASS_SPECIFIC | 0x0000000A)\r
+#define EFI_SW_BS_PC_CLOSE_EVENT                    (EFI_SUBCLASS_SPECIFIC | 0x0000000B)\r
+#define EFI_SW_BS_PC_CHECK_EVENT                    (EFI_SUBCLASS_SPECIFIC | 0x0000000C)\r
+#define EFI_SW_BS_PC_INSTALL_PROTOCOL_INTERFACE     (EFI_SUBCLASS_SPECIFIC | 0x0000000D)\r
+#define EFI_SW_BS_PC_REINSTALL_PROTOCOL_INTERFACE   (EFI_SUBCLASS_SPECIFIC | 0x0000000E)\r
+#define EFI_SW_BS_PC_UNINSTALL_PROTOCOL_INTERFACE   (EFI_SUBCLASS_SPECIFIC | 0x0000000F)\r
+#define EFI_SW_BS_PC_HANDLE_PROTOCOL                (EFI_SUBCLASS_SPECIFIC | 0x00000010)\r
+#define EFI_SW_BS_PC_PC_HANDLE_PROTOCOL             (EFI_SUBCLASS_SPECIFIC | 0x00000011)\r
+#define EFI_SW_BS_PC_REGISTER_PROTOCOL_NOTIFY       (EFI_SUBCLASS_SPECIFIC | 0x00000012)\r
+#define EFI_SW_BS_PC_LOCATE_HANDLE                  (EFI_SUBCLASS_SPECIFIC | 0x00000013)\r
+#define EFI_SW_BS_PC_INSTALL_CONFIGURATION_TABLE    (EFI_SUBCLASS_SPECIFIC | 0x00000014)\r
+#define EFI_SW_BS_PC_LOAD_IMAGE                     (EFI_SUBCLASS_SPECIFIC | 0x00000015)\r
+#define EFI_SW_BS_PC_START_IMAGE                    (EFI_SUBCLASS_SPECIFIC | 0x00000016)\r
+#define EFI_SW_BS_PC_EXIT                           (EFI_SUBCLASS_SPECIFIC | 0x00000017)\r
+#define EFI_SW_BS_PC_UNLOAD_IMAGE                   (EFI_SUBCLASS_SPECIFIC | 0x00000018)\r
+#define EFI_SW_BS_PC_EXIT_BOOT_SERVICES             (EFI_SUBCLASS_SPECIFIC | 0x00000019)\r
+#define EFI_SW_BS_PC_GET_NEXT_MONOTONIC_COUNT       (EFI_SUBCLASS_SPECIFIC | 0x0000001A)\r
+#define EFI_SW_BS_PC_STALL                          (EFI_SUBCLASS_SPECIFIC | 0x0000001B)\r
+#define EFI_SW_BS_PC_SET_WATCHDOG_TIMER             (EFI_SUBCLASS_SPECIFIC | 0x0000001C)\r
+#define EFI_SW_BS_PC_CONNECT_CONTROLLER             (EFI_SUBCLASS_SPECIFIC | 0x0000001D)\r
+#define EFI_SW_BS_PC_DISCONNECT_CONTROLLER          (EFI_SUBCLASS_SPECIFIC | 0x0000001E)\r
+#define EFI_SW_BS_PC_OPEN_PROTOCOL                  (EFI_SUBCLASS_SPECIFIC | 0x0000001F)\r
+#define EFI_SW_BS_PC_CLOSE_PROTOCOL                 (EFI_SUBCLASS_SPECIFIC | 0x00000020)\r
+#define EFI_SW_BS_PC_OPEN_PROTOCOL_INFORMATION      (EFI_SUBCLASS_SPECIFIC | 0x00000021)\r
+#define EFI_SW_BS_PC_PROTOCOLS_PER_HANDLE           (EFI_SUBCLASS_SPECIFIC | 0x00000022)\r
+#define EFI_SW_BS_PC_LOCATE_HANDLE_BUFFER           (EFI_SUBCLASS_SPECIFIC | 0x00000023)\r
+#define EFI_SW_BS_PC_LOCATE_PROTOCOL                (EFI_SUBCLASS_SPECIFIC | 0x00000024)\r
+#define EFI_SW_BS_PC_INSTALL_MULTIPLE_INTERFACES    (EFI_SUBCLASS_SPECIFIC | 0x00000025)\r
+#define EFI_SW_BS_PC_UNINSTALL_MULTIPLE_INTERFACES  (EFI_SUBCLASS_SPECIFIC | 0x00000026)\r
+#define EFI_SW_BS_PC_CALCULATE_CRC_32               (EFI_SUBCLASS_SPECIFIC | 0x00000027)\r
+#define EFI_SW_BS_PC_COPY_MEM                       (EFI_SUBCLASS_SPECIFIC | 0x00000028)\r
+#define EFI_SW_BS_PC_SET_MEM                        (EFI_SUBCLASS_SPECIFIC | 0x00000029)\r
+\r
+//\r
+// Software Class EFI Runtime Services Subclass Progress Code definitions.\r
+//\r
+#define EFI_SW_RS_PC_GET_TIME                       (EFI_SUBCLASS_SPECIFIC | 0x00000000)\r
+#define EFI_SW_RS_PC_SET_TIME                       (EFI_SUBCLASS_SPECIFIC | 0x00000001)\r
+#define EFI_SW_RS_PC_GET_WAKEUP_TIME                (EFI_SUBCLASS_SPECIFIC | 0x00000002)\r
+#define EFI_SW_RS_PC_SET_WAKEUP_TIME                (EFI_SUBCLASS_SPECIFIC | 0x00000003)\r
+#define EFI_SW_RS_PC_SET_VIRTUAL_ADDRESS_MAP        (EFI_SUBCLASS_SPECIFIC | 0x00000004)\r
+#define EFI_SW_RS_PC_CONVERT_POINTER                (EFI_SUBCLASS_SPECIFIC | 0x00000005)\r
+#define EFI_SW_RS_PC_GET_VARIABLE                   (EFI_SUBCLASS_SPECIFIC | 0x00000006)\r
+#define EFI_SW_RS_PC_GET_NEXT_VARIABLE_NAME         (EFI_SUBCLASS_SPECIFIC | 0x00000007)\r
+#define EFI_SW_RS_PC_SET_VARIABLE                   (EFI_SUBCLASS_SPECIFIC | 0x00000008)\r
+#define EFI_SW_RS_PC_GET_NEXT_HIGH_MONOTONIC_COUNT  (EFI_SUBCLASS_SPECIFIC | 0x00000009)\r
+#define EFI_SW_RS_PC_RESET_SYSTEM                   (EFI_SUBCLASS_SPECIFIC | 0x0000000A)\r
+\r
+//\r
+// Software Class EFI DXE Services Subclass Progress Code definitions\r
+//\r
+#define EFI_SW_DS_PC_ADD_MEMORY_SPACE             (EFI_SUBCLASS_SPECIFIC | 0x00000000)\r
+#define EFI_SW_DS_PC_ALLOCATE_MEMORY_SPACE        (EFI_SUBCLASS_SPECIFIC | 0x00000001)\r
+#define EFI_SW_DS_PC_FREE_MEMORY_SPACE            (EFI_SUBCLASS_SPECIFIC | 0x00000002)\r
+#define EFI_SW_DS_PC_REMOVE_MEMORY_SPACE          (EFI_SUBCLASS_SPECIFIC | 0x00000003)\r
+#define EFI_SW_DS_PC_GET_MEMORY_SPACE_DESCRIPTOR  (EFI_SUBCLASS_SPECIFIC | 0x00000004)\r
+#define EFI_SW_DS_PC_SET_MEMORY_SPACE_ATTRIBUTES  (EFI_SUBCLASS_SPECIFIC | 0x00000005)\r
+#define EFI_SW_DS_PC_GET_MEMORY_SPACE_MAP         (EFI_SUBCLASS_SPECIFIC | 0x00000006)\r
+#define EFI_SW_DS_PC_ADD_IO_SPACE                 (EFI_SUBCLASS_SPECIFIC | 0x00000007)\r
+#define EFI_SW_DS_PC_ALLOCATE_IO_SPACE            (EFI_SUBCLASS_SPECIFIC | 0x00000008)\r
+#define EFI_SW_DS_PC_FREE_IO_SPACE                (EFI_SUBCLASS_SPECIFIC | 0x00000009)\r
+#define EFI_SW_DS_PC_REMOVE_IO_SPACE              (EFI_SUBCLASS_SPECIFIC | 0x0000000A)\r
+#define EFI_SW_DS_PC_GET_IO_SPACE_DESCRIPTOR      (EFI_SUBCLASS_SPECIFIC | 0x0000000B)\r
+#define EFI_SW_DS_PC_GET_IO_SPACE_MAP             (EFI_SUBCLASS_SPECIFIC | 0x0000000C)\r
+#define EFI_SW_DS_PC_DISPATCH                     (EFI_SUBCLASS_SPECIFIC | 0x0000000D)\r
+#define EFI_SW_DS_PC_SCHEDULE                     (EFI_SUBCLASS_SPECIFIC | 0x0000000E)\r
+#define EFI_SW_DS_PC_TRUST                        (EFI_SUBCLASS_SPECIFIC | 0x0000000F)\r
+#define EFI_SW_DS_PC_PROCESS_FIRMWARE_VOLUME      (EFI_SUBCLASS_SPECIFIC | 0x00000010)\r
+\r
+//\r
+// Software Class Error Code definitions.\r
+// These are shared by all subclasses.\r
+//\r
+#define EFI_SW_EC_NON_SPECIFIC            0x00000000\r
+#define EFI_SW_EC_LOAD_ERROR              0x00000001\r
+#define EFI_SW_EC_INVALID_PARAMETER       0x00000002\r
+#define EFI_SW_EC_UNSUPPORTED             0x00000003\r
+#define EFI_SW_EC_INVALID_BUFFER          0x00000004\r
+#define EFI_SW_EC_OUT_OF_RESOURCES        0x00000005\r
+#define EFI_SW_EC_ABORTED                 0x00000006\r
+#define EFI_SW_EC_ILLEGAL_SOFTWARE_STATE  0x00000007\r
+#define EFI_SW_EC_ILLEGAL_HARDWARE_STATE  0x00000008\r
+#define EFI_SW_EC_START_ERROR             0x00000009\r
+#define EFI_SW_EC_BAD_DATE_TIME           0x0000000A\r
+#define EFI_SW_EC_CFG_INVALID             0x0000000B\r
+#define EFI_SW_EC_CFG_CLR_REQUEST         0x0000000C\r
+#define EFI_SW_EC_CFG_DEFAULT             0x0000000D\r
+#define EFI_SW_EC_PWD_INVALID             0x0000000E\r
+#define EFI_SW_EC_PWD_CLR_REQUEST         0x0000000F\r
+#define EFI_SW_EC_PWD_CLEARED             0x00000010\r
+#define EFI_SW_EC_EVENT_LOG_FULL          0x00000011\r
+\r
+//\r
+// Software Class Unspecified Subclass Error Code definitions.\r
+//\r
+//\r
+// Software Class SEC Subclass Error Code definitions.\r
+//\r
+//\r
+// Software Class PEI Core Subclass Error Code definitions.\r
+//\r
+#define EFI_SW_PEI_CORE_EC_DXE_CORRUPT  (EFI_SUBCLASS_SPECIFIC | 0x00000000)\r
+\r
+//\r
+// Software Class PEI Module Subclass Error Code definitions.\r
+//\r
+#define EFI_SW_PEIM_EC_NO_RECOVERY_CAPSULE        (EFI_SUBCLASS_SPECIFIC | 0x00000000)\r
+#define EFI_SW_PEIM_EC_INVALID_CAPSULE_DESCRIPTOR (EFI_SUBCLASS_SPECIFIC | 0x00000001)\r
+\r
+//\r
+// Software Class DXE Core Subclass Error Code definitions.\r
+//\r
+#define EFI_SW_CSM_LEGACY_ROM_INIT  (EFI_SUBCLASS_SPECIFIC | 0x00000000)\r
+//\r
+// Software Class DXE Boot Service Driver Subclass Error Code definitions.\r
+//\r
+#define EFI_SW_DXE_BS_EC_LEGACY_OPROM_NO_SPACE  (EFI_SUBCLASS_SPECIFIC | 0x00000000)\r
+\r
+//\r
+// Software Class DXE Runtime Service Driver Subclass Error Code definitions.\r
+//\r
+//\r
+// Software Class SMM Driver Subclass Error Code definitions.\r
+//\r
+//\r
+// Software Class EFI Application Subclass Error Code definitions.\r
+//\r
+//\r
+// Software Class EFI OS Loader Subclass Error Code definitions.\r
+//\r
+//\r
+// Software Class EFI RT Subclass Error Code definitions.\r
+//\r
+//\r
+// Software Class EFI AL Subclass Error Code definitions.\r
+//\r
+//\r
+// Software Class EBC Exception Subclass Error Code definitions.\r
+// These exceptions are derived from the debug protocol definitions in the EFI\r
+// specification.\r
+//\r
+#define EFI_SW_EC_EBC_UNDEFINED             (EFI_SUBCLASS_SPECIFIC | EXCEPT_EBC_UNDEFINED)\r
+#define EFI_SW_EC_EBC_DIVIDE_ERROR          (EFI_SUBCLASS_SPECIFIC | EXCEPT_EBC_DIVIDE_ERROR)\r
+#define EFI_SW_EC_EBC_DEBUG                 (EFI_SUBCLASS_SPECIFIC | EXCEPT_EBC_DEBUG)\r
+#define EFI_SW_EC_EBC_BREAKPOINT            (EFI_SUBCLASS_SPECIFIC | EXCEPT_EBC_BREAKPOINT)\r
+#define EFI_SW_EC_EBC_OVERFLOW              (EFI_SUBCLASS_SPECIFIC | EXCEPT_EBC_OVERFLOW)\r
+#define EFI_SW_EC_EBC_INVALID_OPCODE        (EFI_SUBCLASS_SPECIFIC | EXCEPT_EBC_INVALID_OPCODE)\r
+#define EFI_SW_EC_EBC_STACK_FAULT           (EFI_SUBCLASS_SPECIFIC | EXCEPT_EBC_STACK_FAULT)\r
+#define EFI_SW_EC_EBC_ALIGNMENT_CHECK       (EFI_SUBCLASS_SPECIFIC | EXCEPT_EBC_ALIGNMENT_CHECK)\r
+#define EFI_SW_EC_EBC_INSTRUCTION_ENCODING  (EFI_SUBCLASS_SPECIFIC | EXCEPT_EBC_INSTRUCTION_ENCODING)\r
+#define EFI_SW_EC_EBC_BAD_BREAK             (EFI_SUBCLASS_SPECIFIC | EXCEPT_EBC_BAD_BREAK)\r
+#define EFI_SW_EC_EBC_STEP                  (EFI_SUBCLASS_SPECIFIC | EXCEPT_EBC_STEP)\r
+\r
+//\r
+// Software Class IA32 Exception Subclass Error Code definitions.\r
+// These exceptions are derived from the debug protocol definitions in the EFI\r
+// specification.\r
+//\r
+#define EFI_SW_EC_IA32_DIVIDE_ERROR     (EFI_SUBCLASS_SPECIFIC | EXCEPT_IA32_DIVIDE_ERROR)\r
+#define EFI_SW_EC_IA32_DEBUG            (EFI_SUBCLASS_SPECIFIC | EXCEPT_IA32_DEBUG)\r
+#define EFI_SW_EC_IA32_NMI              (EFI_SUBCLASS_SPECIFIC | EXCEPT_IA32_NMI)\r
+#define EFI_SW_EC_IA32_BREAKPOINT       (EFI_SUBCLASS_SPECIFIC | EXCEPT_IA32_BREAKPOINT)\r
+#define EFI_SW_EC_IA32_OVERFLOW         (EFI_SUBCLASS_SPECIFIC | EXCEPT_IA32_OVERFLOW)\r
+#define EFI_SW_EC_IA32_BOUND            (EFI_SUBCLASS_SPECIFIC | EXCEPT_IA32_BOUND)\r
+#define EFI_SW_EC_IA32_INVALID_OPCODE   (EFI_SUBCLASS_SPECIFIC | EXCEPT_IA32_INVALID_OPCODE)\r
+#define EFI_SW_EC_IA32_DOUBLE_FAULT     (EFI_SUBCLASS_SPECIFIC | EXCEPT_IA32_DOUBLE_FAULT)\r
+#define EFI_SW_EC_IA32_INVALID_TSS      (EFI_SUBCLASS_SPECIFIC | EXCEPT_IA32_INVALID_TSS)\r
+#define EFI_SW_EC_IA32_SEG_NOT_PRESENT  (EFI_SUBCLASS_SPECIFIC | EXCEPT_IA32_SEG_NOT_PRESENT)\r
+#define EFI_SW_EC_IA32_STACK_FAULT      (EFI_SUBCLASS_SPECIFIC | EXCEPT_IA32_STACK_FAULT)\r
+#define EFI_SW_EC_IA32_GP_FAULT         (EFI_SUBCLASS_SPECIFIC | EXCEPT_IA32_GP_FAULT)\r
+#define EFI_SW_EC_IA32_PAGE_FAULT       (EFI_SUBCLASS_SPECIFIC | EXCEPT_IA32_PAGE_FAULT)\r
+#define EFI_SW_EC_IA32_FP_ERROR         (EFI_SUBCLASS_SPECIFIC | EXCEPT_IA32_FP_ERROR)\r
+#define EFI_SW_EC_IA32_ALIGNMENT_CHECK  (EFI_SUBCLASS_SPECIFIC | EXCEPT_IA32_ALIGNMENT_CHECK)\r
+#define EFI_SW_EC_IA32_MACHINE_CHECK    (EFI_SUBCLASS_SPECIFIC | EXCEPT_IA32_MACHINE_CHECK)\r
+#define EFI_SW_EC_IA32_SIMD             (EFI_SUBCLASS_SPECIFIC | EXCEPT_IA32_SIMD)\r
+\r
+//\r
+// Software Class X64 Exception Subclass Error Code definitions.\r
+// These exceptions are derived from the debug protocol definitions in the EFI\r
+// specification.\r
+//\r
+#define EFI_SW_EC_X64_DIVIDE_ERROR      (EFI_SUBCLASS_SPECIFIC | EXCEPT_X64_DIVIDE_ERROR)\r
+#define EFI_SW_EC_X64_DEBUG             (EFI_SUBCLASS_SPECIFIC | EXCEPT_X64_DEBUG)\r
+#define EFI_SW_EC_X64_NMI               (EFI_SUBCLASS_SPECIFIC | EXCEPT_X64_NMI)\r
+#define EFI_SW_EC_X64_BREAKPOINT        (EFI_SUBCLASS_SPECIFIC | EXCEPT_X64_BREAKPOINT)\r
+#define EFI_SW_EC_X64_OVERFLOW          (EFI_SUBCLASS_SPECIFIC | EXCEPT_X64_OVERFLOW)\r
+#define EFI_SW_EC_X64_BOUND             (EFI_SUBCLASS_SPECIFIC | EXCEPT_X64_BOUND)\r
+#define EFI_SW_EC_X64_INVALID_OPCODE    (EFI_SUBCLASS_SPECIFIC | EXCEPT_X64_INVALID_OPCODE)\r
+#define EFI_SW_EC_X64_DOUBLE_FAULT      (EFI_SUBCLASS_SPECIFIC | EXCEPT_X64_DOUBLE_FAULT)\r
+#define EFI_SW_EC_X64_INVALID_TSS       (EFI_SUBCLASS_SPECIFIC | EXCEPT_X64_INVALID_TSS)\r
+#define EFI_SW_EC_X64_SEG_NOT_PRESENT   (EFI_SUBCLASS_SPECIFIC | EXCEPT_X64_SEG_NOT_PRESENT)\r
+#define EFI_SW_EC_X64_STACK_FAULT       (EFI_SUBCLASS_SPECIFIC | EXCEPT_X64_STACK_FAULT)\r
+#define EFI_SW_EC_X64_GP_FAULT          (EFI_SUBCLASS_SPECIFIC | EXCEPT_X64_GP_FAULT)\r
+#define EFI_SW_EC_X64_PAGE_FAULT        (EFI_SUBCLASS_SPECIFIC | EXCEPT_X64_PAGE_FAULT)\r
+#define EFI_SW_EC_X64_FP_ERROR          (EFI_SUBCLASS_SPECIFIC | EXCEPT_X64_FP_ERROR)\r
+#define EFI_SW_EC_X64_ALIGNMENT_CHECK   (EFI_SUBCLASS_SPECIFIC | EXCEPT_X64_ALIGNMENT_CHECK)\r
+#define EFI_SW_EC_X64_MACHINE_CHECK     (EFI_SUBCLASS_SPECIFIC | EXCEPT_X64_MACHINE_CHECK)\r
+#define EFI_SW_EC_X64_SIMD              (EFI_SUBCLASS_SPECIFIC | EXCEPT_X64_SIMD)\r
+\r
+//\r
+// Software Class IPF Exception Subclass Error Code definitions.\r
+// These exceptions are derived from the debug protocol definitions in the EFI\r
+// specification.\r
+//\r
+#define EFI_SW_EC_IPF_ALT_DTLB            (EFI_SUBCLASS_SPECIFIC | EXCEPT_IPF_ALT_DTLB)\r
+#define EFI_SW_EC_IPF_DNESTED_TLB         (EFI_SUBCLASS_SPECIFIC | EXCEPT_IPF_DNESTED_TLB)\r
+#define EFI_SW_EC_IPF_BREAKPOINT          (EFI_SUBCLASS_SPECIFIC | EXCEPT_IPF_BREAKPOINT)\r
+#define EFI_SW_EC_IPF_EXTERNAL_INTERRUPT  (EFI_SUBCLASS_SPECIFIC | EXCEPT_IPF_EXTERNAL_INTERRUPT)\r
+#define EFI_SW_EC_IPF_GEN_EXCEPT          (EFI_SUBCLASS_SPECIFIC | EXCEPT_IPF_GEN_EXCEPT)\r
+#define EFI_SW_EC_IPF_NAT_CONSUMPTION     (EFI_SUBCLASS_SPECIFIC | EXCEPT_IPF_NAT_CONSUMPTION)\r
+#define EFI_SW_EC_IPF_DEBUG_EXCEPT        (EFI_SUBCLASS_SPECIFIC | EXCEPT_IPF_DEBUG_EXCEPT)\r
+#define EFI_SW_EC_IPF_UNALIGNED_ACCESS    (EFI_SUBCLASS_SPECIFIC | EXCEPT_IPF_UNALIGNED_ACCESS)\r
+#define EFI_SW_EC_IPF_FP_FAULT            (EFI_SUBCLASS_SPECIFIC | EXCEPT_IPF_FP_FAULT)\r
+#define EFI_SW_EC_IPF_FP_TRAP             (EFI_SUBCLASS_SPECIFIC | EXCEPT_IPF_FP_TRAP)\r
+#define EFI_SW_EC_IPF_TAKEN_BRANCH        (EFI_SUBCLASS_SPECIFIC | EXCEPT_IPF_TAKEN_BRANCH)\r
+#define EFI_SW_EC_IPF_SINGLE_STEP         (EFI_SUBCLASS_SPECIFIC | EXCEPT_IPF_SINGLE_STEP)\r
+\r
+\r
+//\r
+// Software Class PEI Service Subclass Error Code definitions.\r
+//\r
+//\r
+// Software Class EFI Boot Service Subclass Error Code definitions.\r
+//\r
+//\r
+// Software Class EFI Runtime Service Subclass Error Code definitions.\r
+//\r
+//\r
+// Software Class EFI DXE Service Subclass Error Code definitions.\r
+//\r
+\r
+///////////////////////////////////////////////////////////////////////////////\r
+// Section 7\r
+///////////////////////////////////////////////////////////////////////////////\r
+//\r
+// Debug Code definitions for all classes and subclass\r
+// Only one debug code is defined at this point and should\r
+// be used for anything that gets sent to debug stream.\r
+//\r
+#define EFI_DC_UNSPECIFIED  0x0\r
+\r
+#endif\r
diff --git a/IntelFrameworkPkg/Include/FrameworkBase.h b/IntelFrameworkPkg/Include/FrameworkBase.h
new file mode 100644 (file)
index 0000000..fb99890
--- /dev/null
@@ -0,0 +1,29 @@
+/** @file\r
+  Header file that supports Framework extension to UEFI for all types of\r
+  modules.\r
+\r
+  This header file must include Framework extension definitions common to all\r
+  types of modules.\r
+\r
+  Copyright (c) 2007, Intel Corporation\r
+  All rights reserved. This program and the accompanying materials\r
+  are licensed and made available under the terms and conditions of the BSD License\r
+  which accompanies this distribution.  The full text of the license may be found at\r
+  http://opensource.org/licenses/bsd-license.php\r
+\r
+  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
+  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
+\r
+  Module Name:    FrameworkBase.h\r
+\r
+**/\r
+\r
+#ifndef _FRAMEWORK_BASE_H_\r
+#define _FRAMEWORK_BASE_H_\r
+\r
+#include <Common/FrameworkFirmwareFileSystem.h>\r
+#include <Common/FrameworkHob.h>\r
+#include <Common/FrameworkLegacy16.h>\r
+#include <Common/DataHubRecords.h>\r
+\r
+#endif\r
diff --git a/IntelFrameworkPkg/Include/FrameworkDxe.h b/IntelFrameworkPkg/Include/FrameworkDxe.h
new file mode 100644 (file)
index 0000000..6fb767e
--- /dev/null
@@ -0,0 +1,27 @@
+/** @file\r
+  Header file that supports Framework extension to UEFI/PI for DXE modules.\r
+\r
+  This header file must include Framework extension definitions common to DXE\r
+  modules.\r
+\r
+  Copyright (c) 2007, Intel Corporation\r
+  All rights reserved. This program and the accompanying materials\r
+  are licensed and made available under the terms and conditions of the BSD License\r
+  which accompanies this distribution.  The full text of the license may be found at\r
+  http://opensource.org/licenses/bsd-license.php\r
+\r
+  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
+  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
+\r
+  Module Name:    FrameworkDxe.h\r
+\r
+**/\r
+\r
+#ifndef _FRAMEWORK_DXE_H_\r
+#define _FRAMEWORK_DXE_H_\r
+\r
+#include <FrameworkBase.h>\r
+#include <Common/FrameworkDxeCis.h>\r
+#include <Common/FrameworkStatusCode.h>\r
+\r
+#endif\r
diff --git a/IntelFrameworkPkg/Include/FrameworkPei.h b/IntelFrameworkPkg/Include/FrameworkPei.h
new file mode 100644 (file)
index 0000000..fdcbbcf
--- /dev/null
@@ -0,0 +1,27 @@
+/** @file\r
+  Header file that supports Framework extension to UEFI/PI for PEI modules.\r
+\r
+  This header file must include Framework extension definitions common to PEI\r
+  modules.\r
+\r
+  Copyright (c) 2007, Intel Corporation\r
+  All rights reserved. This program and the accompanying materials\r
+  are licensed and made available under the terms and conditions of the BSD License\r
+  which accompanies this distribution.  The full text of the license may be found at\r
+  http://opensource.org/licenses/bsd-license.php\r
+\r
+  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
+  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
+\r
+  Module Name:    FrameworkPei.h\r
+\r
+**/\r
+\r
+#ifndef _FRAMEWORK_PEI_H_\r
+#define _FRAMEWORK_PEI_H_\r
+\r
+#include <FrameworkBase.h>\r
+#include <PiPei.h>\r
+#include <Common/FrameworkStatusCode.h>\r
+\r
+#endif\r
diff --git a/IntelFrameworkPkg/Include/FrameworkSmm.h b/IntelFrameworkPkg/Include/FrameworkSmm.h
new file mode 100644 (file)
index 0000000..0226b9a
--- /dev/null
@@ -0,0 +1,26 @@
+/** @file\r
+  Header file that supports Framework extension to UEFI/PI for DXE modules.\r
+\r
+  This header file must include Framework extension definitions common to DXE\r
+  modules.\r
+\r
+  Copyright (c) 2007, Intel Corporation\r
+  All rights reserved. This program and the accompanying materials\r
+  are licensed and made available under the terms and conditions of the BSD License\r
+  which accompanies this distribution.  The full text of the license may be found at\r
+  http://opensource.org/licenses/bsd-license.php\r
+\r
+  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
+  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
+\r
+  Module Name:    FrameworkSmm.h\r
+\r
+**/\r
+\r
+#ifndef _FRAMEWORK_SMM_H_\r
+#define _FRAMEWORK_SMM_H_\r
+\r
+#include <FrameworkDxe.h>\r
+#include <Common/FrameworkSmmCis.h>\r
+\r
+#endif\r
diff --git a/IntelFrameworkPkg/Include/Guid/AcpiTableStorage.h b/IntelFrameworkPkg/Include/Guid/AcpiTableStorage.h
new file mode 100644 (file)
index 0000000..69a8bc0
--- /dev/null
@@ -0,0 +1,30 @@
+/** @file\r
+  The ACPI table storage file is fully FFS compliant.\r
+  The file is a number of sections of type EFI_SECTION_RAW.\r
+  This GUID is used to identify the file as an ACPI table storage file.\r
+\r
+  Copyright (c) 2007, Intel Corporation\r
+  All rights reserved. This program and the accompanying materials\r
+  are licensed and made available under the terms and conditions of the BSD License\r
+  which accompanies this distribution.  The full text of the license may be found at\r
+  http://opensource.org/licenses/bsd-license.php\r
+\r
+  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
+  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
+\r
+  Module Name:  AcpiTableStorage.h\r
+\r
+  @par Revision Reference:\r
+  GUID defined in ACPI Table Storage Spec Version 0.9.\r
+\r
+**/\r
+\r
+#ifndef _ACPI_TABLE_STORAGE_H_\r
+#define _ACPI_TABLE_STORAGE_H_\r
+\r
+#define EFI_ACPI_TABLE_STORAGE_GUID \\r
+  { 0x7e374e25, 0x8e01, 0x4fee, {0x87, 0xf2, 0x39, 0xc, 0x23, 0xc6, 0x6, 0xcd } }\r
+\r
+extern EFI_GUID gEfiAcpiTableStorageGuid;\r
+\r
+#endif\r
diff --git a/IntelFrameworkPkg/Include/Guid/Capsule.h b/IntelFrameworkPkg/Include/Guid/Capsule.h
new file mode 100644 (file)
index 0000000..6449666
--- /dev/null
@@ -0,0 +1,43 @@
+/** @file\r
+  GUIDs used for EFI Capsule\r
+\r
+  Copyright (c) 2007, Intel Corporation\r
+  All rights reserved. This program and the accompanying materials\r
+  are licensed and made available under the terms and conditions of the BSD License\r
+  which accompanies this distribution.  The full text of the license may be found at\r
+  http://opensource.org/licenses/bsd-license.php\r
+\r
+  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
+  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
+\r
+  Module Name:  Capsule.h\r
+\r
+  @par Revision Reference:\r
+  GUIDs defined in Capsule Spec Version 0.9\r
+\r
+**/\r
+\r
+#ifndef _CAPSULE_GUID_H__\r
+#define _CAPSULE_GUID_H__\r
+\r
+//\r
+// This is the GUID of the capsule header of the image on disk.\r
+//\r
+#define EFI_CAPSULE_GUID \\r
+  { \\r
+    0x3B6686BD, 0x0D76, 0x4030, {0xB7, 0x0E, 0xB5, 0x51, 0x9E, 0x2F, 0xC5, 0xA0 } \\r
+  }\r
+\r
+//\r
+// This is the GUID of the configuration results file created by the capsule\r
+// application.\r
+//\r
+#define EFI_CONFIG_FILE_NAME_GUID \\r
+  { \\r
+    0x98B8D59B, 0xE8BA, 0x48EE, {0x98, 0xDD, 0xC2, 0x95, 0x39, 0x2F, 0x1E, 0xDB } \\r
+  }\r
+\r
+extern EFI_GUID gEfiCapsuleGuid;\r
+extern EFI_GUID gEfiConfigFileNameGuid;\r
+\r
+#endif\r
diff --git a/IntelFrameworkPkg/Include/Guid/DataHubRecords.h b/IntelFrameworkPkg/Include/Guid/DataHubRecords.h
new file mode 100644 (file)
index 0000000..f50a6d3
--- /dev/null
@@ -0,0 +1,63 @@
+/** @file\r
+  DataHubRecord.h include all data hub sub class GUID defitions.\r
+\r
+  Copyright (c) 2007, Intel Corporation\r
+  All rights reserved. This program and the accompanying materials\r
+  are licensed and made available under the terms and conditions of the BSD License\r
+  which accompanies this distribution.  The full text of the license may be found at\r
+  http://opensource.org/licenses/bsd-license.php\r
+\r
+  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
+  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
+\r
+  Module Name:\r
+\r
+  @par Revision Reference:\r
+  These GUID are from Cache subclass spec 0.9, DataHub SubClass spec 0.9, Memory SubClass Spec 0.9,\r
+  Processor Subclass spec 0.9, Misc SubClass spec 0.9.\r
+\r
+**/\r
+#ifndef _DATAHUB_RECORDS_GUID_H_\r
+#define _DATAHUB_RECORDS_GUID_H_\r
+\r
+#define EFI_PROCESSOR_PRODUCER_GUID \\r
+  { 0x1bf06aea, 0x5bec, 0x4a8d, {0x95, 0x76, 0x74, 0x9b, 0x09, 0x56, 0x2d, 0x30 } }\r
+\r
+extern  EFI_GUID gEfiProcessorProducerGuid;\r
+\r
+\r
+#define EFI_PROCESSOR_SUBCLASS_GUID \\r
+  { 0x26fdeb7e, 0xb8af, 0x4ccf, {0xaa, 0x97, 0x02, 0x63, 0x3c, 0xe4, 0x8c, 0xa7 } }\r
+\r
+extern  EFI_GUID gEfiProcessorSubClassGuid;\r
+\r
+\r
+#define EFI_CACHE_SUBCLASS_GUID \\r
+  { 0x7f0013a7, 0xdc79, 0x4b22, {0x80, 0x99, 0x11, 0xf7, 0x5f, 0xdc, 0x82, 0x9d } }\r
+\r
+extern  EFI_GUID gEfiCacheSubClassGuid;\r
+\r
+\r
+#define EFI_MEMORY_PRODUCER_GUID \\r
+  { 0x1d7add6e, 0xb2da, 0x4b0b, {0xb2, 0x9f, 0x49, 0xcb, 0x42, 0xf4, 0x63, 0x56 } }\r
+\r
+extern  EFI_GUID gEfiMemoryProducerGuid;\r
+\r
+\r
+#define EFI_MEMORY_SUBCLASS_GUID \\r
+  {0x4E8F4EBB, 0x64B9, 0x4e05, {0x9B, 0x18, 0x4C, 0xFE, 0x49, 0x23, 0x50, 0x97} }\r
+\r
+extern  EFI_GUID  gEfiMemorySubClassGuid;\r
+\r
+\r
+#define EFI_MISC_PRODUCER_GUID \\r
+  { 0x62512c92, 0x63c4, 0x4d80, {0x82, 0xb1, 0xc1, 0xa4, 0xdc, 0x44, 0x80, 0xe5 } }\r
+\r
+extern  EFI_GUID gEfiMiscProducerGuid;\r
+\r
+#define EFI_MISC_SUBCLASS_GUID \\r
+  { 0x772484B2, 0x7482, 0x4b91, {0x9F, 0x9A, 0xAD, 0x43, 0xF8, 0x1C, 0x58, 0x81 } }\r
+\r
+extern  EFI_GUID  gEfiMiscSubClassGuid;\r
+\r
+#endif\r
diff --git a/IntelFrameworkPkg/Include/Guid/FrameworkDevicePath.h b/IntelFrameworkPkg/Include/Guid/FrameworkDevicePath.h
new file mode 100644 (file)
index 0000000..81f8ff0
--- /dev/null
@@ -0,0 +1,29 @@
+/** @file\r
+  This GUID is used to define a vendor specific device path being owned by the\r
+  Framework specificaitons.\r
+\r
+  Copyright (c) 2007, Intel Corporation\r
+  All rights reserved. This program and the accompanying materials\r
+  are licensed and made available under the terms and conditions of the BSD License\r
+  which accompanies this distribution.  The full text of the license may be found at\r
+  http://opensource.org/licenses/bsd-license.php\r
+\r
+  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
+  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
+\r
+  Module Name:  FrameworkDevicePath.h\r
+\r
+  @par Revision Reference:\r
+  Spec Version 0.9\r
+\r
+**/\r
+\r
+#ifndef _FRAMEWORK_DEVICE_PATH_GUID_H_\r
+#define _FRAMEWORK_DEVICE_PATH_GUID_H_\r
+\r
+#define EFI_FRAMEWORK_DEVICE_PATH_GUID  \\r
+  { 0xb7084e63, 0x46b7, 0x4d1a, { 0x86, 0x77, 0xe3, 0x0b, 0x53, 0xdb, 0xf0, 0x50 } }\r
+\r
+extern EFI_GUID gEfiFrameworkDevicePathGuid;\r
+\r
+#endif\r
diff --git a/IntelFrameworkPkg/Include/Guid/SmmCommunicate.h b/IntelFrameworkPkg/Include/Guid/SmmCommunicate.h
new file mode 100644 (file)
index 0000000..8d36fe9
--- /dev/null
@@ -0,0 +1,40 @@
+/** @file\r
+  Definitions EFI_SMM_COMMUNICATE_HEADER used by EFI_SMM_BASE_PROTOCOL.Communicate()\r
+  functions\r
+\r
+  Copyright (c) 2007, Intel Corporation\r
+  All rights reserved. This program and the accompanying materials\r
+  are licensed and made available under the terms and conditions of the BSD License\r
+  which accompanies this distribution.  The full text of the license may be found at\r
+  http://opensource.org/licenses/bsd-license.php\r
+\r
+  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
+  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
+\r
+  Module Name:  SmmCommunicate.h\r
+\r
+  @par Revision Reference:\r
+  GUIDs defined in SmmCis spec version 0.9\r
+\r
+**/\r
+\r
+#ifndef _SMM_COMMUNICATE_GUID_H_\r
+#define _SMM_COMMUNICATE_GUID_H_\r
+\r
+//******************************************************\r
+// EFI_SMM_COMMUNICATE_HEADER\r
+//******************************************************\r
+#define SMM_COMMUNICATE_HEADER_GUID \\r
+  { \\r
+    0xf328e36c, 0x23b6, 0x4a95, {0x85, 0x4b, 0x32, 0xe1, 0x95, 0x34, 0xcd, 0x75 } \\r
+  }\r
+\r
+typedef struct {\r
+  EFI_GUID                         HeaderGuid;\r
+  UINTN                            MessageLength;\r
+  UINT8                            Data[1];\r
+} EFI_SMM_COMMUNICATE_HEADER;\r
+\r
+extern EFI_GUID gSmmCommunicateHeaderGuid;\r
+\r
+#endif\r
diff --git a/IntelFrameworkPkg/Include/Guid/SmramMemoryReserve.h b/IntelFrameworkPkg/Include/Guid/SmramMemoryReserve.h
new file mode 100644 (file)
index 0000000..680f0b9
--- /dev/null
@@ -0,0 +1,67 @@
+/** @file\r
+  GUID for use in reserving SMRAM regions.\r
+\r
+  Copyright (c) 2007, Intel Corporation\r
+  All rights reserved. This program and the accompanying materials\r
+  are licensed and made available under the terms and conditions of the BSD License\r
+  which accompanies this distribution.  The full text of the license may be found at\r
+  http://opensource.org/licenses/bsd-license.php\r
+\r
+  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
+  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
+\r
+  Module Name:  SmramMemoryReserve.h\r
+\r
+  @par Revision Reference:\r
+  GUIDs defined in SmmCis spec version 0.9\r
+\r
+**/\r
+\r
+#ifndef _EFI_SMM_PEI_SMRAM_MEMORY_RESERVE_H_\r
+#define _EFI_SMM_PEI_SMRAM_MEMORY_RESERVE_H_\r
+\r
+#define EFI_SMM_PEI_SMRAM_MEMORY_RESERVE \\r
+  { \\r
+    0x6dadf1d1, 0xd4cc, 0x4910, {0xbb, 0x6e, 0x82, 0xb1, 0xfd, 0x80, 0xff, 0x3d } \\r
+  }\r
+\r
+//\r
+// *******************************************************\r
+//  EFI_SMRAM_DESCRIPTOR\r
+// *******************************************************\r
+//\r
+typedef struct {\r
+  EFI_PHYSICAL_ADDRESS  PhysicalStart;  // Phsyical location in DRAM\r
+  EFI_PHYSICAL_ADDRESS  CpuStart;       // Address CPU uses to access the SMI handler\r
+  // May or may not match PhysicalStart\r
+  //\r
+  UINT64                PhysicalSize;\r
+  UINT64                RegionState;\r
+} EFI_SMRAM_DESCRIPTOR;\r
+\r
+//\r
+// *******************************************************\r
+//  EFI_SMRAM_STATE\r
+// *******************************************************\r
+//\r
+#define EFI_SMRAM_OPEN                0x00000001\r
+#define EFI_SMRAM_CLOSED              0x00000002\r
+#define EFI_SMRAM_LOCKED              0x00000004\r
+#define EFI_CACHEABLE                 0x00000008\r
+#define EFI_ALLOCATED                 0x00000010\r
+#define EFI_NEEDS_TESTING             0x00000020\r
+#define EFI_NEEDS_ECC_INITIALIZATION  0x00000040\r
+\r
+//\r
+// *******************************************************\r
+//  EFI_SMRAM_HOB_DESCRIPTOR_BLOCK\r
+// *******************************************************\r
+//\r
+typedef struct {\r
+  UINTN                 NumberOfSmmReservedRegions;\r
+  EFI_SMRAM_DESCRIPTOR  Descriptor[1];\r
+} EFI_SMRAM_HOB_DESCRIPTOR_BLOCK;\r
+\r
+extern EFI_GUID gEfiSmmPeiSmramMemoryReserveGuid;\r
+\r
+#endif\r
diff --git a/IntelFrameworkPkg/Include/Ppi/BlockIo.h b/IntelFrameworkPkg/Include/Ppi/BlockIo.h
new file mode 100644 (file)
index 0000000..df209f5
--- /dev/null
@@ -0,0 +1,158 @@
+/** @file\r
+  This file declares BlockIo PPI used to access block-oriented storage devices\r
+\r
+  Copyright (c) 2007, Intel Corporation\r
+  All rights reserved. This program and the accompanying materials\r
+  are licensed and made available under the terms and conditions of the BSD License\r
+  which accompanies this distribution.  The full text of the license may be found at\r
+  http://opensource.org/licenses/bsd-license.php\r
+\r
+  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
+  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
+\r
+  Module Name:  BlockIo.h\r
+\r
+  @par Revision Reference:\r
+  This PPI is defined in Framework of EFI Recovery Spec\r
+  Version 0.9\r
+\r
+**/\r
+\r
+#ifndef _PEI_BLOCK_IO_H_\r
+#define _PEI_BLOCK_IO_H_\r
+\r
+#define EFI_PEI_IDE_BLOCK_IO_PPI \\r
+  { \\r
+    0x0964e5b22, 0x6459, 0x11d2, { 0x8e, 0x39, 0x00, 0xa0, 0xc9, 0x69, 0x72, 0x3b }  \\r
+  }\r
+\r
+#define EFI_PEI_144_FLOPPY_BLOCK_IO_PPI \\r
+  { \\r
+    0xda6855bd, 0x07b7, 0x4c05, { 0x9e, 0xd8, 0xe2, 0x59, 0xfd, 0x36, 0x0e, 0x22 }  \\r
+  }\r
+\r
+#define EFI_PEI_VIRTUAL_BLOCK_IO_PPI \\r
+  { \\r
+    0x695d8aa1, 0x42ee, 0x4c46, { 0x80, 0x5c, 0x6e, 0xa6, 0xbc, 0xe7, 0x99, 0xe3 } \\r
+  }\r
+\r
+typedef struct _EFI_PEI_RECOVERY_BLOCK_IO_PPI EFI_PEI_RECOVERY_BLOCK_IO_PPI;\r
+\r
+typedef UINT64  EFI_PEI_LBA;\r
+\r
+typedef enum {\r
+  LegacyFloppy  = 0,\r
+  IdeCDROM      = 1,\r
+  IdeLS120      = 2,\r
+  UsbMassStorage= 3,\r
+  MaxDeviceType\r
+} EFI_PEI_BLOCK_DEVICE_TYPE;\r
+\r
+typedef struct {\r
+  EFI_PEI_BLOCK_DEVICE_TYPE  DeviceType;\r
+  BOOLEAN                    MediaPresent;\r
+  UINTN                      LastBlock;\r
+  UINTN                      BlockSize;\r
+} EFI_PEI_BLOCK_IO_MEDIA;\r
+\r
+/**\r
+  Gets the count of block I/O devices that one specific block driver detects.\r
+\r
+  @param  PeiServices        General-purpose services that are available to every PEIM.\r
+  @param  This               Indicates the EFI_PEI_RECOVERY_BLOCK_IO_PPI instance.\r
+  @param  NumberBlockDevices The number of block I/O devices discovered.\r
+\r
+  @return Status code\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_PEI_GET_NUMBER_BLOCK_DEVICES) (\r
+  IN  EFI_PEI_SERVICES                         **PeiServices,\r
+  IN  EFI_PEI_RECOVERY_BLOCK_IO_PPI            *This,\r
+  OUT UINTN                                    *NumberBlockDevices\r
+  );\r
+\r
+/**\r
+  Gets a block device's media information.\r
+\r
+  @param  PeiServices    General-purpose services that are available to every PEIM\r
+  @param  This           Indicates the EFI_PEI_RECOVERY_BLOCK_IO_PPI instance.\r
+  @param  DeviceIndex    Specifies the block device to which the function\r
+                         wants to talk. Because the driver that implements Block I/O PPIs\r
+                         will manage multiple block devices, the PPIs that want to talk to a single\r
+                         device must specify the device index that was assigned during the enumeration\r
+                         process. This index is a number from one to NumberBlockDevices.\r
+  @param  MediaInfo      The media information of the specified block media.\r
+\r
+  @retval EFI_SUCCESS           Media information about the specified block device was obtained successfully.\r
+  @retval EFI_DEVICE_ERROR      Cannot get the media information due to a hardware error.\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_PEI_GET_DEVICE_MEDIA_INFORMATION) (\r
+  IN  EFI_PEI_SERVICES                         **PeiServices,\r
+  IN  EFI_PEI_RECOVERY_BLOCK_IO_PPI            *This,\r
+  IN  UINTN                                    DeviceIndex,\r
+  OUT EFI_PEI_BLOCK_IO_MEDIA                   *MediaInfo\r
+  );\r
+\r
+/**\r
+  Reads the requested number of blocks from the specified block device.\r
+\r
+  @param  PeiServices    General-purpose services that are available to every PEIM.\r
+  @param  This           Indicates the EFI_PEI_RECOVERY_BLOCK_IO_PPI instance.\r
+  @param  DeviceIndex    Specifies the block device to which the function wants to talk.\r
+  @param  StartLBA       The starting logical block address (LBA) to read from on the device\r
+  @param  BufferSize     The size of the Buffer in bytes. This number must\r
+                         be a multiple of the intrinsic block size of the device.\r
+  @param  Buffer         A pointer to the destination buffer for the data.\r
+                         The caller is responsible for the ownership of the buffer.\r
+\r
+  @retval EFI_SUCCESS           The data was read correctly from the device.\r
+  @retval EFI_DEVICE_ERROR      The device reported an error while attempting to perform the read operation.\r
+  @retval EFI_INVALID_PARAMETER The read request contains LBAs that are not valid,\r
+                                or the buffer is not properly aligned.\r
+  @retval EFI_BAD_BUFFER_SIZE   The BufferSize parameter is not a multiple of\r
+                                the intrinsic block size of the device.\r
+  @retval EFI_NO_MEDIA          There is no media in the device.\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_PEI_READ_BLOCKS) (\r
+  IN  EFI_PEI_SERVICES                         **PeiServices,\r
+  IN  EFI_PEI_RECOVERY_BLOCK_IO_PPI            *This,\r
+  IN  UINTN                                    DeviceIndex,\r
+  IN  EFI_PEI_LBA                              StartLBA,\r
+  IN  UINTN                                    BufferSize,\r
+  OUT VOID                                     *Buffer\r
+  );\r
+\r
+/**\r
+  @par Ppi Description:\r
+  EFI_PEI_RECOVERY_BLOCK_IO_PPI provides the services that are required\r
+  to access a block I/O device during PEI recovery boot mode.\r
+\r
+  @param GetNumberOfBlockDevices\r
+  Gets the number of block I/O devices that the specific block driver manages.\r
+\r
+  @param GetBlockDeviceMediaInfo\r
+  Gets the specified media information.\r
+\r
+  @param ReadBlocks\r
+  Reads the requested number of blocks from the specified block device.\r
+\r
+**/\r
+struct _EFI_PEI_RECOVERY_BLOCK_IO_PPI {\r
+  EFI_PEI_GET_NUMBER_BLOCK_DEVICES      GetNumberOfBlockDevices;\r
+  EFI_PEI_GET_DEVICE_MEDIA_INFORMATION  GetBlockDeviceMediaInfo;\r
+  EFI_PEI_READ_BLOCKS                   ReadBlocks;\r
+};\r
+\r
+extern EFI_GUID gEfiPeiIdeBlockIoPpiGuid;\r
+extern EFI_GUID gEfiPei144FloppyBlockIoPpiGuid;\r
+extern EFI_GUID gEfiPeiVirtualBlockIoPpiGuid;\r
+\r
+#endif\r
diff --git a/IntelFrameworkPkg/Include/Ppi/BootScriptExecuter.h b/IntelFrameworkPkg/Include/Ppi/BootScriptExecuter.h
new file mode 100644 (file)
index 0000000..1d249f0
--- /dev/null
@@ -0,0 +1,72 @@
+/** @file\r
+  This file declares Boot Script Executer PPI.\r
+\r
+  Copyright (c) 2007, Intel Corporation\r
+  All rights reserved. This program and the accompanying materials\r
+  are licensed and made available under the terms and conditions of the BSD License\r
+  which accompanies this distribution.  The full text of the license may be found at\r
+  http://opensource.org/licenses/bsd-license.php\r
+\r
+  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
+  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
+\r
+  Module Name:  BootScriptExecuter.h\r
+\r
+  @par Revision Reference:\r
+  This PPI is defined in Framework of EFI BootScript spec.\r
+  Version 0.91.\r
+\r
+**/\r
+\r
+#ifndef _PEI_BOOT_SCRIPT_EXECUTER_PPI_H\r
+#define _PEI_BOOT_SCRIPT_EXECUTER_PPI_H\r
+\r
+#define EFI_PEI_BOOT_SCRIPT_EXECUTER_PPI_GUID \\r
+  { \\r
+    0xabd42895, 0x78cf, 0x4872, {0x84, 0x44, 0x1b, 0x5c, 0x18, 0x0b, 0xfb, 0xff } \\r
+  }\r
+\r
+typedef struct _EFI_PEI_BOOT_SCRIPT_EXECUTER_PPI EFI_PEI_BOOT_SCRIPT_EXECUTER_PPI;\r
+\r
+/**\r
+  Executes the Framework boot script table.\r
+\r
+  @param  PeiServices    A pointer to the system PEI Services Table.\r
+  @param  This           A pointer to the EFI_PEI_BOOT_SCRIPT_EXECUTER_PPI instance.\r
+  @param  Address        The physical memory address where the table is stored.\r
+                         It must be zero if the table to be executed is stored in a firmware volume file.\r
+  @param  FvFile         The firmware volume file name that contains the table to\r
+                         be executed. It must be NULL if the table to be executed is stored in physical memory.\r
+\r
+  @retval EFI_SUCCESS           The boot script table was executed successfully.\r
+  @retval EFI_INVALID_PARAMETER Address is zero and FvFile is NULL.\r
+  @retval EFI_NOT_FOUND         The file name specified in FvFile cannot be found.\r
+  @retval EFI_UNSUPPORTED       The format of the boot script table is invalid.\r
+                                Or An unsupported opcode occurred in the table.\r
+                                Or There were opcode execution errors, such as an insufficient dependency.\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_PEI_BOOT_SCRIPT_EXECUTE) (\r
+  IN     EFI_PEI_SERVICES                        **PeiServices,\r
+  IN     EFI_PEI_BOOT_SCRIPT_EXECUTER_PPI        *This,\r
+  IN     EFI_PHYSICAL_ADDRESS                    Address,\r
+  IN     EFI_GUID                                *FvFile OPTIONAL\r
+  );\r
+\r
+/**\r
+  @par Ppi Description:\r
+  This PPI produces functions to interpret and execute the Framework boot script table.\r
+\r
+  @param Execute\r
+  Executes a boot script table.\r
+\r
+**/\r
+struct _EFI_PEI_BOOT_SCRIPT_EXECUTER_PPI {\r
+  EFI_PEI_BOOT_SCRIPT_EXECUTE Execute;\r
+};\r
+\r
+extern EFI_GUID gEfiPeiBootScriptExecuterPpiGuid;\r
+\r
+#endif\r
diff --git a/IntelFrameworkPkg/Include/Ppi/RecoveryModule.h b/IntelFrameworkPkg/Include/Ppi/RecoveryModule.h
new file mode 100644 (file)
index 0000000..8136271
--- /dev/null
@@ -0,0 +1,64 @@
+/** @file\r
+  This file declares Recovery Module PPI.\r
+\r
+  Copyright (c) 2007, Intel Corporation\r
+  All rights reserved. This program and the accompanying materials\r
+  are licensed and made available under the terms and conditions of the BSD License\r
+  which accompanies this distribution.  The full text of the license may be found at\r
+  http://opensource.org/licenses/bsd-license.php\r
+\r
+  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
+  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
+\r
+  Module Name:  RecoveryModule.h\r
+\r
+  @par Revision Reference:\r
+  This PPI is defined in Framework of EFI Recovery Spec.\r
+  Version 0.9\r
+\r
+**/\r
+\r
+#ifndef __PEI_RECOVERY_MODULE_PPI_H__\r
+#define __PEI_RECOVERY_MODULE_PPI_H__\r
+\r
+#define EFI_PEI_RECOVERY_MODULE_PPI_GUID \\r
+  { \\r
+    0xFB6D9542, 0x612D, 0x4f45, {0x87, 0x2F, 0x5C, 0xFF, 0x52, 0xE9, 0x3D, 0xCF } \\r
+  }\r
+\r
+typedef struct _EFI_PEI_RECOVERY_MODULE_PPI EFI_PEI_RECOVERY_MODULE_PPI;\r
+\r
+/**\r
+  Loads a DXE capsule from some media into memory and updates the HOB table\r
+  with the DXE firmware volume information.\r
+\r
+  @param  PeiServices    General-purpose services that are available to every PEIM.\r
+  @param  This           Indicates the EFI_PEI_RECOVERY_MODULE_PPI instance.\r
+\r
+  @retval EFI_SUCCESS           The capsule was loaded correctly.\r
+  @retval EFI_DEVICE_ERROR      A device error occurred.\r
+  @retval EFI_NOT_FOUND         A recovery DXE capsule cannot be found.\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_PEI_LOAD_RECOVERY_CAPSULE) (\r
+  IN EFI_PEI_SERVICES                     **PeiServices,\r
+  IN EFI_PEI_RECOVERY_MODULE_PPI          *This\r
+  );\r
+\r
+/**\r
+  @par Ppi Description:\r
+  Finds and loads the recovery files.\r
+\r
+  @param LoadRecoveryCapsule\r
+  Loads a DXE binary capsule into memory.\r
+\r
+**/\r
+struct _EFI_PEI_RECOVERY_MODULE_PPI {\r
+  EFI_PEI_LOAD_RECOVERY_CAPSULE LoadRecoveryCapsule;\r
+};\r
+\r
+extern EFI_GUID gEfiPeiRecoveryModulePpiGuid;\r
+\r
+#endif\r
diff --git a/IntelFrameworkPkg/Include/Ppi/S3Resume.h b/IntelFrameworkPkg/Include/Ppi/S3Resume.h
new file mode 100644 (file)
index 0000000..d031018
--- /dev/null
@@ -0,0 +1,64 @@
+/** @file\r
+  This file declares S3 Resume PPI.\r
+\r
+  Copyright (c) 2007, Intel Corporation\r
+  All rights reserved. This program and the accompanying materials\r
+  are licensed and made available under the terms and conditions of the BSD License\r
+  which accompanies this distribution.  The full text of the license may be found at\r
+  http://opensource.org/licenses/bsd-license.php\r
+\r
+  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
+  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
+\r
+  Module Name:  S3Resume.h\r
+\r
+  @par Revision Reference:\r
+  This PPI is defined in Framework of EFI S3 Resume Boot Path spec.\r
+  Version 0.9\r
+\r
+**/\r
+\r
+#ifndef __PEI_S3_RESUME_PPI_H__\r
+#define __PEI_S3_RESUME_PPI_H__\r
+\r
+#define EFI_PEI_S3_RESUME_PPI_GUID \\r
+  { \\r
+    0x4426CCB2, 0xE684, 0x4a8a, {0xAE, 0x40, 0x20, 0xD4, 0xB0, 0x25, 0xB7, 0x10 } \\r
+  }\r
+\r
+typedef struct _EFI_PEI_S3_RESUME_PPI   EFI_PEI_S3_RESUME_PPI;\r
+\r
+/**\r
+  Restores the platform to its preboot configuration for an S3 resume and\r
+  jumps to the OS waking vector.\r
+\r
+  @param  PeiServices    Pointer to the PEI Services Table\r
+\r
+  @retval EFI_ABORTED           Execution of the S3 resume boot script table failed.\r
+  @retval EFI_NOT_FOUND         Some necessary information that is used for\r
+                                the S3 resume boot path could not be located.\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_PEI_S3_RESUME_PPI_RESTORE_CONFIG) (\r
+  IN EFI_PEI_SERVICES   **PeiServices\r
+  );\r
+\r
+/**\r
+  @par Ppi Description:\r
+  EFI_PEI_S3_RESUME_PPI accomplishes the firmware S3 resume boot\r
+  path and transfers control to OS.\r
+\r
+  @param S3RestoreConfig\r
+  Restores the platform to its preboot configuration for an S3 resume and\r
+  jumps to the OS waking vector.\r
+\r
+**/\r
+struct _EFI_PEI_S3_RESUME_PPI {\r
+  EFI_PEI_S3_RESUME_PPI_RESTORE_CONFIG  S3RestoreConfig;\r
+};\r
+\r
+extern EFI_GUID gEfiPeiS3ResumePpiGuid;\r
+\r
+#endif\r
diff --git a/IntelFrameworkPkg/Include/Ppi/Smbus.h b/IntelFrameworkPkg/Include/Ppi/Smbus.h
new file mode 100644 (file)
index 0000000..54e6f58
--- /dev/null
@@ -0,0 +1,228 @@
+/** @file\r
+  This file declares Smbus PPI.\r
+\r
+  Copyright (c) 2007, Intel Corporation\r
+  All rights reserved. This program and the accompanying materials\r
+  are licensed and made available under the terms and conditions of the BSD License\r
+  which accompanies this distribution.  The full text of the license may be found at\r
+  http://opensource.org/licenses/bsd-license.php\r
+\r
+  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
+  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
+\r
+  Module Name:  Smbus.h\r
+\r
+  @par Revision Reference:\r
+  This PPI is defined in Framework of EFI SmBus PPI spec.\r
+  Version 0.9\r
+\r
+**/\r
+\r
+#ifndef _PEI_SMBUS_PPI_H\r
+#define _PEI_SMBUS_PPI_H\r
+\r
+#include <IndustryStandard/SmBus.h>\r
+\r
+#define EFI_PEI_SMBUS_PPI_GUID \\r
+  { \\r
+    0xabd42895, 0x78cf, 0x4872, {0x84, 0x44, 0x1b, 0x5c, 0x18, 0xb, 0xfb, 0xda } \\r
+  }\r
+\r
+typedef struct _EFI_PEI_SMBUS_PPI EFI_PEI_SMBUS_PPI;\r
+\r
+/**\r
+  Executes an SMBus operation to an SMBus controller.\r
+\r
+  @param  PeiServices    A pointer to the system PEI Services Table.\r
+  @param  This           A pointer to the EFI_PEI_SMBUS_PPI instance.\r
+  @param  SlaveAddress   The SMBUS hardware address to which the SMBUS\r
+                         device is preassigned or allocated.\r
+  @param  Command        This command is transmitted by the SMBus host\r
+                         controller to the SMBus slave device and the interpretation is\r
+                         SMBus slave device specific.\r
+  @param  Operation      Signifies which particular SMBus hardware protocol\r
+                         instance that it will use to execute the SMBus transactions.\r
+  @param  PecCheck       Defines if Packet Error Code (PEC) checking is required\r
+                         for this operation.\r
+  @param  Length         Signifies the number of bytes that this operation will do.\r
+  @param  Buffer         Contains the value of data to execute to the SMBus slave device.\r
+\r
+  @retval EFI_SUCCESS           The last data that was returned from the access\r
+                                matched the poll exit criteria.\r
+  @retval EFI_CRC_ERROR         The checksum is not correct (PEC is incorrect)\r
+  @retval EFI_TIMEOUT           Timeout expired before the operation was completed.\r
+                                Timeout is determined by the SMBus host controller device.\r
+  @retval EFI_OUT_OF_RESOURCES  The request could not be completed\r
+                                due to a lack of resources.\r
+  @retval EFI_DEVICE_ERROR      The request was not completed because\r
+                                a failure reflected in the Host Status Register bit.\r
+  @retval EFI_INVALID_PARAMETER Operation is not defined in EFI_SMBUS_OPERATION.\r
+                                Or Length/Buffer is NULL for operations except for EfiSmbusQuickRead and\r
+                                EfiSmbusQuickWrite. Length is outside the range of valid values.\r
+  @retval EFI_UNSUPPORTED       The SMBus operation or PEC is not supported.\r
+  @retval EFI_BUFFER_TOO_SMALL  Buffer is not sufficient for this operation.\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_PEI_SMBUS_PPI_EXECUTE_OPERATION) (\r
+  IN      EFI_PEI_SERVICES          **PeiServices,\r
+  IN EFI_PEI_SMBUS_PPI              *This,\r
+  IN      EFI_SMBUS_DEVICE_ADDRESS  SlaveAddress,\r
+  IN      EFI_SMBUS_DEVICE_COMMAND  Command,\r
+  IN      EFI_SMBUS_OPERATION       Operation,\r
+  IN      BOOLEAN                   PecCheck,\r
+  IN OUT  UINTN                     *Length,\r
+  IN OUT  VOID                      *Buffer\r
+  );\r
+\r
+typedef struct {\r
+  UINT32  VendorSpecificId;\r
+  UINT16  SubsystemDeviceId;\r
+  UINT16  SubsystemVendorId;\r
+  UINT16  Interface;\r
+  UINT16  DeviceId;\r
+  UINT16  VendorId;\r
+  UINT8   VendorRevision;\r
+  UINT8   DeviceCapabilities;\r
+} EFI_SMBUS_UDID;\r
+\r
+/**\r
+  CallBack function can be registered in EFI_PEI_SMBUS_PPI_NOTIFY.\r
+\r
+  @param  PeiServices    A pointer to the system PEI Services Table.\r
+  @param  This           A pointer to the EFI_PEI_SMBUS_PPI instance.\r
+  @param  SlaveAddress   The SMBUS hardware address to which the SMBUS\r
+                         device is preassigned or allocated.\r
+  @param  Data           Data of the SMBus host notify command that\r
+                         the caller wants to be called.\r
+\r
+  @return Status Code\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_PEI_SMBUS_NOTIFY_FUNCTION) (\r
+  IN      EFI_PEI_SERVICES              **PeiServices,\r
+  IN EFI_PEI_SMBUS_PPI                  *SmbusPpi,\r
+  IN      EFI_SMBUS_DEVICE_ADDRESS      SlaveAddress,\r
+  IN      UINTN                         Data\r
+  );\r
+\r
+/**\r
+  The ArpDevice() function enumerates the entire bus or enumerates a specific\r
+  device that is identified by SmbusUdid.\r
+\r
+  @param  PeiServices    A pointer to the system PEI Services Table.\r
+  @param  This           A pointer to the EFI_PEI_SMBUS_PPI instance.\r
+  @param  ArpAll         A Boolean expression that indicates if the host drivers need\r
+                         to enumerate all the devices or enumerate only the device that is identified\r
+                         by SmbusUdid. If ArpAll is TRUE, SmbusUdid and SlaveAddress are optional.\r
+                         If ArpAll is FALSE, ArpDevice will enumerate SmbusUdid and the address\r
+                         will be at SlaveAddress.\r
+  @param  SmbusUdid      The targeted SMBus Unique Device Identifier (UDID).\r
+                         The UDID may not exist for SMBus devices with fixed addresses.\r
+  @param  SlaveAddress   The new SMBus address for the slave device for\r
+                         which the operation is targeted.\r
+\r
+  @retval EFI_SUCCESS           The SMBus slave device address was set.\r
+  @retval EFI_INVALID_PARAMETER SlaveAddress is NULL.\r
+  @retval EFI_OUT_OF_RESOURCES  The request could not be completed\r
+                                due to a lack of resources.\r
+  @retval EFI_TIMEOUT           The SMBus slave device did not respond.\r
+  @retval EFI_DEVICE_ERROR      The request was not completed because the transaction failed.\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_PEI_SMBUS_PPI_ARP_DEVICE) (\r
+  IN      EFI_PEI_SERVICES          **PeiServices,\r
+  IN EFI_PEI_SMBUS_PPI              *This,\r
+  IN      BOOLEAN                   ArpAll,\r
+  IN      EFI_SMBUS_UDID            *SmbusUdid, OPTIONAL\r
+  IN OUT  EFI_SMBUS_DEVICE_ADDRESS  *SlaveAddress OPTIONAL\r
+  );\r
+\r
+typedef struct {\r
+  EFI_SMBUS_DEVICE_ADDRESS  SmbusDeviceAddress;\r
+  EFI_SMBUS_UDID            SmbusDeviceUdid;\r
+} EFI_SMBUS_DEVICE_MAP;\r
+\r
+/**\r
+  The GetArpMap() function returns the mapping of all the SMBus devices\r
+  that are enumerated by the SMBus host driver.\r
+\r
+  @param  PeiServices    A pointer to the system PEI Services Table.\r
+  @param  This           A pointer to the EFI_PEI_SMBUS_PPI instance.\r
+  @param  Length         Size of the buffer that contains the SMBus device map.\r
+  @param  SmbusDeviceMap The pointer to the device map as enumerated\r
+                         by the SMBus controller driver.\r
+\r
+  @retval EFI_SUCCESS           The device map was returned correctly in the buffer.\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_PEI_SMBUS_PPI_GET_ARP_MAP) (\r
+  IN      EFI_PEI_SERVICES          **PeiServices,\r
+  IN EFI_PEI_SMBUS_PPI              *This,\r
+  IN OUT  UINTN                     *Length,\r
+  IN OUT  EFI_SMBUS_DEVICE_MAP      **SmbusDeviceMap\r
+  );\r
+\r
+/**\r
+  The Notify() function registers all the callback functions to allow the\r
+  bus driver to call these functions when the SlaveAddress/Data pair happens.\r
+\r
+  @param  PeiServices    A pointer to the system PEI Services Table.\r
+  @param  This           A pointer to the EFI_PEI_SMBUS_PPI instance.\r
+  @param  SlaveAddress   Address that the host controller detects as\r
+                         sending a message and calls all the registered functions.\r
+  @param  Data           Data that the host controller detects as sending a message\r
+                         and calls all the registered functions.\r
+  @param  NotifyFunction The function to call when the bus driver\r
+                         detects the SlaveAddress and Data pair.\r
+\r
+  @retval EFI_SUCCESS           NotifyFunction has been registered.\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_PEI_SMBUS_PPI_NOTIFY) (\r
+  IN      EFI_PEI_SERVICES          **PeiServices,\r
+  IN EFI_PEI_SMBUS_PPI              *This,\r
+  IN      EFI_SMBUS_DEVICE_ADDRESS  SlaveAddress,\r
+  IN      UINTN                     Data,\r
+  IN  EFI_PEI_SMBUS_NOTIFY_FUNCTION NotifyFunction\r
+  );\r
+\r
+/**\r
+  @par Ppi Description:\r
+  Provides the basic I/O interfaces that a PEIM uses to access\r
+  its SMBus controller and the slave devices attached to it.\r
+\r
+  @param Execute\r
+  Executes the SMBus operation to an SMBus slave device.\r
+\r
+  @param ArpDevice\r
+  Allows an SMBus 2.0 device(s) to be Address Resolution Protocol (ARP)\r
+\r
+  @param GetArpMap\r
+  Allows a PEIM to retrieve the address that was allocated by the SMBus\r
+  host controller during enumeration/ARP.\r
+\r
+  @param Notify\r
+  Allows a driver to register for a callback to the SMBus host\r
+  controller driver when the bus issues a notification to the bus controller PEIM.\r
+\r
+**/\r
+struct _EFI_PEI_SMBUS_PPI {\r
+  EFI_PEI_SMBUS_PPI_EXECUTE_OPERATION Execute;\r
+  EFI_PEI_SMBUS_PPI_ARP_DEVICE        ArpDevice;\r
+  EFI_PEI_SMBUS_PPI_GET_ARP_MAP       GetArpMap;\r
+  EFI_PEI_SMBUS_PPI_NOTIFY            Notify;\r
+};\r
+\r
+extern EFI_GUID gEfiPeiSmbusPpiGuid;\r
+\r
+#endif\r
diff --git a/IntelFrameworkPkg/Include/Protocol/AcpiSupport.h b/IntelFrameworkPkg/Include/Protocol/AcpiSupport.h
new file mode 100644 (file)
index 0000000..b0fa68e
--- /dev/null
@@ -0,0 +1,161 @@
+/** @file\r
+  Definition of the ACPI Support protocol.\r
+\r
+  Copyright (c) 2007, Intel Corporation\r
+  All rights reserved. This program and the accompanying materials\r
+  are licensed and made available under the terms and conditions of the BSD License\r
+  which accompanies this distribution.  The full text of the license may be found at\r
+  http://opensource.org/licenses/bsd-license.php\r
+\r
+  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
+  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
+\r
+  Module Name:  AcpiSupport.h\r
+\r
+  @par Revision Reference:\r
+  This is defined in the ACPI Specification 0.9.\r
+\r
+**/\r
+\r
+#ifndef _ACPI_SUPPORT_PROTOCOL_H_\r
+#define _ACPI_SUPPORT_PROTOCOL_H_\r
+\r
+typedef struct _EFI_ACPI_SUPPORT_PROTOCOL EFI_ACPI_SUPPORT_PROTOCOL;\r
+\r
+//\r
+// ACPI Support Protocol GUID\r
+//\r
+#define EFI_ACPI_SUPPORT_GUID \\r
+  { \\r
+    0xdbff9d55, 0x89b7, 0x46da, {0xbd, 0xdf, 0x67, 0x7d, 0x3d, 0xc0, 0x24, 0x1d } \\r
+  }\r
+\r
+//\r
+// Protocol Data Definitions\r
+//\r
+//\r
+// ACPI Version bitmap definition:\r
+//\r
+// EFI_ACPI_TABLE_VERSION_1_0B - ACPI Version 1.0b\r
+// EFI_ACPI_TABLE_VERSION_2_0 - ACPI Version 2.0\r
+// EFI_ACPI_TABLE_VERSION_3_0 - ACPI Version 3.0\r
+// EFI_ACPI_TABLE_VERSION_NONE - No ACPI Versions.  This might be used\r
+//  to create memory-based operation regions or other information\r
+//  that is not part of the ACPI "tree" but must still be found\r
+//  in ACPI memory space and/or managed by the core ACPI driver.\r
+//\r
+// Note that EFI provides discrete GUIDs for each version of ACPI\r
+// that is supported.  It is expected that each EFI GUIDed\r
+// version of ACPI will also have a corresponding bitmap\r
+// definition.  This allows maintenance of separate ACPI trees\r
+// for each distinctly different version of ACPI.\r
+//\r
+#define EFI_ACPI_TABLE_VERSION      UINT32\r
+\r
+#define EFI_ACPI_TABLE_VERSION_NONE (1 << 0)\r
+#define EFI_ACPI_TABLE_VERSION_1_0B (1 << 1)\r
+#define EFI_ACPI_TABLE_VERSION_2_0  (1 << 2)\r
+#define EFI_ACPI_TABLE_VERSION_3_0  (1 << 3)\r
+\r
+//\r
+// Protocol Member Functions\r
+//\r
+\r
+/**\r
+  Returns a requested ACPI table.\r
+\r
+  @param  This                  A pointer to the EFI_ACPI_SUPPORT_PROTOCOL instance.\r
+  @param  Index                 The zero-based index of the table to retrieve.\r
+  @param  Table                 Pointer for returning the table buffer.\r
+  @param  Version               Updated with the ACPI versions to which this table belongs.\r
+  @param  Handle                Pointer for identifying the table.\r
+\r
+  @retval EFI_SUCCESS           The function completed successfully.\r
+  @retval EFI_NOT_FOUND         The requested index is too large and a table was not found.\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_ACPI_GET_ACPI_TABLE) (\r
+  IN EFI_ACPI_SUPPORT_PROTOCOL            *This,\r
+  IN INTN                                 Index,\r
+  OUT VOID                                **Table,\r
+  OUT EFI_ACPI_TABLE_VERSION              *Version,\r
+  OUT UINTN                               *Handle\r
+  );\r
+\r
+/**\r
+  Used to add, remove, or update ACPI tables.\r
+\r
+  @param  This                  A pointer to the EFI_ACPI_SUPPORT_PROTOCOL instance.\r
+  @param  Table                 Pointer to the new table to add or update.\r
+  @param  Checksum              If TRUE, indicates that the checksum should be\r
+                                calculated for this table.\r
+  @param  Version               Indicates to which version(s) of ACPI the table should be added.\r
+  @param  Pointer               to the handle of the table to remove or update.\r
+\r
+  @retval EFI_SUCCESS           The function completed successfully.\r
+  @retval EFI_INVALID_PARAMETER *Handle was zero and Table was NULL.\r
+  @retval EFI_ABORTED           Could not complete the desired action.\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_ACPI_SET_ACPI_TABLE) (\r
+  IN EFI_ACPI_SUPPORT_PROTOCOL            *This,\r
+  IN VOID                                 *Table OPTIONAL,\r
+  IN BOOLEAN                              Checksum,\r
+  IN EFI_ACPI_TABLE_VERSION               Version,\r
+  IN OUT UINTN                            *Handle\r
+  );\r
+\r
+/**\r
+  Causes one or more versions of the ACPI tables to be published in\r
+  the EFI system configuration tables.\r
+\r
+  @param  This                  A pointer to the EFI_ACPI_SUPPORT_PROTOCOL instance.\r
+  @param  Version               Indicates to which version(s) of ACPI that the table should be published.\r
+\r
+  @retval EFI_SUCCESS           The function completed successfully.\r
+  @retval EFI_ABORTED           An error occurred and the function could not complete successfully.\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_ACPI_PUBLISH_TABLES) (\r
+  IN EFI_ACPI_SUPPORT_PROTOCOL            *This,\r
+  IN EFI_ACPI_TABLE_VERSION               Version\r
+  );\r
+\r
+//\r
+// ACPI Support Protocol\r
+//\r
+/**\r
+  @par Protocol Description:\r
+  This protocol provides some basic services to support publishing ACPI system\r
+  tables. The services handle many of the more mundane tasks that are required\r
+  to publish a set of tables.\r
+\r
+  @param GetAcpiTable\r
+  Returns a table specified by an index if it exists.\r
+\r
+  @param SetAcpiTable\r
+  Adds, removes, or updates ACPI tables\r
+\r
+  @param PublishTables\r
+  Publishes the ACPI tables.\r
+\r
+**/\r
+struct _EFI_ACPI_SUPPORT_PROTOCOL {\r
+  EFI_ACPI_GET_ACPI_TABLE GetAcpiTable;\r
+  EFI_ACPI_SET_ACPI_TABLE SetAcpiTable;\r
+  EFI_ACPI_PUBLISH_TABLES PublishTables;\r
+};\r
+\r
+//\r
+// Extern the GUID for protocol users.\r
+//\r
+extern EFI_GUID gEfiAcpiSupportProtocolGuid;\r
+\r
+#endif\r
+\r
diff --git a/IntelFrameworkPkg/Include/Protocol/BootScriptSave.h b/IntelFrameworkPkg/Include/Protocol/BootScriptSave.h
new file mode 100644 (file)
index 0000000..fc34723
--- /dev/null
@@ -0,0 +1,102 @@
+/** @file\r
+  Definition of the Boot Script Save protocol.\r
+\r
+  Copyright (c) 2007, Intel Corporation\r
+  All rights reserved. This program and the accompanying materials\r
+  are licensed and made available under the terms and conditions of the BSD License\r
+  which accompanies this distribution.  The full text of the license may be found at\r
+  http://opensource.org/licenses/bsd-license.php\r
+\r
+  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
+  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
+\r
+  Module Name:  BootScriptSave.h\r
+\r
+  @par Revision Reference:\r
+  This protocol defined in the Boot Script Specification, Version 0.91.\r
+\r
+**/\r
+\r
+#ifndef _BOOT_SCRIPT_SAVE_PROTOCOL_H\r
+#define _BOOT_SCRIPT_SAVE_PROTOCOL_H\r
+\r
+//\r
+// S3 Save Protocol GUID\r
+//\r
+#define EFI_BOOT_SCRIPT_SAVE_PROTOCOL_GUID \\r
+  { \\r
+    0x470e1529, 0xb79e, 0x4e32, {0xa0, 0xfe, 0x6a, 0x15, 0x6d, 0x29, 0xf9, 0xb2 } \\r
+  }\r
+\r
+typedef struct _EFI_BOOT_SCRIPT_SAVE_PROTOCOL EFI_BOOT_SCRIPT_SAVE_PROTOCOL;\r
+\r
+//\r
+// Protocol Member_Function\r
+//\r
+/**\r
+  Adds a record into a specified Framework boot script table.\r
+\r
+  @param  This                  A pointer to the EFI_BOOT_SCRIPT_SAVE_PROTOCOL instance.\r
+  @param  TableName             Name of the script table.Currently, the only meaningful\r
+                                value is EFI_ACPI_S3_RESUME_SCRIPT_TABLE.\r
+  @param  OpCode                The operation code (opcode) number.\r
+  @param  ...                   Argument list that is specific to each opcode.\r
+\r
+  @retval EFI_SUCCESS           The operation succeeded. A record was added into the specified script table.\r
+  @retval EFI_INVALID_PARAMETER The parameter is illegal or the given boot script is not supported.\r
+  @retval EFI_OUT_OF_RESOURCES  There is insufficient memory to store the boot script.\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_BOOT_SCRIPT_WRITE) (\r
+  IN EFI_BOOT_SCRIPT_SAVE_PROTOCOL            *This,\r
+  IN UINT16                                   TableName,\r
+  IN UINT16                                   OpCode,\r
+  ...\r
+  );\r
+\r
+/**\r
+  Closes the specified script table.\r
+\r
+  @param  This                  A pointer to the EFI_BOOT_SCRIPT_SAVE_PROTOCOL instance.\r
+  @param  TableName             Name of the script table.\r
+  @param  Address               A pointer to the physical address where the table begins.\r
+\r
+  @retval EFI_SUCCESS           The table was successfully returned.\r
+  @retval EFI_NOT_FOUND         The specified table was not created previously.\r
+  @retval EFI_OUT_OF_RESOURCES  Memory is insufficient to hold the reorganized boot script table.\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_BOOT_SCRIPT_CLOSE_TABLE) (\r
+  IN EFI_BOOT_SCRIPT_SAVE_PROTOCOL            *This,\r
+  IN UINT16                                   TableName,\r
+  OUT EFI_PHYSICAL_ADDRESS                    *Address\r
+  );\r
+\r
+//\r
+// S3 Save Protocol data structure\r
+//\r
+/**\r
+  @par Protocol Description:\r
+  The EFI_BOOT_SCRIPT_SAVE_PROTOCOL publishes the Framework boot script abstractions\r
+  to store or record various boot scripts into boot script tables.\r
+\r
+  @param Write\r
+  Writes various boot scripts to a boot script table.\r
+\r
+  @param CloseTable\r
+  Retrieves and closes a script table.\r
+\r
+**/\r
+struct _EFI_BOOT_SCRIPT_SAVE_PROTOCOL {\r
+  EFI_BOOT_SCRIPT_WRITE       Write;\r
+  EFI_BOOT_SCRIPT_CLOSE_TABLE CloseTable;\r
+};\r
+\r
+extern EFI_GUID gEfiBootScriptSaveProtocolGuid;\r
+\r
+#endif\r
+\r
diff --git a/IntelFrameworkPkg/Include/Protocol/CpuIo.h b/IntelFrameworkPkg/Include/Protocol/CpuIo.h
new file mode 100644 (file)
index 0000000..38f910e
--- /dev/null
@@ -0,0 +1,125 @@
+/** @file\r
+  This code abstracts the CPU IO Protocol\r
+\r
+  Copyright (c) 2007, Intel Corporation\r
+  All rights reserved. This program and the accompanying materials\r
+  are licensed and made available under the terms and conditions of the BSD License\r
+  which accompanies this distribution.  The full text of the license may be found at\r
+  http://opensource.org/licenses/bsd-license.php\r
+\r
+  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
+  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
+\r
+  Module Name:  CpuIO.h\r
+\r
+  @par Revision Reference:\r
+  CPU IO Protocol is defined in Framework of EFI CPU IO Protocol Spec\r
+  Version 0.9\r
+\r
+**/\r
+\r
+#ifndef _CPUIO_H_\r
+#define _CPUIO_H_\r
+\r
+#define EFI_CPU_IO_PROTOCOL_GUID \\r
+  { \\r
+    0xB0732526, 0x38C8, 0x4b40, {0x88, 0x77, 0x61, 0xC7, 0xB0, 0x6A, 0xAC, 0x45 } \\r
+  }\r
+\r
+typedef struct _EFI_CPU_IO_PROTOCOL EFI_CPU_IO_PROTOCOL;\r
+\r
+//\r
+// *******************************************************\r
+// EFI_CPU_IO_PROTOCOL_WIDTH\r
+// *******************************************************\r
+//\r
+typedef enum {\r
+  EfiCpuIoWidthUint8,\r
+  EfiCpuIoWidthUint16,\r
+  EfiCpuIoWidthUint32,\r
+  EfiCpuIoWidthUint64,\r
+  EfiCpuIoWidthFifoUint8,\r
+  EfiCpuIoWidthFifoUint16,\r
+  EfiCpuIoWidthFifoUint32,\r
+  EfiCpuIoWidthFifoUint64,\r
+  EfiCpuIoWidthFillUint8,\r
+  EfiCpuIoWidthFillUint16,\r
+  EfiCpuIoWidthFillUint32,\r
+  EfiCpuIoWidthFillUint64,\r
+  EfiCpuIoWidthMaximum\r
+} EFI_CPU_IO_PROTOCOL_WIDTH;\r
+\r
+//\r
+// *******************************************************\r
+// EFI_CPU_IO_PROTOCOL_IO_MEM\r
+// *******************************************************\r
+//\r
+/**\r
+  Enables a driver to access memory-mapped registers in the EFI system memory space.\r
+  Or, Enables a driver to access registers in the EFI CPU I/O space.\r
+\r
+  @param  This                  A pointer to the EFI_CPU_IO_PROTOCOL instance.\r
+  @param  Width                 Signifies the width of the I/O or Memory operation.\r
+  @param  Address               The base address of the I/O or Memoryoperation.\r
+  @param  Count                 The number of I/O or Memory operations to perform.\r
+                                The number of bytes moved is Width size * Count, starting at Address.\r
+  @param  Buffer                For read operations, the destination buffer to store the results.\r
+                                For write operations, the source buffer from which to write data.\r
+\r
+  @retval EFI_SUCCESS           The data was read from or written to the EFI system.\r
+  @retval EFI_INVALID_PARAMETER Width is invalid for this EFI system.Or Buffer is NULL.\r
+  @retval EFI_UNSUPPORTED       The Buffer is not aligned for the given Width.\r
+                                Or,The address range specified by Address, Width, and Count is not valid for this EFI system.\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_CPU_IO_PROTOCOL_IO_MEM) (\r
+  IN EFI_CPU_IO_PROTOCOL                *This,\r
+  IN  EFI_CPU_IO_PROTOCOL_WIDTH         Width,\r
+  IN  UINT64                            Address,\r
+  IN  UINTN                             Count,\r
+  IN  OUT VOID                          *Buffer\r
+  );\r
+\r
+//\r
+// *******************************************************\r
+// EFI_CPU_IO_PROTOCOL_ACCESS\r
+// *******************************************************\r
+//\r
+typedef struct {\r
+  EFI_CPU_IO_PROTOCOL_IO_MEM  Read;\r
+  EFI_CPU_IO_PROTOCOL_IO_MEM  Write;\r
+} EFI_CPU_IO_PROTOCOL_ACCESS;\r
+\r
+//\r
+// *******************************************************\r
+// EFI_CPU_IO_PROTOCOL\r
+// *******************************************************\r
+//\r
+/**\r
+  @par Protocol Description:\r
+  Provides the basic memory and I/O interfaces that are used to abstract\r
+  accesses to devices in a system.\r
+\r
+  @param Mem.Read\r
+  Allows reads from memory-mapped I/O space.\r
+\r
+  @param Mem.Write\r
+  Allows writes to memory-mapped I/O space.\r
+\r
+  @param Io.Read\r
+  Allows reads from I/O space.\r
+\r
+  @param Io.Write\r
+  Allows writes to I/O space.\r
+\r
+**/\r
+struct _EFI_CPU_IO_PROTOCOL {\r
+  EFI_CPU_IO_PROTOCOL_ACCESS  Mem;\r
+  EFI_CPU_IO_PROTOCOL_ACCESS  Io;\r
+};\r
+\r
+extern EFI_GUID gEfiCpuIoProtocolGuid;\r
+\r
+#endif\r
diff --git a/IntelFrameworkPkg/Include/Protocol/DataHub.h b/IntelFrameworkPkg/Include/Protocol/DataHub.h
new file mode 100644 (file)
index 0000000..8af0964
--- /dev/null
@@ -0,0 +1,212 @@
+/** @file\r
+  The data hub protocol is used both by agents wishing to log\r
+  data and those wishing to be made aware of all information that\r
+  has been logged.\r
+\r
+  For more information please look at Intel Platform Innovation\r
+  Framework for EFI Data Hub Specification.\r
+\r
+  Copyright (c) 2007, Intel Corporation\r
+  All rights reserved. This program and the accompanying materials\r
+  are licensed and made available under the terms and conditions of the BSD License\r
+  which accompanies this distribution.  The full text of the license may be found at\r
+  http://opensource.org/licenses/bsd-license.php\r
+\r
+  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
+  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
+\r
+  Module Name:  DataHub.h\r
+\r
+  @par Revision Reference:\r
+  This protocol is defined in Framework for EFI Data Hub Specification.\r
+  Version 0.9.\r
+\r
+**/\r
+\r
+#ifndef _DATA_HUB_H_\r
+#define _DATA_HUB_H_\r
+\r
+#define EFI_DATA_HUB_PROTOCOL_GUID \\r
+  { \\r
+    0xae80d021, 0x618e, 0x11d4, {0xbc, 0xd7, 0x0, 0x80, 0xc7, 0x3c, 0x88, 0x81 } \\r
+  }\r
+\r
+//\r
+// EFI generic Data Hub Header\r
+//\r
+// A Data Record is an EFI_DATA_RECORD_HEADER followed by RecordSize bytes of\r
+//  data. The format of the data is defined by the DataRecordGuid.\r
+//\r
+// If EFI_DATA_RECORD_HEADER is extended in the future the Version number must\r
+//  change and the HeaderSize will change if the definition of\r
+//  EFI_DATA_RECORD_HEADER is extended.\r
+//\r
+// The logger is responcible for initializing:\r
+//  Version, HeaderSize, RecordSize, DataRecordGuid, DataRecordClass\r
+//\r
+// The Data Hub driver is responcible for initializing:\r
+//   LogTime and LogMonotonicCount.\r
+//\r
+#define EFI_DATA_RECORD_HEADER_VERSION  0x0100\r
+typedef struct {\r
+  UINT16    Version;\r
+  UINT16    HeaderSize;\r
+  UINT32    RecordSize;\r
+  EFI_GUID  DataRecordGuid;\r
+  EFI_GUID  ProducerName;\r
+  UINT64    DataRecordClass;\r
+  EFI_TIME  LogTime;\r
+  UINT64    LogMonotonicCount;\r
+} EFI_DATA_RECORD_HEADER;\r
+\r
+//\r
+// Definition of DataRecordClass. These are used to filter out class types\r
+// at a very high level. The DataRecordGuid still defines the format of\r
+// the data. See DateHub.doc for rules on what can and can not be a\r
+// new DataRecordClass\r
+//\r
+#define EFI_DATA_RECORD_CLASS_DEBUG         0x0000000000000001\r
+#define EFI_DATA_RECORD_CLASS_ERROR         0x0000000000000002\r
+#define EFI_DATA_RECORD_CLASS_DATA          0x0000000000000004\r
+#define EFI_DATA_RECORD_CLASS_PROGRESS_CODE 0x0000000000000008\r
+\r
+//\r
+// Forward reference for pure ANSI compatability\r
+//\r
+typedef struct _EFI_DATA_HUB_PROTOCOL EFI_DATA_HUB_PROTOCOL;\r
+\r
+/**\r
+  Logs a data record to the system event log.\r
+\r
+  @param  This                  The EFI_DATA_HUB_PROTOCOL instance.\r
+  @param  description\r
+  @param  DataRecordGuid        A GUID that indicates the format of the data passed into RawData.\r
+  @param  ProducerName          A GUID that indicates the identity of the caller to this API.\r
+  @param  DataRecordClass       This class indicates the generic type of the data record.\r
+  @param  RawData               The DataRecordGuid-defined data to be logged.\r
+  @param  RawDataSize           The size in bytes of RawData.\r
+\r
+  @retval EFI_SUCCESS           Data was logged.\r
+  @retval EFI_OUT_OF_RESOURCES  Data was not logged due to lack of system resources.\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_DATA_HUB_LOG_DATA) (\r
+  IN  EFI_DATA_HUB_PROTOCOL   *This,\r
+  IN  EFI_GUID                *DataRecordGuid,\r
+  IN  EFI_GUID                *ProducerName,\r
+  IN  UINT64                  DataRecordClass,\r
+  IN  VOID                    *RawData,\r
+  IN  UINT32                  RawDataSize\r
+  );\r
+\r
+/**\r
+  Allows the system data log to be searched.\r
+\r
+  @param  This                  The EFI_DATA_HUB_PROTOCOL instance.\r
+  @param  MonotonicCount        On input, it specifies the Record to return.\r
+                                An input of zero means to return the first record.\r
+  @param  FilterDriver          If FilterDriver is not passed in a MonotonicCount of zero,\r
+                                it means to return the first data record. If FilterDriver is passed in,\r
+                                then a MonotonicCount of zero means to return the first data not yet read\r
+                                by FilterDriver.\r
+  @param  Record                Returns a dynamically allocated memory buffer with a data\r
+                                record that matches MonotonicCount.\r
+\r
+  @retval EFI_SUCCESS           Data was returned in Record.\r
+  @retval EFI_INVALID_PARAMETER FilterDriver was passed in but does not exist.\r
+  @retval EFI_NOT_FOUND         MonotonicCount does not match any data record\r
+                                in the system. If a MonotonicCount of zero was passed in, then no\r
+                                data records exist in the system.\r
+  @retval EFI_OUT_OF_RESOURCES  Record was not returned due to lack\r
+                                of system resources.\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_DATA_HUB_GET_NEXT_RECORD) (\r
+  IN EFI_DATA_HUB_PROTOCOL    *This,\r
+  IN OUT  UINT64              *MonotonicCount,\r
+  IN  EFI_EVENT               *FilterDriver OPTIONAL,\r
+  OUT EFI_DATA_RECORD_HEADER  **Record\r
+  );\r
+\r
+/**\r
+  Registers an event to be signaled every time a data record is logged in the system.\r
+\r
+  @param  This                  The EFI_DATA_HUB_PROTOCOL instance.\r
+  @param  FilterEvent           The EFI_EVENT to signal whenever data that matches\r
+                                FilterClass is logged in the system.\r
+  @param  FilterTpl             The maximum EFI_TPL at which FilterEvent can be signaled.\r
+                                It is strongly recommended that you use the lowest EFI_TPL possible.\r
+  @param  FilterClass           FilterEvent will be signaled whenever a bit\r
+                                in EFI_DATA_RECORD_HEADER.DataRecordClass is also set in FilterClass.\r
+                                If FilterClass is zero, no class-based filtering will be performed.\r
+  @param  FilterDataRecordGuid  FilterEvent will be signaled whenever\r
+                                FilterDataRecordGuid matches EFI_DATA_RECORD_HEADER.DataRecordGuid.\r
+                                If FilterDataRecordGuid is NULL, then no GUID-based filtering will be performed.\r
+\r
+  @retval EFI_SUCCESS           The filter driver event was registered\r
+  @retval EFI_ALREADY_STARTED   FilterEvent was previously registered and cannot be registered again.\r
+  @retval EFI_OUT_OF_RESOURCES  The filter driver event was not registered\r
+                                due to lack of system resources.\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_DATA_HUB_REGISTER_FILTER_DRIVER) (\r
+  IN EFI_DATA_HUB_PROTOCOL    *This,\r
+  IN EFI_EVENT                FilterEvent,\r
+  IN EFI_TPL                  FilterTpl,\r
+  IN UINT64                   FilterClass,\r
+  IN EFI_GUID                 *FilterDataRecordGuid OPTIONAL\r
+  );\r
+\r
+/**\r
+  Stops a filter driver from being notified when data records are logged.\r
+\r
+  @param  This                  The EFI_DATA_HUB_PROTOCOL instance.\r
+  @param  FilterEvent           The EFI_EVENT to remove from the list of events to be\r
+                                signaled every time errors are logged.\r
+\r
+  @retval EFI_SUCCESS           The filter driver represented by FilterEvent was shut off.\r
+  @retval EFI_NOT_FOUND         FilterEvent did not exist.\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_DATA_HUB_UNREGISTER_FILTER_DRIVER) (\r
+  IN EFI_DATA_HUB_PROTOCOL    *This,\r
+  IN EFI_EVENT                FilterEvent\r
+  );\r
+\r
+/**\r
+  @par Protocol Description:\r
+  This protocol is used to log information and register filter drivers\r
+  to receive data records.\r
+\r
+  @param LogData\r
+  Logs a data record.\r
+\r
+  @param GetNextDataRecord\r
+  Gets a data record. Used both to view the memory-based log and to\r
+  get information about which data records have been consumed by a filter driver.\r
+\r
+  @param RegisterFilterDriver\r
+  Allows the registration of an EFI event to act as a filter driver for all data records that are logged.\r
+\r
+  @param UnregisterFilterDriver\r
+  Used to remove a filter driver that was added with RegisterFilterDriver().\r
+\r
+**/\r
+struct _EFI_DATA_HUB_PROTOCOL {\r
+  EFI_DATA_HUB_LOG_DATA                 LogData;\r
+  EFI_DATA_HUB_GET_NEXT_RECORD          GetNextRecord;\r
+  EFI_DATA_HUB_REGISTER_FILTER_DRIVER   RegisterFilterDriver;\r
+  EFI_DATA_HUB_UNREGISTER_FILTER_DRIVER UnregisterFilterDriver;\r
+};\r
+\r
+extern EFI_GUID gEfiDataHubProtocolGuid;\r
+\r
+#endif\r
diff --git a/IntelFrameworkPkg/Include/Protocol/FirmwareVolume.h b/IntelFrameworkPkg/Include/Protocol/FirmwareVolume.h
new file mode 100644 (file)
index 0000000..50c53d5
--- /dev/null
@@ -0,0 +1,319 @@
+/** @file\r
+  This file declares Firmware Volume protocol.\r
+\r
+  Copyright (c) 2007, Intel Corporation\r
+  All rights reserved. This program and the accompanying materials\r
+  are licensed and made available under the terms and conditions of the BSD License\r
+  which accompanies this distribution.  The full text of the license may be found at\r
+  http://opensource.org/licenses/bsd-license.php\r
+\r
+  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
+  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
+\r
+  Module Name:  FirmwareVolume.h\r
+\r
+  @par Revision Reference:\r
+  This protocol is defined in Firmware Volume specification.\r
+  Version 0.9\r
+\r
+**/\r
+\r
+#ifndef _FIRMWARE_VOLUME_H_\r
+#define _FIRMWARE_VOLUME_H_\r
+\r
+\r
+//\r
+// Firmware Volume Protocol GUID definition\r
+//\r
+#define EFI_FIRMWARE_VOLUME_PROTOCOL_GUID \\r
+  { \\r
+    0x389F751F, 0x1838, 0x4388, {0x83, 0x90, 0xCD, 0x81, 0x54, 0xBD, 0x27, 0xF8 } \\r
+  }\r
+\r
+#define FV_DEVICE_SIGNATURE EFI_SIGNATURE_32 ('_', 'F', 'V', '_')\r
+\r
+typedef struct _EFI_FIRMWARE_VOLUME_PROTOCOL  EFI_FIRMWARE_VOLUME_PROTOCOL;\r
+\r
+//\r
+// EFI_FV_ATTRIBUTES bit definitions\r
+//\r
+typedef UINT64  EFI_FV_ATTRIBUTES;\r
+\r
+//\r
+// ************************************************************\r
+// EFI_FV_ATTRIBUTES bit definitions\r
+// ************************************************************\r
+//\r
+#define EFI_FV_READ_DISABLE_CAP       0x0000000000000001ULL\r
+#define EFI_FV_READ_ENABLE_CAP        0x0000000000000002ULL\r
+#define EFI_FV_READ_STATUS            0x0000000000000004ULL\r
+\r
+#define EFI_FV_WRITE_DISABLE_CAP      0x0000000000000008ULL\r
+#define EFI_FV_WRITE_ENABLE_CAP       0x0000000000000010ULL\r
+#define EFI_FV_WRITE_STATUS           0x0000000000000020ULL\r
+\r
+#define EFI_FV_LOCK_CAP               0x0000000000000040ULL\r
+#define EFI_FV_LOCK_STATUS            0x0000000000000080ULL\r
+#define EFI_FV_WRITE_POLICY_RELIABLE  0x0000000000000100ULL\r
+\r
+#define EFI_FV_ALIGNMENT_CAP          0x0000000000008000ULL\r
+#define EFI_FV_ALIGNMENT_2            0x0000000000010000ULL\r
+#define EFI_FV_ALIGNMENT_4            0x0000000000020000ULL\r
+#define EFI_FV_ALIGNMENT_8            0x0000000000040000ULL\r
+#define EFI_FV_ALIGNMENT_16           0x0000000000080000ULL\r
+#define EFI_FV_ALIGNMENT_32           0x0000000000100000ULL\r
+#define EFI_FV_ALIGNMENT_64           0x0000000000200000ULL\r
+#define EFI_FV_ALIGNMENT_128          0x0000000000400000ULL\r
+#define EFI_FV_ALIGNMENT_256          0x0000000000800000ULL\r
+#define EFI_FV_ALIGNMENT_512          0x0000000001000000ULL\r
+#define EFI_FV_ALIGNMENT_1K           0x0000000002000000ULL\r
+#define EFI_FV_ALIGNMENT_2K           0x0000000004000000ULL\r
+#define EFI_FV_ALIGNMENT_4K           0x0000000008000000ULL\r
+#define EFI_FV_ALIGNMENT_8K           0x0000000010000000ULL\r
+#define EFI_FV_ALIGNMENT_16K          0x0000000020000000ULL\r
+#define EFI_FV_ALIGNMENT_32K          0x0000000040000000ULL\r
+#define EFI_FV_ALIGNMENT_64K          0x0000000080000000ULL\r
+\r
+//\r
+// Protocol API definitions\r
+//\r
+\r
+/**\r
+  Retrieves attributes, insures positive polarity of attribute bits, returns\r
+  resulting attributes in output parameter\r
+\r
+  @param  This                  Calling context\r
+  @param  Attributes            output buffer which contains attributes\r
+\r
+  @retval EFI_INVALID_PARAMETER\r
+  @retval EFI_SUCCESS\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_FV_GET_ATTRIBUTES) (\r
+  IN  EFI_FIRMWARE_VOLUME_PROTOCOL  *This,\r
+  OUT EFI_FV_ATTRIBUTES             *Attributes\r
+  );\r
+\r
+/**\r
+  Sets volume attributes\r
+\r
+  @param  This                  Calling context\r
+  @param  Attributes            Buffer which contains attributes\r
+\r
+  @retval EFI_INVALID_PARAMETER\r
+  @retval EFI_DEVICE_ERROR\r
+  @retval EFI_SUCCESS\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_FV_SET_ATTRIBUTES) (\r
+  IN EFI_FIRMWARE_VOLUME_PROTOCOL   *This,\r
+  IN OUT EFI_FV_ATTRIBUTES          *Attributes\r
+  );\r
+\r
+typedef UINT32  EFI_FV_FILE_ATTRIBUTES;\r
+\r
+#define EFI_FV_FILE_ATTRIB_ALIGNMENT  0x0000001F\r
+\r
+/**\r
+  Read the requested file (NameGuid) and returns data in Buffer.\r
+\r
+  @param  This                  Calling context\r
+  @param  NameGuid              Filename identifying which file to read\r
+  @param  Buffer                Pointer to pointer to buffer in which contents of file are returned.\r
+                                <br>\r
+                                If Buffer is NULL, only type, attributes, and size are returned as\r
+                                there is no output buffer.\r
+                                <br>\r
+                                If Buffer != NULL and *Buffer == NULL, the output buffer is allocated\r
+                                from BS pool by ReadFile\r
+                                <br>\r
+                                If Buffer != NULL and *Buffer != NULL, the output buffer has been\r
+                                allocated by the caller and is being passed in.\r
+  @param  BufferSize            Indicates the buffer size passed in, and on output the size\r
+                                required to complete the read\r
+  @param  FoundType             Indicates the type of the file who's data is returned\r
+  @param  FileAttributes        Indicates the attributes of the file who's data is resturned\r
+  @param  AuthenticationStatus  Indicates the authentication status of the data\r
+\r
+  @retval EFI_SUCCESS\r
+  @retval EFI_WARN_BUFFER_TOO_SMALL\r
+  @retval EFI_NOT_FOUND\r
+  @retval EFI_DEVICE_ERROR\r
+  @retval EFI_ACCESS_DENIED\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_FV_READ_FILE) (\r
+  IN EFI_FIRMWARE_VOLUME_PROTOCOL   *This,\r
+  IN EFI_GUID                       *NameGuid,\r
+  IN OUT VOID                       **Buffer,\r
+  IN OUT UINTN                      *BufferSize,\r
+  OUT EFI_FV_FILETYPE               *FoundType,\r
+  OUT EFI_FV_FILE_ATTRIBUTES        *FileAttributes,\r
+  OUT UINT32                        *AuthenticationStatus\r
+  );\r
+\r
+/**\r
+  Read the requested section from the specified file and returns data in Buffer.\r
+\r
+  @param  This                  Calling context\r
+  @param  NameGuid              Filename identifying the file from which to read\r
+  @param  SectionType           Indicates what section type to retrieve\r
+  @param  SectionInstance       Indicates which instance of SectionType to retrieve\r
+  @param  Buffer                Pointer to pointer to buffer in which contents of file are returned.\r
+                                <br>\r
+                                If Buffer is NULL, only type, attributes, and size are returned as\r
+                                there is no output buffer.\r
+                                <br>\r
+                                If Buffer != NULL and *Buffer == NULL, the output buffer is allocated\r
+                                from BS pool by ReadFile\r
+                                <br>\r
+                                If Buffer != NULL and *Buffer != NULL, the output buffer has been\r
+                                allocated by the caller and is being passed in.\r
+  @param  BufferSize            Indicates the buffer size passed in, and on output the size\r
+                                required to complete the read\r
+  @param  AuthenticationStatus  Indicates the authentication status of the data\r
+\r
+  @retval EFI_SUCCESS\r
+  @retval EFI_WARN_BUFFER_TOO_SMALL\r
+  @retval EFI_OUT_OF_RESOURCES\r
+  @retval EFI_NOT_FOUND\r
+  @retval EFI_DEVICE_ERROR\r
+  @retval EFI_ACCESS_DENIED\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_FV_READ_SECTION) (\r
+  IN EFI_FIRMWARE_VOLUME_PROTOCOL   *This,\r
+  IN EFI_GUID                       *NameGuid,\r
+  IN EFI_SECTION_TYPE               SectionType,\r
+  IN UINTN                          SectionInstance,\r
+  IN OUT VOID                       **Buffer,\r
+  IN OUT UINTN                      *BufferSize,\r
+  OUT UINT32                        *AuthenticationStatus\r
+  );\r
+\r
+typedef UINT32  EFI_FV_WRITE_POLICY;\r
+\r
+#define EFI_FV_UNRELIABLE_WRITE 0x00000000\r
+#define EFI_FV_RELIABLE_WRITE   0x00000001\r
+\r
+typedef struct {\r
+  EFI_GUID                *NameGuid;\r
+  EFI_FV_FILETYPE         Type;\r
+  EFI_FV_FILE_ATTRIBUTES  FileAttributes;\r
+  VOID                    *Buffer;\r
+  UINT32                  BufferSize;\r
+} EFI_FV_WRITE_FILE_DATA;\r
+\r
+/**\r
+  Write the supplied file (NameGuid) to the FV.\r
+\r
+  @param  This                  Calling context\r
+  @param  NumberOfFiles         Indicates the number of file records pointed to by FileData\r
+  @param  WritePolicy           Indicates the level of reliability of the write with respect to\r
+                                things like power failure events.\r
+  @param  FileData              A pointer to an array of EFI_FV_WRITE_FILE_DATA structures. Each\r
+                                element in the array indicates a file to write, and there are\r
+                                NumberOfFiles elements in the input array.\r
+\r
+  @retval EFI_SUCCESS\r
+  @retval EFI_OUT_OF_RESOURCES\r
+  @retval EFI_DEVICE_ERROR\r
+  @retval EFI_WRITE_PROTECTED\r
+  @retval EFI_NOT_FOUND\r
+  @retval EFI_INVALID_PARAMETER\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_FV_WRITE_FILE) (\r
+  IN EFI_FIRMWARE_VOLUME_PROTOCOL   *This,\r
+  IN UINT32                         NumberOfFiles,\r
+  IN EFI_FV_WRITE_POLICY            WritePolicy,\r
+  IN EFI_FV_WRITE_FILE_DATA         *FileData\r
+  );\r
+\r
+/**\r
+  Given the input key, search for the next matching file in the volume.\r
+\r
+  @param  This                  Calling context\r
+  @param  Key                   Pointer to a caller allocated buffer that contains an implementation\r
+                                specific key that is used to track where to begin searching on\r
+                                successive calls.\r
+  @param  FileType              Indicates the file type to filter for\r
+  @param  NameGuid              Guid filename of the file found\r
+  @param  Attributes            Attributes of the file found\r
+  @param  Size                  Size in bytes of the file found\r
+\r
+  @retval EFI_SUCCESS\r
+  @retval EFI_NOT_FOUND\r
+  @retval EFI_DEVICE_ERROR\r
+  @retval EFI_ACCESS_DENIED\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_FV_GET_NEXT_FILE) (\r
+  IN EFI_FIRMWARE_VOLUME_PROTOCOL   *This,\r
+  IN OUT VOID                       *Key,\r
+  IN OUT EFI_FV_FILETYPE            *FileType,\r
+  OUT EFI_GUID                      *NameGuid,\r
+  OUT EFI_FV_FILE_ATTRIBUTES        *Attributes,\r
+  OUT UINTN                         *Size\r
+  );\r
+\r
+/**\r
+  @par Protocol Description:\r
+  The Firmware Volume Protocol provides file-level access to the firmware volume.\r
+  Each firmware volume driver must produce an instance of the Firmware Volume\r
+  Protocol if the firmware volume is to be visible to the system. The Firmware\r
+  Volume Protocol also provides mechanisms for determining and modifying some\r
+  attributes of the firmware volume.\r
+\r
+  @param GetVolumeAttributes\r
+  Retrieves volume capabilities and current settings.\r
+\r
+  @param SetVolumeAttributes\r
+  Modifies the current settings of the firmware volume.\r
+\r
+  @param ReadFile\r
+  Reads an entire file from the firmware volume.\r
+\r
+  @param ReadSection\r
+  Reads a single section from a file into a buffer.\r
+\r
+  @param WriteFile\r
+  Writes an entire file into the firmware volume.\r
+\r
+  @param GetNextFile\r
+  Provides service to allow searching the firmware volume.\r
+\r
+  @param KeySize\r
+  Data field that indicates the size in bytes of the Key input buffer for\r
+  the GetNextFile() API.\r
+\r
+  @param ParentHandle\r
+  Handle of the parent firmware volume.\r
+\r
+**/\r
+struct _EFI_FIRMWARE_VOLUME_PROTOCOL {\r
+  EFI_FV_GET_ATTRIBUTES GetVolumeAttributes;\r
+  EFI_FV_SET_ATTRIBUTES SetVolumeAttributes;\r
+  EFI_FV_READ_FILE      ReadFile;\r
+  EFI_FV_READ_SECTION   ReadSection;\r
+  EFI_FV_WRITE_FILE     WriteFile;\r
+  EFI_FV_GET_NEXT_FILE  GetNextFile;\r
+  UINT32                KeySize;\r
+  EFI_HANDLE            ParentHandle;\r
+};\r
+\r
+extern EFI_GUID gEfiFirmwareVolumeProtocolGuid;\r
+\r
+#endif\r
diff --git a/IntelFrameworkPkg/Include/Protocol/FirmwareVolumeBlock.h b/IntelFrameworkPkg/Include/Protocol/FirmwareVolumeBlock.h
new file mode 100644 (file)
index 0000000..f397f59
--- /dev/null
@@ -0,0 +1,251 @@
+/** @file\r
+  This file declares Firmware Volume Block protocol.\r
+\r
+  Low level firmware device access routines to abstract firmware device\r
+  hardware.\r
+\r
+  Copyright (c) 2007, Intel Corporation\r
+  All rights reserved. This program and the accompanying materials\r
+  are licensed and made available under the terms and conditions of the BSD License\r
+  which accompanies this distribution.  The full text of the license may be found at\r
+  http://opensource.org/licenses/bsd-license.php\r
+\r
+  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
+  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
+\r
+  Module Name:  FirmwareVolumeBlock.h\r
+\r
+  @par Revision Reference:\r
+  This protocol is defined in Framework of EFI Firmware Volume Block specification.\r
+  Version 0.9\r
+\r
+**/\r
+\r
+#ifndef _FIRMWARE_VOLUME_BLOCK_H_\r
+#define _FIRMWARE_VOLUME_BLOCK_H_\r
+\r
+\r
+#define EFI_FIRMWARE_VOLUME_BLOCK_PROTOCOL_GUID \\r
+  { \\r
+    0xDE28BC59, 0x6228, 0x41BD, {0xBD, 0xF6, 0xA3, 0xB9, 0xAD, 0xB5, 0x8D, 0xA1 } \\r
+  }\r
+\r
+typedef struct _EFI_FIRMWARE_VOLUME_BLOCK_PROTOCOL  EFI_FIRMWARE_VOLUME_BLOCK_PROTOCOL;\r
+\r
+/**\r
+  Retrieves Volume attributes.  No polarity translations are done.\r
+\r
+  @param  This                  Calling context\r
+  @param  Attributes            output buffer which contains attributes\r
+\r
+  @retval EFI_INVALID_PARAMETER\r
+  @retval EFI_SUCCESS\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_FVB_GET_ATTRIBUTES) (\r
+  IN EFI_FIRMWARE_VOLUME_BLOCK_PROTOCOL           *This,\r
+  OUT EFI_FVB_ATTRIBUTES                          *Attributes\r
+  )\r
+;\r
+\r
+/**\r
+  Sets Volume attributes.  No polarity translations are done.\r
+\r
+  @param  This                  Calling context\r
+  @param  Attributes            On input: contains new attributes\r
+                                On output: contains current attributes of FV\r
+\r
+  @retval EFI_INVALID_PARAMETER\r
+  @retval EFI_SUCCESS\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_FVB_SET_ATTRIBUTES) (\r
+  IN EFI_FIRMWARE_VOLUME_BLOCK_PROTOCOL           *This,\r
+  IN OUT EFI_FVB_ATTRIBUTES                       *Attributes\r
+  )\r
+;\r
+\r
+/**\r
+  Retrieves the physical address of a memory mapped FV.\r
+\r
+  @param  This                  Calling context\r
+  @param  Attributes            Address is a pointer to a caller allocated EFI_PHYSICAL_ADDRESS\r
+                                that on successful return from GetPhysicalAddress() contains the\r
+                                base address of the firmware volume.\r
+\r
+  @retval EFI_UNSUPPORTED\r
+  @retval EFI_SUCCESS\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_FVB_GET_PHYSICAL_ADDRESS) (\r
+  IN EFI_FIRMWARE_VOLUME_BLOCK_PROTOCOL           *This,\r
+  OUT EFI_PHYSICAL_ADDRESS                        *Address\r
+  )\r
+;\r
+\r
+/**\r
+  Retrieves the size in bytes of a specific block within an FV.\r
+\r
+  @param  This                  Calling context.\r
+  @param  Lba                   Indicates which block to return the size for.\r
+  @param  BlockSize             BlockSize is a pointer to a caller allocated\r
+                                UINTN in which the size of the block is returned.\r
+  @param  NumberOfBlocks        NumberOfBlocks is a pointer to a caller allocated\r
+                                UINTN in which the number of consecutive blocks\r
+                                starting with Lba is returned. All blocks in this\r
+                                range have a size of BlockSize.\r
+\r
+  @retval EFI_INVALID_PARAMETER\r
+  @retval EFI_SUCCESS\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_FVB_GET_BLOCK_SIZE) (\r
+  IN EFI_FIRMWARE_VOLUME_BLOCK_PROTOCOL           *This,\r
+  IN EFI_LBA                                      Lba,\r
+  OUT UINTN                                       *BlockSize,\r
+  OUT UINTN                                       *NumberOfBlocks\r
+  )\r
+;\r
+\r
+/**\r
+  Reads data beginning at Lba:Offset from FV and places the data in Buffer.\r
+  The read terminates either when *NumBytes of data have been read, or when\r
+  a block boundary is reached.  *NumBytes is updated to reflect the actual\r
+  number of bytes read.\r
+\r
+  @param  This                  Calling context\r
+  @param  Lba                   Block in which to begin read\r
+  @param  Offset                Offset in the block at which to begin read\r
+  @param  NumBytes              At input, indicates the requested read size. At output, indicates\r
+                                the actual number of bytes read.\r
+  @param  Buffer                Data buffer in which to place data read.\r
+\r
+  @retval EFI_INVALID_PARAMETER\r
+  @retval EFI_NOT_FOUND\r
+  @retval EFI_DEVICE_ERROR\r
+  @retval EFI_SUCCESS\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_FVB_READ) (\r
+  IN EFI_FIRMWARE_VOLUME_BLOCK_PROTOCOL           *This,\r
+  IN EFI_LBA                                      Lba,\r
+  IN UINTN                                        Offset,\r
+  IN OUT UINTN                                    *NumBytes,\r
+  OUT UINT8                                       *Buffer\r
+  )\r
+;\r
+\r
+/**\r
+  Writes data beginning at Lba:Offset from FV. The write terminates either\r
+  when *NumBytes of data have been written, or when a block boundary is\r
+  reached.  *NumBytes is updated to reflect the actual number of bytes\r
+  written.\r
+\r
+  @param  This                  Calling context\r
+  @param  Lba                   Block in which to begin write\r
+  @param  Offset                Offset in the block at which to begin write\r
+  @param  NumBytes              At input, indicates the requested write size. At output, indicates\r
+                                the actual number of bytes written.\r
+  @param  Buffer                Buffer containing source data for the write.\r
+\r
+  @retval EFI_INVALID_PARAMETER\r
+  @retval EFI_NOT_FOUND\r
+  @retval EFI_DEVICE_ERROR\r
+  @retval EFI_SUCCESS\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_FVB_WRITE) (\r
+  IN EFI_FIRMWARE_VOLUME_BLOCK_PROTOCOL           *This,\r
+  IN EFI_LBA                                      Lba,\r
+  IN UINTN                                        Offset,\r
+  IN OUT UINTN                                    *NumBytes,\r
+  IN UINT8                                        *Buffer\r
+  )\r
+;\r
+\r
+#define EFI_LBA_LIST_TERMINATOR 0xFFFFFFFFFFFFFFFFULL\r
+\r
+/**\r
+  The EraseBlock() function erases one or more blocks as denoted by the\r
+  variable argument list. The entire parameter list of blocks must be verified\r
+  prior to erasing any blocks.  If a block is requested that does not exist\r
+  within the associated firmware volume (it has a larger index than the last\r
+  block of the firmware volume), the EraseBlock() function must return\r
+  EFI_INVALID_PARAMETER without modifying the contents of the firmware volume.\r
+\r
+  @param  This                  Calling context\r
+  @param  ...                   Starting LBA followed by Number of Lba to erase. a -1 to terminate\r
+                                the list.\r
+\r
+  @retval EFI_INVALID_PARAMETER\r
+  @retval EFI_DEVICE_ERROR\r
+  @retval EFI_SUCCESS\r
+  @retval EFI_ACCESS_DENIED\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_FVB_ERASE_BLOCKS) (\r
+  IN EFI_FIRMWARE_VOLUME_BLOCK_PROTOCOL           *This,\r
+  ...\r
+  )\r
+;\r
+\r
+/**\r
+  @par Protocol Description:\r
+  This protocol provides control over block-oriented firmware devices.\r
+  Typically, the FFS (or an alternate file system) driver consumes the\r
+  Firmware Volume Block Protocol and produces the Firmware Volume Protocol.\r
+\r
+  @param GetAttributes\r
+  Retrieves the current volume attributes.\r
+\r
+  @param SetAttributes\r
+  Sets the current volume attributes.\r
+\r
+  @param GetPhysicalAddress\r
+  Retrieves the memory-mapped address of the firmware volume.\r
+\r
+  @param GetBlockSize\r
+  Retrieves the size for a specific block.\r
+\r
+  @param Read\r
+  Reads n bytes into a buffer from the firmware volume hardware.\r
+\r
+  @param Write\r
+  Writes n bytes from a buffer into the firmware volume hardware.\r
+\r
+  @param EraseBlocks\r
+  Erases specified block(s) and sets all values as indicated by\r
+  the EFI_FVB_ERASE_POLARITY bit.\r
+\r
+  @param ParentHandle\r
+  Handle of the parent firmware volume.\r
+\r
+**/\r
+struct _EFI_FIRMWARE_VOLUME_BLOCK_PROTOCOL {\r
+  EFI_FVB_GET_ATTRIBUTES        GetVolumeAttributes;\r
+  EFI_FVB_SET_ATTRIBUTES        SetVolumeAttributes;\r
+  EFI_FVB_GET_PHYSICAL_ADDRESS  GetPhysicalAddress;\r
+  EFI_FVB_GET_BLOCK_SIZE        GetBlockSize;\r
+  EFI_FVB_READ                  Read;\r
+  EFI_FVB_WRITE                 Write;\r
+  EFI_FVB_ERASE_BLOCKS          EraseBlocks;\r
+  EFI_HANDLE                    ParentHandle;\r
+};\r
+\r
+extern EFI_GUID gEfiFirmwareVolumeBlockProtocolGuid;\r
+\r
+#endif\r
diff --git a/IntelFrameworkPkg/Include/Protocol/Hii.h b/IntelFrameworkPkg/Include/Protocol/Hii.h
new file mode 100644 (file)
index 0000000..fbecbef
--- /dev/null
@@ -0,0 +1,942 @@
+/** @file\r
+  This file defines the Human Interface Infrastructure protocol which will\r
+  be used by resources which want to publish IFR/Font/String data and have it\r
+  collected by the Configuration engine.\r
+\r
+  Copyright (c) 2007, Intel Corporation\r
+  All rights reserved. This program and the accompanying materials\r
+  are licensed and made available under the terms and conditions of the BSD License\r
+  which accompanies this distribution.  The full text of the license may be found at\r
+  http://opensource.org/licenses/bsd-license.php\r
+\r
+  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
+  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
+\r
+  Module Name:  Hii.h\r
+\r
+  @par Revision Reference:\r
+  This protocol is defined in HII spec 0.92.\r
+\r
+**/\r
+\r
+#ifndef _HII_H_\r
+#define _HII_H_\r
+\r
+#define EFI_HII_PROTOCOL_GUID \\r
+  { \\r
+    0xd7ad636e, 0xb997, 0x459b, {0xbf, 0x3f, 0x88, 0x46, 0x89, 0x79, 0x80, 0xe1} \\r
+  }\r
+\r
+// BugBug:\r
+//++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++\r
+// If UGA goes away we need to put this some place. I'm not sure where?\r
+//\r
+//typedef struct {\r
+//  UINT8 Blue;\r
+//  UINT8 Green;\r
+//  UINT8 Red;\r
+//  UINT8 Reserved;\r
+//} EFI_UGA_PIXEL;\r
+\r
+//++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++\r
+//\r
+\r
+typedef struct _EFI_HII_PROTOCOL  EFI_HII_PROTOCOL;\r
+\r
+//\r
+// Global definition\r
+//\r
+#define NARROW_CHAR         0xFFF0\r
+#define WIDE_CHAR           0xFFF1\r
+#define NON_BREAKING_CHAR   0xFFF2\r
+#define GLYPH_WIDTH         8\r
+#define GLYPH_HEIGHT        19\r
+\r
+#define EFI_HII_FONT        1\r
+#define EFI_HII_STRING      2\r
+#define EFI_HII_IFR         3\r
+#define EFI_HII_KEYBOARD    4\r
+#define EFI_HII_HANDLES     5\r
+#define EFI_HII_VARIABLE    6\r
+#define EFI_HII_DEVICE_PATH 7\r
+\r
+\r
+// References to string tokens must use this macro to enable scanning for\r
+// token usages.\r
+//\r
+#define STRING_TOKEN(t) t\r
+\r
+//\r
+// The following types are currently defined:\r
+//\r
+typedef UINT16  EFI_FORM_ID;\r
+typedef UINT16  EFI_FORM_LABEL;\r
+\r
+#pragma pack(1)\r
+\r
+typedef struct {\r
+  UINT32  Length;\r
+  UINT16  Type;\r
+} EFI_HII_PACK_HEADER;\r
+\r
+//\r
+// A form list consists of a large variety of structure\r
+// possibilities so to represent the binary blob of data\r
+// associated with a package of forms, we will assume a\r
+// pointer to a self-describing data buffer.\r
+//\r
+typedef struct {\r
+  EFI_HII_PACK_HEADER Header;\r
+} EFI_HII_IFR_PACK;\r
+\r
+typedef struct {\r
+  EFI_HII_PACK_HEADER Header;           // Must be filled in\r
+  EFI_HANDLE          ImageHandle;      // Must be filled in\r
+  EFI_HANDLE          DeviceHandle;     // Optional\r
+  EFI_HANDLE          ControllerHandle; // Optional\r
+  EFI_HANDLE          CallbackHandle;   // Optional\r
+  EFI_HANDLE          COBExportHandle;  // Optional\r
+} EFI_HII_HANDLE_PACK;\r
+\r
+//\r
+// ********************************************************\r
+// EFI_VARIABLE_CONTENTS\r
+// ********************************************************\r
+//\r
+typedef struct {\r
+  EFI_HII_PACK_HEADER Header;\r
+  EFI_GUID            VariableGuid;\r
+  UINT32              VariableNameLength;\r
+  UINT16              VariableId;\r
+  //\r
+  //  CHAR16                VariableName[]; //Null-terminated\r
+  //\r
+} EFI_HII_VARIABLE_PACK;\r
+\r
+//\r
+// ********************************************************\r
+// EFI_DEVICE_PATH_PACK\r
+// ********************************************************\r
+//\r
+typedef struct {\r
+  EFI_HII_PACK_HEADER Header;\r
+  //\r
+  //  EFI_DEVICE_PATH       DevicePath[];\r
+  //\r
+} EFI_HII_DEVICE_PATH_PACK;\r
+\r
+//\r
+// ********************************************************\r
+// EFI_HII_DATA_TABLE\r
+// ********************************************************\r
+//\r
+typedef struct {\r
+  EFI_HII_HANDLE  HiiHandle;\r
+  EFI_GUID        PackageGuid;\r
+  UINT32          DataTableSize;\r
+  UINT32          IfrDataOffset;\r
+  UINT32          StringDataOffset;\r
+  UINT32          VariableDataOffset;\r
+  UINT32          DevicePathOffset;\r
+  UINT32          NumberOfVariableData;\r
+  UINT32          NumberOfLanguages;\r
+  //\r
+  // EFI_HII_DEVICE_PATH_PACK DevicePath[];\r
+  // EFI_HII_VARIABLE_PACK VariableData[];\r
+  // EFI_HII_IFR_PACK IfrData;\r
+  // EFI_HII_STRING_PACK StringData[];\r
+  //\r
+} EFI_HII_DATA_TABLE;\r
+\r
+//\r
+// ********************************************************\r
+// EFI_HII_EXPORT_TABLE\r
+// ********************************************************\r
+//\r
+typedef struct {\r
+  UINT32    NumberOfHiiDataTables;\r
+  EFI_GUID  Revision;\r
+  //\r
+  // EFI_HII_DATA_TABLE HiiDataTable[];\r
+  //\r
+} EFI_HII_EXPORT_TABLE;\r
+\r
+typedef struct {\r
+  BOOLEAN               FormSetUpdate;      // If TRUE, next variable is significant\r
+  EFI_PHYSICAL_ADDRESS  FormCallbackHandle; // If not 0, will update Formset with this info\r
+  BOOLEAN               FormUpdate;         // If TRUE, next variable is significant\r
+  UINT16                FormValue;          // specify which form is to be updated if FormUpdate value is TRUE.\r
+  STRING_REF            FormTitle;          // If not 0, will update Form with this info\r
+  UINT16                DataCount;          // The number of Data entries in this structure\r
+  UINT8                 *Data;              // An array of 1+ op-codes, specified by DataCount\r
+} EFI_HII_UPDATE_DATA;\r
+\r
+//\r
+// String attributes\r
+//\r
+#define LANG_RIGHT_TO_LEFT  0x00000001\r
+\r
+//\r
+// A string package is used to localize strings to a particular\r
+// language.  The package is associated with a particular driver\r
+// or set of drivers.  Tools are used to associate tokens with\r
+// string references in forms and in programs.  These tokens are\r
+// language agnostic.  When paired with a language pack (directly\r
+// or indirectly), the string token resolves into an actual\r
+// UNICODE string.  The NumStringPointers determines how many\r
+// StringPointers (offset values) there are as well as the total\r
+// number of Strings that are defined.\r
+//\r
+typedef struct {\r
+  EFI_HII_PACK_HEADER Header;\r
+  RELOFST             LanguageNameString;\r
+  RELOFST             PrintableLanguageName;\r
+  UINT32              NumStringPointers;\r
+  UINT32              Attributes;\r
+  //\r
+  //  RELOFST               StringPointers[];\r
+  //  EFI_STRING            Strings[];\r
+  //\r
+} EFI_HII_STRING_PACK;\r
+\r
+//\r
+// Glyph Attributes\r
+//\r
+#define EFI_GLYPH_NON_SPACING   1\r
+#define EFI_GLYPH_WIDE          2\r
+\r
+typedef struct {\r
+  CHAR16  UnicodeWeight;\r
+  UINT8   Attributes;\r
+  UINT8   GlyphCol1[GLYPH_HEIGHT];\r
+} EFI_NARROW_GLYPH;\r
+\r
+typedef struct {\r
+  CHAR16  UnicodeWeight;\r
+  UINT8   Attributes;\r
+  UINT8   GlyphCol1[GLYPH_HEIGHT];\r
+  UINT8   GlyphCol2[GLYPH_HEIGHT];\r
+  UINT8   Pad[3];\r
+} EFI_WIDE_GLYPH;\r
+\r
+//\r
+// A font list consists of a font header followed by a series\r
+// of glyph structures.  Note that fonts are not language specific.\r
+//\r
+typedef struct {\r
+  EFI_HII_PACK_HEADER Header;\r
+  UINT16              NumberOfNarrowGlyphs;\r
+  UINT16              NumberOfWideGlyphs;\r
+} EFI_HII_FONT_PACK;\r
+\r
+//\r
+// The IfrData in the EFI_HII_IFR_PACK structure definition\r
+// is variable length, and not really part of the header. To\r
+// simplify from code the size of the header, define an\r
+// identical structure that does not include the IfrData field.\r
+// Then use sizeof() this new structure to determine the\r
+// actual size of the header.\r
+//\r
+typedef struct {\r
+  EFI_HII_PACK_HEADER Header;\r
+} EFI_HII_IFR_PACK_HEADER;\r
+\r
+//\r
+// pedef EFI_HII_PACK_HEADER EFI_HII_IFR_PACK_HEADER;\r
+//\r
+typedef enum {\r
+  EfiKeyLCtrl,\r
+  EfiKeyA0,\r
+  EfiKeyLAlt,\r
+  EfiKeySpaceBar,\r
+  EfiKeyA2,\r
+  EfiKeyA3,\r
+  EfiKeyA4,\r
+  EfiKeyRCtrl,\r
+  EfiKeyLeftArrow,\r
+  EfiKeyDownArrow,\r
+  EfiKeyRightArrow,\r
+  EfiKeyZero,\r
+  EfiKeyPeriod,\r
+  EfiKeyEnter,\r
+  EfiKeyLShift,\r
+  EfiKeyB0,\r
+  EfiKeyB1,\r
+  EfiKeyB2,\r
+  EfiKeyB3,\r
+  EfiKeyB4,\r
+  EfiKeyB5,\r
+  EfiKeyB6,\r
+  EfiKeyB7,\r
+  EfiKeyB8,\r
+  EfiKeyB9,\r
+  EfiKeyB10,\r
+  EfiKeyRshift,\r
+  EfiKeyUpArrow,\r
+  EfiKeyOne,\r
+  EfiKeyTwo,\r
+  EfiKeyThree,\r
+  EfiKeyCapsLock,\r
+  EfiKeyC1,\r
+  EfiKeyC2,\r
+  EfiKeyC3,\r
+  EfiKeyC4,\r
+  EfiKeyC5,\r
+  EfiKeyC6,\r
+  EfiKeyC7,\r
+  EfiKeyC8,\r
+  EfiKeyC9,\r
+  EfiKeyC10,\r
+  EfiKeyC11,\r
+  EfiKeyC12,\r
+  EfiKeyFour,\r
+  EfiKeyFive,\r
+  EfiKeySix,\r
+  EfiKeyPlus,\r
+  EfiKeyTab,\r
+  EfiKeyD1,\r
+  EfiKeyD2,\r
+  EfiKeyD3,\r
+  EfiKeyD4,\r
+  EfiKeyD5,\r
+  EfiKeyD6,\r
+  EfiKeyD7,\r
+  EfiKeyD8,\r
+  EfiKeyD9,\r
+  EfiKeyD10,\r
+  EfiKeyD11,\r
+  EfiKeyD12,\r
+  EfiKeyD13,\r
+  EfiKeyDel,\r
+  EfiKeyEnd,\r
+  EfiKeyPgDn,\r
+  EfiKeySeven,\r
+  EfiKeyEight,\r
+  EfiKeyNine,\r
+  EfiKeyE0,\r
+  EfiKeyE1,\r
+  EfiKeyE2,\r
+  EfiKeyE3,\r
+  EfiKeyE4,\r
+  EfiKeyE5,\r
+  EfiKeyE6,\r
+  EfiKeyE7,\r
+  EfiKeyE8,\r
+  EfiKeyE9,\r
+  EfiKeyE10,\r
+  EfiKeyE11,\r
+  EfiKeyE12,\r
+  EfiKeyBackSpace,\r
+  EfiKeyIns,\r
+  EfiKeyHome,\r
+  EfiKeyPgUp,\r
+  EfiKeyNLck,\r
+  EfiKeySlash,\r
+  EfiKeyAsterisk,\r
+  EfiKeyMinus,\r
+  EfiKeyEsc,\r
+  EfiKeyF1,\r
+  EfiKeyF2,\r
+  EfiKeyF3,\r
+  EfiKeyF4,\r
+  EfiKeyF5,\r
+  EfiKeyF6,\r
+  EfiKeyF7,\r
+  EfiKeyF8,\r
+  EfiKeyF9,\r
+  EfiKeyF10,\r
+  EfiKeyF11,\r
+  EfiKeyF12,\r
+  EfiKeyPrint,\r
+  EfiKeySLck,\r
+  EfiKeyPause\r
+} EFI_KEY;\r
+\r
+typedef struct {\r
+  EFI_KEY Key;\r
+  CHAR16  Unicode;\r
+  CHAR16  ShiftedUnicode;\r
+  CHAR16  AltGrUnicode;\r
+  CHAR16  ShiftedAltGrUnicode;\r
+  UINT16  Modifier;\r
+} EFI_KEY_DESCRIPTOR;\r
+\r
+//\r
+// This structure allows a sparse set of keys to be redefined\r
+// or a complete redefinition of the keyboard layout.  Most\r
+// keyboards have a lot of commonality in their layouts, therefore\r
+// only defining those keys that need to change from the default\r
+// minimizes the passed in information.\r
+//\r
+// Additionally, when an update occurs, the active keyboard layout\r
+// will be switched to the newly updated keyboard layout.  This\r
+// allows for situations that when a keyboard layout driver is\r
+// loaded as part of system initialization, the system will default\r
+// the keyboard behavior to the new layout.\r
+//\r
+// Each call to update the keyboard mapping should contain the\r
+// complete set of key descriptors to be updated, since every\r
+// call to the HII which contains an EFI_HII_KEYBOARD_PACK will\r
+// wipe the previous set of overrides.  A call to\r
+//\r
+typedef struct {\r
+  EFI_HII_PACK_HEADER Header;\r
+  EFI_KEY_DESCRIPTOR  *Descriptor;\r
+  UINT8               DescriptorCount;\r
+} EFI_HII_KEYBOARD_PACK;\r
+\r
+//\r
+// The EFI_HII_PACKAGES can contain different types of packages just\r
+// after the structure as inline data.\r
+//\r
+typedef struct {\r
+  UINTN     NumberOfPackages;\r
+  EFI_GUID  *GuidId;\r
+  //\r
+  // EFI_HII_HANDLE_PACK    *HandlePack;        // Only one pack.\r
+  // EFI_HII_IFR_PACK       *IfrPack;           // Only one pack.\r
+  // EFI_HII_FONT_PACK      *FontPack[];        // Multiple packs ok\r
+  // EFI_HII_STRING_PACK    *StringPack[];      // Multiple packs ok\r
+  // EFI_HII_KEYBOARD_PACK  *KeyboardPack[];    // Multiple packs ok\r
+  //\r
+} EFI_HII_PACKAGES;\r
+\r
+typedef struct _EFI_HII_VARIABLE_PACK_LIST {\r
+  struct _EFI_HII_VARIABLE_PACK_LIST   *NextVariablePack;\r
+  EFI_HII_VARIABLE_PACK                *VariablePack;\r
+} EFI_HII_VARIABLE_PACK_LIST;\r
+\r
+#pragma pack()\r
+\r
+/**\r
+  Registers the various packs that are passed in via the Packages parameter.\r
+\r
+  @param  This                  A pointer to the EFI_HII_PROTOCOL instance.\r
+  @param  Packages              A pointer to an EFI_HII_PACKAGES package instance.\r
+  @param  Handle                A pointer to the EFI_HII_HANDLE instance.\r
+\r
+  @retval EFI_SUCCESS           Data was extracted from Packages, the database\r
+                                was updated with the data, and Handle returned successfully.\r
+  @retval EFI_INVALID_PARAMETER The content of Packages was invalid.\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_HII_NEW_PACK) (\r
+  IN  EFI_HII_PROTOCOL    *This,\r
+  IN  EFI_HII_PACKAGES    *Packages,\r
+  OUT EFI_HII_HANDLE      *Handle\r
+  );\r
+\r
+/**\r
+  Removes a package from the HII database.\r
+\r
+  @param  This                  A pointer to the EFI_HII_PROTOCOL instance.\r
+  @param  Handle                The handle that was registered to the data that is requested\r
+                                for removal.\r
+\r
+  @retval EFI_SUCCESS           The data associated with the Handle was removed\r
+                                from the HII database.\r
+  @retval EFI_INVALID_PARAMETER The Handle was not valid.\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_HII_REMOVE_PACK) (\r
+  IN EFI_HII_PROTOCOL    *This,\r
+  IN EFI_HII_HANDLE      Handle\r
+  );\r
+\r
+/**\r
+  Determines the handles that are currently active in the database.\r
+\r
+  @param  This                  A pointer to the EFI_HII_PROTOCOL instance.\r
+  @param  HandleBufferLength    On input, a pointer to the length of the handle\r
+                                buffer. On output, the length of the handle buffer that is required\r
+                                for the handles found.\r
+  @param  Handle                An array of EFI_HII_HANDLE instances returned.\r
+\r
+  @retval EFI_SUCCESS           Handle was updated successfully.\r
+  @retval EFI_BUFFER_TOO_SMALL  The HandleBufferLength parameter indicates\r
+                                that Handle is too small to support the number of handles.\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_HII_FIND_HANDLES) (\r
+  IN     EFI_HII_PROTOCOL *This,\r
+  IN OUT UINT16           *HandleBufferLength,\r
+  OUT    EFI_HII_HANDLE   *Handle\r
+  );\r
+\r
+/**\r
+  Exports the contents of the database into a buffer.\r
+\r
+  @param  This                  A pointer to the EFI_HII_PROTOCOL instance.\r
+  @param  Handle                An EFI_HII_HANDLE that corresponds to the desired\r
+                                handle to export. If the value is 0, the entire database will be exported.\r
+                                In either case, the data will be exported in a format described by the\r
+                                structure definition of EFI_HII_EXPORT_TABLE.\r
+  @param  BufferSize\r
+  On input, a pointer to the length of the buffer. On output, the length\r
+  of the buffer that is required for the export data.\r
+  @param  Buffer                A pointer to a buffer that will contain the results of the export function.\r
+\r
+  @retval EFI_SUCCESS           The buffer was successfully filled with BufferSize amount of data.\r
+  @retval EFI_BUFFER_TOO_SMALL  The value in BufferSize was too small to contain the export data.\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_HII_EXPORT) (\r
+  IN     EFI_HII_PROTOCOL *This,\r
+  IN     EFI_HII_HANDLE   Handle,\r
+  IN OUT UINTN            *BufferSize,\r
+  OUT    VOID             *Buffer\r
+  );\r
+\r
+/**\r
+  Remove any new strings that were added after the initial string export\r
+  for this handle.\r
+\r
+  @param  This                  A pointer to the EFI_HII_PROTOCOL instance.\r
+  @param  Handle                The handle on which the string resides.\r
+\r
+  @retval EFI_SUCCESS           Remove strings from the handle successfully.\r
+  @retval EFI_INVALID_PARAMETER The Handle was unknown.\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_HII_RESET_STRINGS) (\r
+  IN     EFI_HII_PROTOCOL   *This,\r
+  IN     EFI_HII_HANDLE     Handle\r
+  );\r
+\r
+/**\r
+  Tests if all of the characters in a string have corresponding font characters.\r
+\r
+  @param  This                  A pointer to the EFI_HII_PROTOCOL instance.\r
+  @param  StringToTest          A pointer to a Unicode string.\r
+  @param  FirstMissing          A pointer to an index into the string. On input,\r
+                                the index of the first character in the StringToTest to examine. On exit,\r
+                                the index of the first character encountered for which a glyph is unavailable.\r
+                                If all glyphs in the string are available, the index is the index of the\r
+                                terminator of the string.\r
+  @param  GlyphBufferSize       A pointer to a value. On output, if the function\r
+                                returns EFI_SUCCESS, it contains the amount of memory that is required to\r
+                                store the string's glyph equivalent.\r
+\r
+  @retval EFI_SUCCESS           All glyphs are available. Note that an empty string\r
+                                always returns this value.\r
+  @retval EFI_NOT_FOUND         A glyph was not found for a character.\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_HII_TEST_STRING) (\r
+  IN     EFI_HII_PROTOCOL  *This,\r
+  IN     CHAR16            *StringToTest,\r
+  IN OUT UINT32            *FirstMissing,\r
+  OUT    UINT32            *GlyphBufferSize\r
+  );\r
+\r
+/**\r
+  Translates a Unicode character into the corresponding font glyph.\r
+\r
+  @param  This                  A pointer to the EFI_HII_PROTOCOL instance.\r
+  @param  Source                A pointer to a Unicode string.\r
+  @param  Index                 On input, the offset into the string from which to fetch\r
+                                the character.On successful completion, the index is updated to the first\r
+                                character past the character(s) making up the just extracted glyph.\r
+  @param  GlyphBuffer           Pointer to an array where the glyphs corresponding\r
+                                to the characters in the source may be stored. GlyphBuffer is assumed\r
+                                to be wide enough to accept a wide glyph character.\r
+  @param  BitWidth              If EFI_SUCCESS was returned, the UINT16 pointed to by\r
+                                this value is filled with the length of the glyph in pixels. It is unchanged\r
+                                if the call was unsuccessful.\r
+  @param  InternalStatus        The cell pointed to by this parameter must be\r
+                                initialized to zero prior to invoking the call the first time for any string.\r
+\r
+  @retval EFI_SUCCESS           It worked.\r
+  @retval EFI_NOT_FOUND         A glyph for a character was not found.\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_HII_GET_GLYPH) (\r
+  IN     EFI_HII_PROTOCOL  *This,\r
+  IN     CHAR16            *Source,\r
+  IN OUT UINT16            *Index,\r
+  OUT    UINT8             **GlyphBuffer,\r
+  OUT    UINT16            *BitWidth,\r
+  IN OUT UINT32            *InternalStatus\r
+  );\r
+\r
+/**\r
+  Translates a glyph into the format required for input to the Universal\r
+  Graphics Adapter (UGA) Block Transfer (BLT) routines.\r
+\r
+  @param  This                  A pointer to the EFI_HII_PROTOCOL instance.\r
+  @param  GlyphBuffer           A pointer to the buffer that contains glyph data.\r
+  @param  Foreground            The foreground setting requested to be used for the\r
+                                generated BltBuffer data.\r
+  @param  Background            The background setting requested to be used for the\r
+                                generated BltBuffer data.\r
+  @param  Count                 The entry in the BltBuffer upon which to act.\r
+  @param  Width                 The width in bits of the glyph being converted.\r
+  @param  Height                The height in bits of the glyph being converted\r
+  @param  BltBuffer             A pointer to the buffer that contains the data that is\r
+                                ready to be used by the UGA BLT routines.\r
+\r
+  @retval EFI_SUCCESS           It worked.\r
+  @retval EFI_NOT_FOUND         A glyph for a character was not found.\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_HII_GLYPH_TO_BLT) (\r
+  IN     EFI_HII_PROTOCOL             *This,\r
+  IN     UINT8                        *GlyphBuffer,\r
+  IN     EFI_GRAPHICS_OUTPUT_BLT_PIXEL Foreground,\r
+  IN     EFI_GRAPHICS_OUTPUT_BLT_PIXEL Background,\r
+  IN     UINTN                         Count,\r
+  IN     UINTN                         Width,\r
+  IN     UINTN                         Height,\r
+  IN OUT EFI_GRAPHICS_OUTPUT_BLT_PIXEL *BltBuffer\r
+  );\r
+\r
+/**\r
+  Allows a new string to be added to an already existing string package.\r
+\r
+  @param  This                  A pointer to the EFI_HII_PROTOCOL instance.\r
+  @param  Pointer               to a NULL-terminated string containing a single ISO 639-2\r
+                                language identifier, indicating the language in which the string is translated.\r
+  @param  Handle                The handle of the language pack to which the string is to be added.\r
+  @param  Reference             The identifier of the string to be added. If the reference\r
+                                value is zero, then the string will be assigned a new identifier on that\r
+                                handle for the language specified. Otherwise, the string will be updated\r
+                                with the NewString Value.\r
+  @param  NewString             The string to be added.\r
+\r
+  @retval EFI_SUCCESS           The string was effectively registered.\r
+  @retval EFI_INVALID_PARAMETER The Handle was unknown.\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_HII_NEW_STRING) (\r
+  IN     EFI_HII_PROTOCOL      *This,\r
+  IN     CHAR16                *Language,\r
+  IN     EFI_HII_HANDLE        Handle,\r
+  IN OUT STRING_REF            *Reference,\r
+  IN     CHAR16                *NewString\r
+  );\r
+\r
+/**\r
+  Allows a program to determine the primary languages that are supported\r
+  on a given handle.\r
+\r
+  @param  This                  A pointer to the EFI_HII_PROTOCOL instance.\r
+  @param  Handle                The handle on which the strings reside.\r
+  @param  LanguageString        A string allocated by GetPrimaryLanguages() that\r
+                                contains a list of all primary languages registered on the handle.\r
+\r
+  @retval EFI_SUCCESS           LanguageString was correctly returned.\r
+  @retval EFI_INVALID_PARAMETER The Handle was unknown.\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_HII_GET_PRI_LANGUAGES) (\r
+  IN  EFI_HII_PROTOCOL    *This,\r
+  IN  EFI_HII_HANDLE      Handle,\r
+  OUT EFI_STRING          *LanguageString\r
+  );\r
+\r
+/**\r
+  Allows a program to determine which secondary languages are supported\r
+  on a given handle for a given primary language.\r
+\r
+  @param  This                  A pointer to the EFI_HII_PROTOCOL instance.\r
+  @param  Handle                The handle on which the strings reside.\r
+  @param  PrimaryLanguage       Pointer to a NULL-terminated string containing a single\r
+                                ISO 639-2 language identifier, indicating the primary language.\r
+  @param  LanguageString        A string allocated by GetSecondaryLanguages()\r
+                                containing a list of all secondary languages registered on the handle.\r
+\r
+  @retval EFI_SUCCESS           LanguageString was correctly returned.\r
+  @retval EFI_INVALID_PARAMETER The Handle was unknown.\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_HII_GET_SEC_LANGUAGES) (\r
+  IN  EFI_HII_PROTOCOL    *This,\r
+  IN  EFI_HII_HANDLE      Handle,\r
+  IN  CHAR16              *PrimaryLanguage,\r
+  OUT EFI_STRING          *LanguageString\r
+  );\r
+\r
+/**\r
+  Extracts a string from a package already registered with the EFI HII database.\r
+\r
+  @param  This                  A pointer to the EFI_HII_PROTOCOL instance.\r
+  @param  Handle                The handle on which the string resides.\r
+  @param  Token                 The string token assigned to the string.\r
+  @param  Raw                   If TRUE, the string is returned unedited in the internal\r
+                                storage format described above. If false, the string returned is edited\r
+                                by replacing <cr> with <space> and by removing special characters such\r
+                                as the <wide> prefix.\r
+  @param  LanguageString        Pointer to a NULL-terminated string containing a\r
+                                single ISO 639-2 language identifier, indicating the language to print.\r
+                                If the LanguageString is empty (starts with a NULL), the default system\r
+                                language will be used to determine the language.\r
+  @param  BufferLength          Length of the StringBuffer.\r
+  @param  StringBuffer          The buffer designed to receive the characters in the string.\r
+\r
+  @retval EFI_SUCCESS           StringBuffer is filled with a NULL-terminated string.\r
+  @retval EFI_INVALID_PARAMETER The handle or string token is unknown.\r
+  @retval EFI_BUFFER_TOO_SMALL  The buffer provided was not large enough to\r
+                                allow the entire string to be stored.\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_HII_GET_STRING) (\r
+  IN     EFI_HII_PROTOCOL  *This,\r
+  IN     EFI_HII_HANDLE    Handle,\r
+  IN     STRING_REF        Token,\r
+  IN     BOOLEAN           Raw,\r
+  IN     CHAR16            *LanguageString,\r
+  IN OUT UINTN             *BufferLength,\r
+  OUT    EFI_STRING        StringBuffer\r
+  );\r
+\r
+/**\r
+  Allows a program to extract a part of a string of not more than a given width.\r
+\r
+  @param  This                  A pointer to the EFI_HII_PROTOCOL instance.\r
+  @param  Handle                The handle on which the string resides.\r
+  @param  Token                 The string token assigned to the string.\r
+  @param  Index                 On input, the offset into the string where the line is to start.\r
+                                On output, the index is updated to point to beyond the last character returned\r
+                                in the call.\r
+  @param  LineWidth             The maximum width of the line in units of narrow glyphs.\r
+  @param  LanguageString        Pointer to a NULL-terminated string containing a\r
+                                single ISO 639-2 language identifier, indicating the language to print.\r
+  @param  BufferLength          Pointer to the length of the StringBuffer.\r
+  @param  StringBuffer          The buffer designed to receive the characters in the string.\r
+\r
+  @retval EFI_SUCCESS           StringBuffer filled with characters that will fit on the line.\r
+  @retval EFI_NOT_FOUND         The font glyph for at least one of the characters in\r
+                                the string is not in the font database.\r
+  @retval EFI_BUFFER_TOO_SMALL  The buffer provided was not large enough\r
+                                to allow the entire string to be stored.\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_HII_GET_LINE) (\r
+  IN     EFI_HII_PROTOCOL  *This,\r
+  IN     EFI_HII_HANDLE    Handle,\r
+  IN     STRING_REF        Token,\r
+  IN OUT UINT16            *Index,\r
+  IN     UINT16            LineWidth,\r
+  IN     CHAR16            *LanguageString,\r
+  IN OUT UINT16            *BufferLength,\r
+  OUT    EFI_STRING        StringBuffer\r
+  );\r
+\r
+/**\r
+  Allows a program to extract a form or form package that has previously\r
+  been registered with the HII database.\r
+\r
+  @param  This                  A pointer to the EFI_HII_PROTOCOL instance.\r
+  @param  Handle                Handle on which the form resides.\r
+  @param  FormId                The ID of the form to return. If the ID is zero,\r
+                                the entire form package is returned.\r
+  @param  BufferLength          On input, the length of the Buffer. On output,\r
+                                the length of the returned buffer,\r
+  @param  Buffer                The buffer designed to receive the form(s).\r
+\r
+  @retval EFI_SUCCESS           Buffer filled with the requested forms. BufferLength\r
+                                was updated.\r
+  @retval EFI_INVALID_PARAMETER The handle is unknown.\r
+  @retval EFI_NOT_FOUND         A form on the requested handle cannot be found with\r
+                                the requested FormId.\r
+  @retval EFI_BUFFER_TOO_SMALL  The buffer provided was not large enough\r
+                                to allow the form to be stored.\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_HII_GET_FORMS) (\r
+  IN     EFI_HII_PROTOCOL  *This,\r
+  IN     EFI_HII_HANDLE    Handle,\r
+  IN     EFI_FORM_ID       FormId,\r
+  IN OUT UINTN             *BufferLength,\r
+  OUT    UINT8             *Buffer\r
+  );\r
+\r
+/**\r
+  Extracts the defaults that are associated with a given handle in the HII database.\r
+\r
+  @param  This                  A pointer to the EFI_HII_PROTOCOL instance.\r
+  @param  Handle                The HII handle from which will have default data retrieved.\r
+  @param  DefaultMask           The mask used to specify some type of default override when extracting\r
+                                the default image data.\r
+  @param  VariablePackList      A indirect pointer to the first entry of a link list with\r
+                                type EFI_HII_VARIABLE_PACK_LIST.\r
+\r
+  @retval EFI_SUCCESS           The VariablePackList was populated with the appropriate\r
+                                default setting data.\r
+  @retval EFI_NOT_FOUND         The IFR does not have any explicit or default map(s).\r
+  @retval EFI_INVALID_PARAMETER The HII database entry associated with Handle\r
+                                contain invalid data.\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_HII_GET_DEFAULT_IMAGE) (\r
+  IN     EFI_HII_PROTOCOL           *This,\r
+  IN     EFI_HII_HANDLE             Handle,\r
+  IN     UINTN                      DefaultMask,\r
+  OUT    EFI_HII_VARIABLE_PACK_LIST **VariablePackList\r
+  );\r
+\r
+/**\r
+  Allows the caller to update a form or form package that has previously been\r
+  registered with the EFI HII database.\r
+\r
+  @param  This                  A pointer to the EFI_HII_PROTOCOL instance.\r
+  @param  Handle                Handle of the package where the form to be updated resides.\r
+  @param  Label                 The label inside the form package where the update is to take place.\r
+  @param  AddData               If TRUE, adding data at a given Label; otherwise,\r
+                                if FALSE, removing data at a given Label.\r
+  @param  Data                  The buffer containing the new tags to insert after the Label\r
+\r
+  @retval EFI_SUCCESS           The form was updated with the new tags.\r
+  @retval EFI_INVALID_PARAMETER The buffer for the buffer length does not\r
+                                contain an integral number of tags.\r
+  @retval EFI_NOT_FOUND         The Handle, Label, or FormId was not found.\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_HII_UPDATE_FORM) (\r
+  IN EFI_HII_PROTOCOL     *This,\r
+  IN EFI_HII_HANDLE       Handle,\r
+  IN EFI_FORM_LABEL       Label,\r
+  IN BOOLEAN              AddData,\r
+  IN EFI_HII_UPDATE_DATA  *Data\r
+  );\r
+\r
+/**\r
+  Retrieves the current keyboard layout.\r
+\r
+  @param  This                  A pointer to the EFI_HII_PROTOCOL instance.\r
+  @param  DescriptorCount       A pointer to the number of Descriptor entries being\r
+                                described in the keyboard layout being retrieved.\r
+  @param  Descriptor            A pointer to a buffer containing an array of EFI_KEY_DESCRIPTOR\r
+                                entries. Each entry will reflect the definition of a specific physical key.\r
+\r
+  @retval EFI_SUCCESS           The keyboard layout was retrieved successfully.\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_HII_GET_KEYBOARD_LAYOUT) (\r
+  IN     EFI_HII_PROTOCOL    *This,\r
+  OUT    UINT16              *DescriptorCount,\r
+  OUT    EFI_KEY_DESCRIPTOR  *Descriptor\r
+  );\r
+\r
+/**\r
+  @par Protocol Description:\r
+  The HII Protocol manages the HII database, which is a repository for data\r
+  having to do with fonts, strings, forms, keyboards, and other future human\r
+  interface items.\r
+\r
+  @param NewPack\r
+  Extracts the various packs from a package list.\r
+\r
+  @param RemovePack\r
+  Removes a package from the HII database.\r
+\r
+  @param FindHandles\r
+  Determines the handles that are currently active in the database.\r
+\r
+  @param ExportDatabase\r
+  Export the entire contents of the database to a buffer.\r
+\r
+  @param TestString\r
+  Tests if all of the characters in a string have corresponding font characters.\r
+\r
+  @param GetGlyph\r
+  Translates a Unicode character into the corresponding font glyph.\r
+\r
+  @param GlyphToBlt\r
+  Converts a glyph value into a format that is ready for a UGA BLT command.\r
+\r
+  @param NewString\r
+  Allows a new string to be added to an already existing string package.\r
+\r
+  @param GetPrimaryLanguages\r
+  Allows a program to determine the primary languages that are supported\r
+  on a given handle.\r
+\r
+  @param GetSecondaryLanguages\r
+  Allows a program to determine which secondary languages are supported\r
+  on a given handle for a given primary language.\r
+\r
+  @param GetString\r
+  Extracts a string from a package that is already registered with the\r
+  EFI HII database.\r
+\r
+  @param ResetString\r
+  Remove any new strings that were added after the initial string export\r
+  for this handle.\r
+\r
+  @param GetLine\r
+  Allows a program to extract a part of a string of not more than a given width.\r
+\r
+  @param GetForms\r
+  Allows a program to extract a form or form package that has been previously registered.\r
+\r
+  @param GetDefaultImage\r
+  Allows a program to extract the nonvolatile image that represents the default storage image.\r
+\r
+  @param UpdateForm\r
+  Allows a program to update a previously registered form.\r
+\r
+  @param GetKeyboardLayout\r
+  Allows a program to extract the current keyboard layout.\r
+\r
+**/\r
+struct _EFI_HII_PROTOCOL {\r
+  EFI_HII_NEW_PACK            NewPack;\r
+  EFI_HII_REMOVE_PACK         RemovePack;\r
+  EFI_HII_FIND_HANDLES        FindHandles;\r
+  EFI_HII_EXPORT              ExportDatabase;\r
+\r
+  EFI_HII_TEST_STRING         TestString;\r
+  EFI_HII_GET_GLYPH           GetGlyph;\r
+  EFI_HII_GLYPH_TO_BLT        GlyphToBlt;\r
+\r
+  EFI_HII_NEW_STRING          NewString;\r
+  EFI_HII_GET_PRI_LANGUAGES   GetPrimaryLanguages;\r
+  EFI_HII_GET_SEC_LANGUAGES   GetSecondaryLanguages;\r
+  EFI_HII_GET_STRING          GetString;\r
+  EFI_HII_RESET_STRINGS       ResetStrings;\r
+  EFI_HII_GET_LINE            GetLine;\r
+  EFI_HII_GET_FORMS           GetForms;\r
+  EFI_HII_GET_DEFAULT_IMAGE   GetDefaultImage;\r
+  EFI_HII_UPDATE_FORM         UpdateForm;\r
+\r
+  EFI_HII_GET_KEYBOARD_LAYOUT GetKeyboardLayout;\r
+};\r
+\r
+extern EFI_GUID gEfiHiiProtocolGuid;\r
+\r
+#endif\r
diff --git a/IntelFrameworkPkg/Include/Protocol/IdeControllerInit.h b/IntelFrameworkPkg/Include/Protocol/IdeControllerInit.h
new file mode 100644 (file)
index 0000000..1f8b515
--- /dev/null
@@ -0,0 +1,455 @@
+/** @file\r
+  This file declares EFI IDE Controller Init Protocol\r
+\r
+  Copyright (c) 2007, Intel Corporation\r
+  All rights reserved. This program and the accompanying materials\r
+  are licensed and made available under the terms and conditions of the BSD License\r
+  which accompanies this distribution.  The full text of the license may be found at\r
+  http://opensource.org/licenses/bsd-license.php\r
+\r
+  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
+  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
+\r
+  Module Name:  IdeControllerInit.h\r
+\r
+  @par Revision Reference:\r
+  This Protocol is defined in IDE Controller Initialization Protocol Specification\r
+  Version 0.9\r
+\r
+**/\r
+\r
+#ifndef _EFI_IDE_CONTROLLER_INIT_PROTOCOL_H_\r
+#define _EFI_IDE_CONTROLLER_INIT_PROTOCOL_H_\r
+\r
+//\r
+// Global ID for the EFI Platform IDE Protocol GUID\r
+//\r
+#define EFI_IDE_CONTROLLER_INIT_PROTOCOL_GUID \\r
+  { 0xa1e37052, 0x80d9, 0x4e65, {0xa3, 0x17, 0x3e, 0x9a, 0x55, 0xc4, 0x3e, 0xc9 } }\r
+\r
+//\r
+// Forward reference for pure ANSI compatability\r
+//\r
+typedef struct _EFI_IDE_CONTROLLER_INIT_PROTOCOL  EFI_IDE_CONTROLLER_INIT_PROTOCOL;\r
+\r
+//\r
+//////////////////////////////////////////////////////////////////////////////////////////\r
+// EFI_IDE_BUS_ENUMERATION_PHASE\r
+// EFI_IDE_CONTROLLER_ENUM_PHASE\r
+//\r
+typedef enum{\r
+  EfiIdeBeforeChannelEnumeration,\r
+  EfiIdeAfterChannelEnumeration,\r
+  EfiIdeBeforeChannelReset,\r
+  EfiIdeAfterChannelReset,\r
+  EfiIdeBusBeforeDevicePresenceDetection,\r
+  EfiIdeBusAfterDevicePresenceDetection,\r
+  EfiIdeResetMode,\r
+  EfiIdeBusPhaseMaximum\r
+} EFI_IDE_CONTROLLER_ENUM_PHASE;\r
+\r
+//\r
+//******************************************************\r
+// EFI_ATA_EXT_TRANSFER_PROTOCOL\r
+//******************************************************\r
+//\r
+// This extended mode describes the SATA physical protocol.\r
+// SATA physical layers can operate at different speeds.\r
+// These speeds are defined below. Various PATA protocols\r
+// and associated modes are not applicable to SATA devices.\r
+//\r
+\r
+typedef enum {\r
+  EfiAtaSataTransferProtocol\r
+} EFI_ATA_EXT_TRANSFER_PROTOCOL;\r
+\r
+#define  EFI_SATA_AUTO_SPEED  0\r
+#define  EFI_SATA_GEN1_SPEED  1\r
+#define  EFI_SATA_GEN2_SPEED  2\r
+\r
+//\r
+//*******************************************************\r
+// EFI_IDE_CABLE_TYPE\r
+//*******************************************************\r
+//\r
+typedef enum {\r
+  EfiIdeCableTypeUnknown,\r
+  EfiIdeCableType40pin,\r
+  EfiIdeCableType80Pin,\r
+  EfiIdeCableTypeSerial,\r
+  EfiIdeCableTypeMaximum\r
+} EFI_IDE_CABLE_TYPE;\r
+\r
+//\r
+//******************************************************\r
+// EFI_ATA_MODE\r
+//******************************************************\r
+//\r
+typedef struct {\r
+  BOOLEAN      Valid;\r
+  UINT32       Mode;\r
+} EFI_ATA_MODE;\r
+\r
+//\r
+//******************************************************\r
+// EFI_ATA_EXTENDED_MODE\r
+//******************************************************\r
+//\r
+typedef struct {\r
+  EFI_ATA_EXT_TRANSFER_PROTOCOL  TransferProtocol;\r
+  UINT32                         Mode;\r
+} EFI_ATA_EXTENDED_MODE;\r
+\r
+//\r
+//******************************************************\r
+// EFI_ATA_COLLECTIVE_MODE\r
+//******************************************************\r
+//\r
+typedef struct {\r
+  EFI_ATA_MODE           PioMode;\r
+  EFI_ATA_MODE           SingleWordDmaMode;\r
+  EFI_ATA_MODE           MultiWordDmaMode;\r
+  EFI_ATA_MODE           UdmaMode;\r
+  UINT32                 ExtModeCount;\r
+  EFI_ATA_EXTENDED_MODE  ExtMode[1];\r
+} EFI_ATA_COLLECTIVE_MODE;\r
+\r
+//\r
+//*******************************************************\r
+// EFI_ATA_IDENTIFY_DATA\r
+//*******************************************************\r
+//\r
+\r
+#pragma pack(1)\r
+\r
+typedef struct {\r
+  UINT16  config;             // General Configuration\r
+  UINT16  cylinders;          // Number of Cylinders\r
+  UINT16  reserved_2;\r
+  UINT16  heads;              //Number of logical heads\r
+  UINT16  vendor_data1;\r
+  UINT16  vendor_data2;\r
+  UINT16  sectors_per_track;\r
+  UINT16  vendor_specific_7_9[3];\r
+  CHAR8   SerialNo[20];       // ASCII\r
+  UINT16  vendor_specific_20_21[2];\r
+  UINT16  ecc_bytes_available;\r
+  CHAR8   FirmwareVer[8];     // ASCII\r
+  CHAR8   ModelName[40];      // ASCII\r
+  UINT16  multi_sector_cmd_max_sct_cnt;\r
+  UINT16  reserved_48;\r
+  UINT16  capabilities;\r
+  UINT16  reserved_50;\r
+  UINT16  pio_cycle_timing;\r
+  UINT16  reserved_52;\r
+  UINT16  field_validity;\r
+  UINT16  current_cylinders;\r
+  UINT16  current_heads;\r
+  UINT16  current_sectors;\r
+  UINT16  CurrentCapacityLsb;\r
+  UINT16  CurrentCapacityMsb;\r
+  UINT16  reserved_59;\r
+  UINT16  user_addressable_sectors_lo;\r
+  UINT16  user_addressable_sectors_hi;\r
+  UINT16  reserved_62;\r
+  UINT16  multi_word_dma_mode;\r
+  UINT16  advanced_pio_modes;\r
+  UINT16  min_multi_word_dma_cycle_time;\r
+  UINT16  rec_multi_word_dma_cycle_time;\r
+  UINT16  min_pio_cycle_time_without_flow_control;\r
+  UINT16  min_pio_cycle_time_with_flow_control;\r
+  UINT16  reserved_69_79[11];\r
+  UINT16  major_version_no;\r
+  UINT16  minor_version_no;\r
+  UINT16  command_set_supported_82; // word 82\r
+  UINT16  command_set_supported_83; // word 83\r
+  UINT16  command_set_feature_extn; // word 84\r
+  UINT16  command_set_feature_enb_85; // word 85\r
+  UINT16  command_set_feature_enb_86; // word 86\r
+  UINT16  command_set_feature_default; // word 87\r
+  UINT16  ultra_dma_mode; // word 88\r
+  UINT16  reserved_89_127[39];\r
+  UINT16  security_status;\r
+  UINT16  vendor_data_129_159[31];\r
+  UINT16  reserved_160_255[96];\r
+} EFI_ATA_IDENTIFY_DATA;\r
+\r
+#pragma pack()\r
+//\r
+//*******************************************************\r
+// EFI_ATAPI_IDENTIFY_DATA\r
+//*******************************************************\r
+//\r
+#pragma pack(1)\r
+typedef struct {\r
+    UINT16  config;             // General Configuration\r
+    UINT16  obsolete_1;\r
+    UINT16  specific_config;\r
+    UINT16  obsolete_3;\r
+    UINT16  retired_4_5[2];\r
+    UINT16  obsolete_6;\r
+    UINT16  cfa_reserved_7_8[2];\r
+    UINT16  retired_9;\r
+    CHAR8   SerialNo[20];       // ASCII\r
+    UINT16  retired_20_21[2];\r
+    UINT16  obsolete_22;\r
+    CHAR8   FirmwareVer[8];     // ASCII\r
+    CHAR8   ModelName[40];      // ASCII\r
+    UINT16  multi_sector_cmd_max_sct_cnt;\r
+    UINT16  reserved_48;\r
+    UINT16  capabilities_49;\r
+    UINT16  capabilities_50;\r
+    UINT16  obsolete_51_52[2];\r
+    UINT16  field_validity;\r
+    UINT16  obsolete_54_58[5];\r
+    UINT16  mutil_sector_setting;\r
+    UINT16  user_addressable_sectors_lo;\r
+    UINT16  user_addressable_sectors_hi;\r
+    UINT16  obsolete_62;\r
+    UINT16  multi_word_dma_mode;\r
+    UINT16  advanced_pio_modes;\r
+    UINT16  min_multi_word_dma_cycle_time;\r
+    UINT16  rec_multi_word_dma_cycle_time;\r
+    UINT16  min_pio_cycle_time_without_flow_control;\r
+    UINT16  min_pio_cycle_time_with_flow_control;\r
+    UINT16  reserved_69_74[6];\r
+    UINT16  queue_depth;\r
+    UINT16  reserved_76_79[4];\r
+    UINT16  major_version_no;\r
+    UINT16  minor_version_no;\r
+    UINT16  cmd_set_support_82;\r
+    UINT16  cmd_set_support_83;\r
+    UINT16  cmd_feature_support;\r
+    UINT16  cmd_feature_enable_85;\r
+    UINT16  cmd_feature_enable_86;\r
+    UINT16  cmd_feature_default;\r
+    UINT16  ultra_dma_select;\r
+    UINT16  time_required_for_sec_erase;\r
+    UINT16  time_required_for_enhanced_sec_erase;\r
+    UINT16  current_advanced_power_mgmt_value;\r
+    UINT16  master_pwd_revison_code;\r
+    UINT16  hardware_reset_result;\r
+    UINT16  current_auto_acoustic_mgmt_value;\r
+    UINT16  reserved_95_99[5];\r
+    UINT16  max_user_lba_for_48bit_addr[4];\r
+    UINT16  reserved_104_126[23];\r
+    UINT16  removable_media_status_notification_support;\r
+    UINT16  security_status;\r
+    UINT16  vendor_data_129_159[31];\r
+    UINT16  cfa_power_mode;\r
+    UINT16  cfa_reserved_161_175[15];\r
+    UINT16  current_media_serial_no[30];\r
+    UINT16  reserved_206_254[49];\r
+    UINT16  integrity_word;\r
+} EFI_ATAPI_IDENTIFY_DATA;\r
+\r
+#pragma pack()\r
+//\r
+//*******************************************************\r
+// EFI_IDENTIFY_DATA\r
+//*******************************************************\r
+//\r
+typedef union {\r
+  EFI_ATA_IDENTIFY_DATA       AtaData;\r
+  EFI_ATAPI_IDENTIFY_DATA     AtapiData;\r
+} EFI_IDENTIFY_DATA;\r
+\r
+#define   EFI_ATAPI_DEVICE_IDENTIFY_DATA  0x8000\r