summaryrefslogtreecommitdiffstats
path: root/Nt32Pkg/MiscSubClassPlatformDxe
diff options
context:
space:
mode:
authorqwang12 <qwang12@6f19259b-4bc3-4df7-8a09-765794883524>2007-06-27 06:46:00 +0000
committerqwang12 <qwang12@6f19259b-4bc3-4df7-8a09-765794883524>2007-06-27 06:46:00 +0000
commit8879d432afdfa0e4ae905857f177ddc24cb71f3b (patch)
tree7575e1badc413a3410665b0857a68687ef7a8953 /Nt32Pkg/MiscSubClassPlatformDxe
parent068eac814d7f1a391d28505289b640bcab675004 (diff)
downloadedk2-8879d432afdfa0e4ae905857f177ddc24cb71f3b.tar.gz
edk2-8879d432afdfa0e4ae905857f177ddc24cb71f3b.tar.bz2
edk2-8879d432afdfa0e4ae905857f177ddc24cb71f3b.zip
add in MiscSubClassPlatformDxe
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@2783 6f19259b-4bc3-4df7-8a09-765794883524
Diffstat (limited to 'Nt32Pkg/MiscSubClassPlatformDxe')
-rw-r--r--Nt32Pkg/MiscSubClassPlatformDxe/CommonHeader.h41
-rw-r--r--Nt32Pkg/MiscSubClassPlatformDxe/MiscBaseBoardManufacturer.unibin0 -> 3014 bytes
-rw-r--r--Nt32Pkg/MiscSubClassPlatformDxe/MiscBaseBoardManufacturerData.c62
-rw-r--r--Nt32Pkg/MiscSubClassPlatformDxe/MiscBiosVendor.unibin0 -> 2374 bytes
-rw-r--r--Nt32Pkg/MiscSubClassPlatformDxe/MiscBiosVendorData.c93
-rw-r--r--Nt32Pkg/MiscSubClassPlatformDxe/MiscBootInformationData.c38
-rw-r--r--Nt32Pkg/MiscSubClassPlatformDxe/MiscChassisManufacturer.unibin0 -> 2575 bytes
-rw-r--r--Nt32Pkg/MiscSubClassPlatformDxe/MiscChassisManufacturerData.c50
-rw-r--r--Nt32Pkg/MiscSubClassPlatformDxe/MiscDevicePath.h180
-rw-r--r--Nt32Pkg/MiscSubClassPlatformDxe/MiscNumberOfInstallableLanguagesData.c42
-rw-r--r--Nt32Pkg/MiscSubClassPlatformDxe/MiscOemString.unibin0 -> 2108 bytes
-rw-r--r--Nt32Pkg/MiscSubClassPlatformDxe/MiscOemStringData.c37
-rw-r--r--Nt32Pkg/MiscSubClassPlatformDxe/MiscPortInternalConnectorDesignator.unibin0 -> 9593 bytes
-rw-r--r--Nt32Pkg/MiscSubClassPlatformDxe/MiscPortInternalConnectorDesignatorData.c104
-rw-r--r--Nt32Pkg/MiscSubClassPlatformDxe/MiscPortInternalConnectorDesignatorFunction.c271
-rw-r--r--Nt32Pkg/MiscSubClassPlatformDxe/MiscResetCapabilitiesData.c47
-rw-r--r--Nt32Pkg/MiscSubClassPlatformDxe/MiscSubclassDriver.dxs31
-rw-r--r--Nt32Pkg/MiscSubClassPlatformDxe/MiscSubclassDriver.h109
-rw-r--r--Nt32Pkg/MiscSubClassPlatformDxe/MiscSubclassDriver.inf145
-rw-r--r--Nt32Pkg/MiscSubClassPlatformDxe/MiscSubclassDriver.msa128
-rw-r--r--Nt32Pkg/MiscSubClassPlatformDxe/MiscSubclassDriver.unibin0 -> 2902 bytes
-rw-r--r--Nt32Pkg/MiscSubClassPlatformDxe/MiscSubclassDriverDataTable.c104
-rw-r--r--Nt32Pkg/MiscSubClassPlatformDxe/MiscSubclassDriverEntryPoint.c523
-rw-r--r--Nt32Pkg/MiscSubClassPlatformDxe/MiscSystemLanguageString.unibin0 -> 2126 bytes
-rw-r--r--Nt32Pkg/MiscSubClassPlatformDxe/MiscSystemLanguageStringData.c38
-rw-r--r--Nt32Pkg/MiscSubClassPlatformDxe/MiscSystemManufacturer.unibin0 -> 2571 bytes
-rw-r--r--Nt32Pkg/MiscSubClassPlatformDxe/MiscSystemManufacturerData.c60
-rw-r--r--Nt32Pkg/MiscSubClassPlatformDxe/MiscSystemManufacturerFunction.c127
-rw-r--r--Nt32Pkg/MiscSubClassPlatformDxe/MiscSystemOptionString.unibin0 -> 2116 bytes
-rw-r--r--Nt32Pkg/MiscSubClassPlatformDxe/MiscSystemOptionStringData.c37
-rw-r--r--Nt32Pkg/MiscSubClassPlatformDxe/MiscSystemSlotDesignation.unibin0 -> 2143 bytes
-rw-r--r--Nt32Pkg/MiscSubClassPlatformDxe/MiscSystemSlotDesignationData.c57
32 files changed, 2324 insertions, 0 deletions
diff --git a/Nt32Pkg/MiscSubClassPlatformDxe/CommonHeader.h b/Nt32Pkg/MiscSubClassPlatformDxe/CommonHeader.h
new file mode 100644
index 0000000000..ed104f7ef2
--- /dev/null
+++ b/Nt32Pkg/MiscSubClassPlatformDxe/CommonHeader.h
@@ -0,0 +1,41 @@
+/**@file
+ Common header file shared by all source files.
+
+ This file includes package header files, library classes and protocol, PPI & GUID definitions.
+
+ Copyright (c) 2006 - 2007, Intel Corporation
+ All rights reserved. This program and the accompanying materials
+ are licensed and made available under the terms and conditions of the BSD License
+ which accompanies this distribution. The full text of the license may be found at
+ http://opensource.org/licenses/bsd-license.php
+ THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+**/
+
+#ifndef __COMMON_HEADER_H_
+#define __COMMON_HEADER_H_
+
+
+//
+// The package level header files this module uses
+//
+#include <PiDxe.h>
+#include <WinNtDxe.h>
+//
+// The protocols, PPI and GUID defintions for this module
+//
+//#include <Protocol/WinNtIo.h>
+//
+// The Library classes this module consumes
+//
+#include <Library/BaseLib.h>
+#include <Library/DebugLib.h>
+#include <Library/FrameworkHiiLib.h>
+#include <Library/UefiLib.h>
+#include <Library/UefiDriverEntryPoint.h>
+#include <Library/BaseMemoryLib.h>
+#include <Library/MemoryAllocationLib.h>
+#include <Library/UefiBootServicesTableLib.h>
+#include <Library/DevicePathLib.h>
+
+#endif
diff --git a/Nt32Pkg/MiscSubClassPlatformDxe/MiscBaseBoardManufacturer.uni b/Nt32Pkg/MiscSubClassPlatformDxe/MiscBaseBoardManufacturer.uni
new file mode 100644
index 0000000000..62280724a8
--- /dev/null
+++ b/Nt32Pkg/MiscSubClassPlatformDxe/MiscBaseBoardManufacturer.uni
Binary files differ
diff --git a/Nt32Pkg/MiscSubClassPlatformDxe/MiscBaseBoardManufacturerData.c b/Nt32Pkg/MiscSubClassPlatformDxe/MiscBaseBoardManufacturerData.c
new file mode 100644
index 0000000000..b7594f703a
--- /dev/null
+++ b/Nt32Pkg/MiscSubClassPlatformDxe/MiscBaseBoardManufacturerData.c
@@ -0,0 +1,62 @@
+/*++
+
+Copyright (c) 2006, Intel Corporation
+All rights reserved. This program and the accompanying materials
+are licensed and made available under the terms and conditions of the BSD License
+which accompanies this distribution. The full text of the license may be found at
+http://opensource.org/licenses/bsd-license.php
+
+THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+
+Module Name:
+
+ MiscBaseBoardManufacturerData.c
+
+Abstract:
+
+ This driver parses the mMiscSubclassDataTable structure and reports
+ any generated data to the DataHub.
+
+--*/
+
+//
+// Include common header file for this module.
+//
+#include "CommonHeader.h"
+
+#include "MiscSubclassDriver.h"
+
+//
+// Static (possibly build generated) Bios Vendor data.
+//
+MISC_SUBCLASS_TABLE_DATA(EFI_MISC_BASE_BOARD_MANUFACTURER_DATA, MiscBaseBoardManufacturer) = {
+ STRING_TOKEN(STR_MISC_BASE_BOARD_MANUFACTURER),
+ STRING_TOKEN(STR_MISC_BASE_BOARD_PRODUCT_NAME),
+ STRING_TOKEN(STR_MISC_BASE_BOARD_VERSION),
+ STRING_TOKEN(STR_MISC_BASE_BOARD_SERIAL_NUMBER),
+ STRING_TOKEN(STR_MISC_BASE_BOARD_ASSET_TAG),
+ STRING_TOKEN(STR_MISC_BASE_BOARD_CHASSIS_LOCATION),
+ { // BaseBoardFeatureFlags
+ 1, // Motherboard
+ 0, // RequiresDaughterCard
+ 0, // Removable
+ 1, // Replaceable,
+ 0, // HotSwappable
+ 0, // Reserved
+ },
+ EfiBaseBoardTypeUnknown, // BaseBoardType
+ { // BaseBoardChassisLink
+ EFI_MISC_SUBCLASS_GUID, // ProducerName
+ 1, // Instance
+ 1, // SubInstance
+ },
+ 0, // BaseBoardNumberLinks
+ { // LinkN
+ EFI_MISC_SUBCLASS_GUID, // ProducerName
+ 1, // Instance
+ 1, // SubInstance
+ },
+};
+
+/* eof - MiscBaseBoardManufacturerData.c */
diff --git a/Nt32Pkg/MiscSubClassPlatformDxe/MiscBiosVendor.uni b/Nt32Pkg/MiscSubClassPlatformDxe/MiscBiosVendor.uni
new file mode 100644
index 0000000000..ecade7465d
--- /dev/null
+++ b/Nt32Pkg/MiscSubClassPlatformDxe/MiscBiosVendor.uni
Binary files differ
diff --git a/Nt32Pkg/MiscSubClassPlatformDxe/MiscBiosVendorData.c b/Nt32Pkg/MiscSubClassPlatformDxe/MiscBiosVendorData.c
new file mode 100644
index 0000000000..f2363f3c66
--- /dev/null
+++ b/Nt32Pkg/MiscSubClassPlatformDxe/MiscBiosVendorData.c
@@ -0,0 +1,93 @@
+/*++
+
+Copyright (c) 2006, Intel Corporation
+All rights reserved. This program and the accompanying materials
+are licensed and made available under the terms and conditions of the BSD License
+which accompanies this distribution. The full text of the license may be found at
+http://opensource.org/licenses/bsd-license.php
+
+THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+
+Module Name:
+
+ MiscBiosVendorData.c
+
+Abstract:
+
+ This driver parses the mMiscSubclassDataTable structure and reports
+ any generated data to the DataHub.
+
+--*/
+
+//
+// Include common header file for this module.
+//
+#include "CommonHeader.h"
+
+#include "MiscSubclassDriver.h"
+
+//
+// Static (possibly build generated) Bios Vendor data.
+//
+MISC_SUBCLASS_TABLE_DATA(EFI_MISC_BIOS_VENDOR_DATA, MiscBiosVendor) = {
+ STRING_TOKEN(STR_MISC_BIOS_VENDOR), // BiosVendor
+ STRING_TOKEN(STR_MISC_BIOS_VERSION), // BiosVersion
+ STRING_TOKEN(STR_MISC_BIOS_RELEASE_DATE), // BiosReleaseDate
+ 0xBABE, // BiosStartingAddress
+ { // BiosPhysicalDeviceSize
+ 2, // Value
+ 3, // Exponent
+ },
+ { // BiosCharacteristics1
+ 0, // Reserved1 :2
+ 0, // Unknown :1
+ 1, // BiosCharacteristicsNotSupported :1
+ 0, // IsaIsSupported :1
+ 0, // McaIsSupported :1
+ 0, // EisaIsSupported :1
+ 0, // PciIsSupported :1
+ 0, // PcmciaIsSupported :1
+ 0, // PlugAndPlayIsSupported :1
+ 0, // ApmIsSupported :1
+ 0, // BiosIsUpgradable :1
+ 0, // BiosShadowingAllowed :1
+ 0, // VlVesaIsSupported :1
+ 0, // EscdSupportIsAvailable :1
+ 0, // BootFromCdIsSupported :1
+ 0, // SelectableBootIsSupported :1
+ 0, // RomBiosIsSocketed :1
+ 0, // BootFromPcmciaIsSupported :1
+ 0, // EDDSpecificationIsSupported :1
+ 0, // JapaneseNecFloppyIsSupported :1
+ 0, // JapaneseToshibaFloppyIsSupported :1
+ 0, // Floppy525_360IsSupported :1
+ 0, // Floppy525_12IsSupported :1
+ 0, // Floppy35_720IsSupported :1
+ 0, // Floppy35_288IsSupported :1
+ 0, // PrintScreenIsSupported :1
+ 0, // Keyboard8042IsSupported :1
+ 0, // SerialIsSupported :1
+ 0, // PrinterIsSupported :1
+ 0, // CgaMonoIsSupported :1
+ 0, // NecPc98 :1
+ 0, // AcpiIsSupported :1
+ 0, // UsbLegacyIsSupported :1
+ 0, // AgpIsSupported :1
+ 0, // I20BootIsSupported :1
+ 0, // Ls120BootIsSupported :1
+ 0, // AtapiZipDriveBootIsSupported :1
+ 0, // Boot1394IsSupported :1
+ 0, // SmartBatteryIsSupported :1
+ 0, // BiosBootSpecIsSupported :1
+ 0, // FunctionKeyNetworkBootIsSupported :1
+ 0 // Reserved :22
+ },
+ { // BiosCharacteristics2
+ 0, // BiosReserved :16
+ 0, // SystemReserved :16
+ 0 // Reserved :32
+ },
+};
+
+/* eof - MiscBiosVendorData.c */
diff --git a/Nt32Pkg/MiscSubClassPlatformDxe/MiscBootInformationData.c b/Nt32Pkg/MiscSubClassPlatformDxe/MiscBootInformationData.c
new file mode 100644
index 0000000000..8741468698
--- /dev/null
+++ b/Nt32Pkg/MiscSubClassPlatformDxe/MiscBootInformationData.c
@@ -0,0 +1,38 @@
+/*++
+
+Copyright (c) 2006, Intel Corporation
+All rights reserved. This program and the accompanying materials
+are licensed and made available under the terms and conditions of the BSD License
+which accompanies this distribution. The full text of the license may be found at
+http://opensource.org/licenses/bsd-license.php
+
+THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+
+Module Name:
+
+ MiscBootInformationData.c
+
+Abstract:
+
+ This driver parses the mMiscSubclassDataTable structure and reports
+ any generated data to the DataHub.
+
+--*/
+
+//
+// Include common header file for this module.
+//
+#include "CommonHeader.h"
+
+#include "MiscSubclassDriver.h"
+
+//
+// Static (possibly build generated) Bios Vendor data.
+//
+MISC_SUBCLASS_TABLE_DATA(EFI_MISC_BOOT_INFORMATION_STATUS_DATA, BootInformationStatus) = {
+ EfiBootInformationStatusNoError, // BootInformationStatus
+ 0 // BootInformationData
+};
+
+/* eof - MiscBootInformationData.c */
diff --git a/Nt32Pkg/MiscSubClassPlatformDxe/MiscChassisManufacturer.uni b/Nt32Pkg/MiscSubClassPlatformDxe/MiscChassisManufacturer.uni
new file mode 100644
index 0000000000..eac153a18b
--- /dev/null
+++ b/Nt32Pkg/MiscSubClassPlatformDxe/MiscChassisManufacturer.uni
Binary files differ
diff --git a/Nt32Pkg/MiscSubClassPlatformDxe/MiscChassisManufacturerData.c b/Nt32Pkg/MiscSubClassPlatformDxe/MiscChassisManufacturerData.c
new file mode 100644
index 0000000000..3e7d340780
--- /dev/null
+++ b/Nt32Pkg/MiscSubClassPlatformDxe/MiscChassisManufacturerData.c
@@ -0,0 +1,50 @@
+/*++
+
+Copyright (c) 2006, Intel Corporation
+All rights reserved. This program and the accompanying materials
+are licensed and made available under the terms and conditions of the BSD License
+which accompanies this distribution. The full text of the license may be found at
+http://opensource.org/licenses/bsd-license.php
+
+THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+
+Module Name:
+
+ MiscChassisManufacturerData.c
+
+Abstract:
+
+ This driver parses the mMiscSubclassDataTable structure and reports
+ any generated data to the DataHub.
+
+--*/
+
+//
+// Include common header file for this module.
+//
+#include "CommonHeader.h"
+
+#include "MiscSubclassDriver.h"
+
+//
+// Static (possibly build generated) Chassis Manufacturer data.
+//
+MISC_SUBCLASS_TABLE_DATA(EFI_MISC_CHASSIS_MANUFACTURER_DATA, MiscChassisManufacturer) = {
+ STRING_TOKEN(STR_MISC_CHASSIS_MANUFACTURER), // ChassisManufactrurer
+ STRING_TOKEN(STR_MISC_CHASSIS_VERSION), // ChassisVersion
+ STRING_TOKEN(STR_MISC_CHASSIS_SERIAL_NUMBER), // ChassisSerialNumber
+ STRING_TOKEN(STR_MISC_CHASSIS_ASSET_TAG), // ChassisAssetTag
+ { // ChassisTypeStatus
+ EfiMiscChassisTypeOther, // ChassisType
+ 0, // ChassisLockPresent
+ 0 // Reserved
+ },
+ EfiChassisStateOther, // ChassisBootupState
+ EfiChassisStateOther, // ChassisPowerSupplyState
+ EfiChassisStateOther, // ChassisThermalState
+ EfiChassisSecurityStatusOther, // ChassisSecurityState
+ 0 // ChassisOemDefined
+};
+
+/* eof - MiscChassisManufacaturerData.c */
diff --git a/Nt32Pkg/MiscSubClassPlatformDxe/MiscDevicePath.h b/Nt32Pkg/MiscSubClassPlatformDxe/MiscDevicePath.h
new file mode 100644
index 0000000000..3880aa49fb
--- /dev/null
+++ b/Nt32Pkg/MiscSubClassPlatformDxe/MiscDevicePath.h
@@ -0,0 +1,180 @@
+/*++
+
+Copyright (c) 2006, Intel Corporation
+All rights reserved. This program and the accompanying materials
+are licensed and made available under the terms and conditions of the BSD License
+which accompanies this distribution. The full text of the license may be found at
+http://opensource.org/licenses/bsd-license.php
+
+THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+
+Module Name:
+
+ MiscDevicePath.h
+
+Abstract:
+
+ Misc class required EFI Device Path definitions (Ports, slots &
+ onboard devices)
+
+--*/
+
+#ifndef _MISC_DEVICE_PATH_H
+#define _MISC_DEVICE_PATH_H
+
+
+//
+// Include common header file for this module.
+//
+#include "CommonHeader.h"
+
+#pragma pack(1)
+//
+// USB
+//
+
+/* For reference:
+#define USB1_1_STR "ACPI(PNP0A03,0)/PCI(1D,0)."
+#define USB1_2_STR "ACPI(PNP0A03,0)/PCI(1D,1)."
+#define USB1_3_STR "ACPI(PNP0A03,0)/PCI(1D,2)."
+#define USB2_1_STR "ACPI(PNP0A03,0)/PCI(1D,7)."
+*/
+
+//
+// #define acpi { 0x02, 0x01, 0x00, 0x0C, 0x0a0341d0, 0x00000000 }
+// #define pci( device,function) { 0x01, 0x01, 0x00, 0x06, device, function }
+// #define end { 0xFF, 0xFF, 0x00, 0x04 }
+//
+#define DP_ACPI \
+ { \
+ ACPI_DEVICE_PATH, ACPI_DP, (UINT8) (sizeof (ACPI_HID_DEVICE_PATH)), (UINT8) \
+ ((sizeof (ACPI_HID_DEVICE_PATH)) >> 8), EISA_PNP_ID (0x0A03), 0 \
+ }
+#define DP_PCI(device, function) \
+ { \
+ HARDWARE_DEVICE_PATH, HW_PCI_DP, (UINT8) (sizeof (PCI_DEVICE_PATH)), (UINT8) \
+ ((sizeof (PCI_DEVICE_PATH)) >> 8), function, device \
+ }
+#define DP_END \
+ { \
+ END_DEVICE_PATH_TYPE, END_ENTIRE_DEVICE_PATH_SUBTYPE, END_DEVICE_PATH_LENGTH, 0 \
+ }
+
+#define DP_LPC(eisaid, function) \
+ { \
+ ACPI_DEVICE_PATH, ACPI_DP, (UINT8) (sizeof (ACPI_HID_DEVICE_PATH)), (UINT8) \
+ ((sizeof (ACPI_HID_DEVICE_PATH)) >> 8), EISA_PNP_ID (eisaid), function \
+ }
+
+//
+// Shanmu >> moved to TianoDevicePath.h
+//
+
+/*
+typedef struct _USB_PORT_DEVICE_PATH
+{
+ ACPI_HID_DEVICE_PATH PciRootBridgeDevicePath;
+ PCI_DEVICE_PATH PciBusDevicePath;
+ EFI_DEVICE_PATH_PROTOCOL EndDevicePath;
+} USB_PORT_DEVICE_PATH;
+
+
+//IDE ??I am not sure. Should this be ATAPI_DEVICE_PATH
+typedef struct _IDE_DEVICE_PATH
+{
+ ACPI_HID_DEVICE_PATH PciRootBridgeDevicePath;
+ PCI_DEVICE_PATH PciBusDevicePath;
+ EFI_DEVICE_PATH_PROTOCOL EndDevicePath;
+} IDE_DEVICE_PATH;
+
+//RMC Connector
+typedef struct _RMC_CONN_DEVICE_PATH
+{
+ ACPI_HID_DEVICE_PATH PciRootBridgeDevicePath;
+ PCI_DEVICE_PATH PciBridgeDevicePath;
+ PCI_DEVICE_PATH PciBusDevicePath;
+ EFI_DEVICE_PATH_PROTOCOL EndDevicePath;
+} RMC_CONN_DEVICE_PATH;
+
+//static RMC_CONN_DEVICE_PATH mRmcConnDevicePath = { acpi, pci( 0x1E,0x00 ),pci( 0x0A,0x00 ), end };
+
+//RIDE
+typedef struct _RIDE_DEVICE_PATH
+{
+ ACPI_HID_DEVICE_PATH PciRootBridgeDevicePath;
+ PCI_DEVICE_PATH PciBridgeDevicePath;
+ PCI_DEVICE_PATH PciBusDevicePath;
+ EFI_DEVICE_PATH_PROTOCOL EndDevicePath;
+} RIDE_DEVICE_PATH;
+
+//static RIDE_DEVICE_PATH mRideDevicePath = { acpi, pci( 0x1E,0x00 ),pci( 0x02,0x00 ), end };
+
+//Gigabit NIC
+//typedef struct _GB_NIC_DEVICE_PATH
+//{
+// ACPI_HID_DEVICE_PATH PciRootBridgeDevicePath;
+// PCI_DEVICE_PATH PciBridgeDevicePath;
+// PCI_DEVICE_PATH PciXBridgeDevicePath;
+// PCI_DEVICE_PATH PciXBusDevicePath;
+// EFI_DEVICE_PATH_PROTOCOL EndDevicePath;
+//} GB_NIC_DEVICE_PATH;
+
+//static GB_NIC_DEVICE_PATH mGbNicDevicePath = { acpi, pci( 0x03,0x00 ),pci( 0x1F,0x00 ),pci( 0x07,0x00 ), end };
+
+
+//P/S2 Connector
+typedef struct _PS2_CONN_DEVICE_PATH
+{
+ ACPI_HID_DEVICE_PATH PciRootBridgeDevicePath;
+ PCI_DEVICE_PATH LpcBridgeDevicePath;
+ ACPI_HID_DEVICE_PATH LpcBusDevicePath;
+ EFI_DEVICE_PATH_PROTOCOL EndDevicePath;
+} PS2_CONN_DEVICE_PATH;
+
+//static PS2_CONN_DEVICE_PATH mPs2KeyboardDevicePath = { acpi, pci( 0x1F,0x00 ),lpc( 0x0303,0 ), end };
+//static PS2_CONN_DEVICE_PATH mPs2MouseDevicePath = { acpi, pci( 0x1F,0x00 ),lpc( 0x0303,1 ), end };
+
+//Serial Port Connector
+typedef struct _SERIAL_CONN_DEVICE_PATH
+{
+ ACPI_HID_DEVICE_PATH PciRootBridgeDevicePath;
+ PCI_DEVICE_PATH LpcBridgeDevicePath;
+ ACPI_HID_DEVICE_PATH LpcBusDevicePath;
+ EFI_DEVICE_PATH_PROTOCOL EndDevicePath;
+} SERIAL_CONN_DEVICE_PATH;
+
+//static SERIAL_CONN_DEVICE_PATH mCom1DevicePath = { acpi, pci( 0x1F,0x00 ),lpc( 0x0501,0 ), end };
+//static SERIAL_CONN_DEVICE_PATH mCom2DevicePath = { acpi, pci( 0x1F,0x00 ),lpc( 0x0501,1 ), end };
+
+//Parallel Port Connector
+typedef struct _PARALLEL_CONN_DEVICE_PATH
+{
+ ACPI_HID_DEVICE_PATH PciRootBridgeDevicePath;
+ PCI_DEVICE_PATH LpcBridgeDevicePath;
+ ACPI_HID_DEVICE_PATH LpcBusDevicePath;
+ EFI_DEVICE_PATH_PROTOCOL EndDevicePath;
+} PARALLEL_CONN_DEVICE_PATH;
+
+//static PARALLEL_CONN_DEVICE_PATH mLpt1DevicePath = { acpi, pci( 0x1F,0x00 ),lpc( 0x0401,0 ), end };
+
+//Floopy Connector
+typedef struct _FLOOPY_CONN_DEVICE_PATH
+{
+ ACPI_HID_DEVICE_PATH PciRootBridgeDevicePath;
+ PCI_DEVICE_PATH LpcBridgeDevicePath;
+ ACPI_HID_DEVICE_PATH LpcBusDevicePath;
+ EFI_DEVICE_PATH_PROTOCOL EndDevicePath;
+} FLOOPY_CONN_DEVICE_PATH;
+
+//static FLOOPY_CONN_DEVICE_PATH mFloopyADevicePath = { acpi, pci( 0x1F,0x00 ),lpc( 0x0604,0 ), end };
+//static FLOOPY_CONN_DEVICE_PATH mFloopyBDevicePath = { acpi, pci( 0x1F,0x00 ),lpc( 0x0604,1 ), end };
+
+*/
+
+//
+// End Shanmu
+//
+#pragma pack()
+
+#endif
diff --git a/Nt32Pkg/MiscSubClassPlatformDxe/MiscNumberOfInstallableLanguagesData.c b/Nt32Pkg/MiscSubClassPlatformDxe/MiscNumberOfInstallableLanguagesData.c
new file mode 100644
index 0000000000..b3d2c2eceb
--- /dev/null
+++ b/Nt32Pkg/MiscSubClassPlatformDxe/MiscNumberOfInstallableLanguagesData.c
@@ -0,0 +1,42 @@
+/*++
+
+Copyright (c) 2006, Intel Corporation
+All rights reserved. This program and the accompanying materials
+are licensed and made available under the terms and conditions of the BSD License
+which accompanies this distribution. The full text of the license may be found at
+http://opensource.org/licenses/bsd-license.php
+
+THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+
+Module Name:
+
+ MiscNumberOfInstallableLanguagesData.c
+
+Abstract:
+
+ This driver parses the mMiscSubclassDataTable structure and reports
+ any generated data to the DataHub.
+
+--*/
+
+//
+// Include common header file for this module.
+//
+#include "CommonHeader.h"
+
+#include "MiscSubclassDriver.h"
+
+//
+// Static (possibly build generated) Bios Vendor data.
+//
+MISC_SUBCLASS_TABLE_DATA(EFI_MISC_NUMBER_OF_INSTALLABLE_LANGUAGES_DATA, NumberOfInstallableLanguages) = {
+ 1, // NumberOfInstallableLanguages
+ { // LanguageFlags
+ 0, // AbbreviatedLanguageFormat
+ 0 // Reserved
+ },
+ 0, // CurrentLanguageNumber
+};
+
+/* eof - MiscNumberOfInstallableLanguagesData.c */
diff --git a/Nt32Pkg/MiscSubClassPlatformDxe/MiscOemString.uni b/Nt32Pkg/MiscSubClassPlatformDxe/MiscOemString.uni
new file mode 100644
index 0000000000..9306f0f03d
--- /dev/null
+++ b/Nt32Pkg/MiscSubClassPlatformDxe/MiscOemString.uni
Binary files differ
diff --git a/Nt32Pkg/MiscSubClassPlatformDxe/MiscOemStringData.c b/Nt32Pkg/MiscSubClassPlatformDxe/MiscOemStringData.c
new file mode 100644
index 0000000000..7d89033281
--- /dev/null
+++ b/Nt32Pkg/MiscSubClassPlatformDxe/MiscOemStringData.c
@@ -0,0 +1,37 @@
+/*++
+
+Copyright (c) 2006, Intel Corporation
+All rights reserved. This program and the accompanying materials
+are licensed and made available under the terms and conditions of the BSD License
+which accompanies this distribution. The full text of the license may be found at
+http://opensource.org/licenses/bsd-license.php
+
+THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+
+Module Name:
+
+ MiscOemStringData.c
+
+Abstract:
+
+ This driver parses the mMiscSubclassDataTable structure and reports
+ any generated data to the DataHub.
+
+--*/
+
+//
+// Include common header file for this module.
+//
+#include "CommonHeader.h"
+
+#include "MiscSubclassDriver.h"
+
+//
+// Static (possibly build generated) Bios Vendor data.
+//
+MISC_SUBCLASS_TABLE_DATA(EFI_MISC_OEM_STRING_DATA, OemString) = {
+ STRING_TOKEN(STR_MISC_OEM_STRING)
+};
+
+/* eof - MiscOemStringData.c */
diff --git a/Nt32Pkg/MiscSubClassPlatformDxe/MiscPortInternalConnectorDesignator.uni b/Nt32Pkg/MiscSubClassPlatformDxe/MiscPortInternalConnectorDesignator.uni
new file mode 100644
index 0000000000..aa5ea7051c
--- /dev/null
+++ b/Nt32Pkg/MiscSubClassPlatformDxe/MiscPortInternalConnectorDesignator.uni
Binary files differ
diff --git a/Nt32Pkg/MiscSubClassPlatformDxe/MiscPortInternalConnectorDesignatorData.c b/Nt32Pkg/MiscSubClassPlatformDxe/MiscPortInternalConnectorDesignatorData.c
new file mode 100644
index 0000000000..e961df7aea
--- /dev/null
+++ b/Nt32Pkg/MiscSubClassPlatformDxe/MiscPortInternalConnectorDesignatorData.c
@@ -0,0 +1,104 @@
+/*++
+
+Copyright (c) 2006, Intel Corporation
+All rights reserved. This program and the accompanying materials
+are licensed and made available under the terms and conditions of the BSD License
+which accompanies this distribution. The full text of the license may be found at
+http://opensource.org/licenses/bsd-license.php
+
+THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+
+Module Name:
+
+ MiscPortInternalConnectorDesignatorData.c
+
+Abstract:
+
+ This driver parses the mMiscSubclassDataTable structure and reports
+ any generated data to the DataHub.
+
+--*/
+
+//
+// Include common header file for this module.
+//
+#include "CommonHeader.h"
+
+#include "MiscSubclassDriver.h"
+
+//
+// Static (possibly build generated) Bios Vendor data.
+//
+MISC_SUBCLASS_TABLE_DATA(EFI_MISC_PORT_INTERNAL_CONNECTOR_DESIGNATOR_DATA, MiscPortInternalConnectorDesignator) = {
+ STRING_TOKEN(STR_MISC_PORT_INTERNAL_CONNECTOR_DESIGNATOR), // PortInternalConnectorDesignator
+ STRING_TOKEN(STR_MISC_PORT_EXTERNAL_CONNECTOR_DESIGNATOR), // PortExternalConnectorDesignator
+ EfiPortConnectorTypeOther, // PortInternalConnectorType
+ EfiPortConnectorTypeOther, // PortExternalConnectorType
+ EfiPortTypeNone, // PortType
+ 0 // PortPath
+};
+
+//
+// Static (possibly build generated) Bios Vendor data.
+//
+MISC_SUBCLASS_TABLE_DATA(EFI_MISC_PORT_INTERNAL_CONNECTOR_DESIGNATOR_DATA, MiscPortKeyboard) = {
+ STRING_TOKEN (STR_MISC_PORT_INTERNAL_KEYBOARD), // PortInternalConnectorDesignator
+ STRING_TOKEN (STR_MISC_PORT_EXTERNAL_KEYBOARD), // PortExternalConnectorDesignator
+ EfiPortConnectorTypeNone, // PortInternalConnectorType
+ EfiPortConnectorTypePS2, // PortExternalConnectorType
+ EfiPortTypeKeyboard, // PortType
+ // mPs2KbyboardDevicePath // PortPath
+ //
+ 0
+};
+
+MISC_SUBCLASS_TABLE_DATA(EFI_MISC_PORT_INTERNAL_CONNECTOR_DESIGNATOR_DATA, MiscPortMouse) = {
+ STRING_TOKEN (STR_MISC_PORT_INTERNAL_MOUSE), // PortInternalConnectorDesignator
+ STRING_TOKEN (STR_MISC_PORT_EXTERNAL_MOUSE), // PortExternalConnectorDesignator
+ EfiPortConnectorTypeNone, // PortInternalConnectorType
+ EfiPortConnectorTypePS2, // PortExternalConnectorType
+ EfiPortTypeMouse, // PortType
+ // mPs2MouseDevicePath // PortPath
+ //
+ 0
+};
+
+
+MISC_SUBCLASS_TABLE_DATA(EFI_MISC_PORT_INTERNAL_CONNECTOR_DESIGNATOR_DATA, MiscPortCom1) = {
+ STRING_TOKEN(STR_MISC_PORT_INTERNAL_COM1),
+ STRING_TOKEN(STR_MISC_PORT_EXTERNAL_COM1),
+ EfiPortConnectorTypeNone,
+ EfiPortConnectorTypeDB9Female,
+ EfiPortTypeSerial16550ACompatible,
+ 0
+};
+
+MISC_SUBCLASS_TABLE_DATA(EFI_MISC_PORT_INTERNAL_CONNECTOR_DESIGNATOR_DATA, MiscPortCom2) = {
+ STRING_TOKEN(STR_MISC_PORT_INTERNAL_COM2),
+ STRING_TOKEN(STR_MISC_PORT_EXTERNAL_COM2),
+ EfiPortConnectorTypeNone,
+ EfiPortConnectorTypeDB9Female,
+ EfiPortTypeSerial16550ACompatible,
+ 0
+};
+
+MISC_SUBCLASS_TABLE_DATA(EFI_MISC_PORT_INTERNAL_CONNECTOR_DESIGNATOR_DATA, MiscPortExtensionPower) = {
+ STRING_TOKEN(STR_MISC_PORT_INTERNAL_EXTENSION_POWER),
+ STRING_TOKEN(STR_MISC_PORT_EXTERNAL_EXTENSION_POWER),
+ EfiPortConnectorTypeOther,
+ EfiPortConnectorTypeNone,
+ EfiPortTypeOther,
+ 0
+};
+
+MISC_SUBCLASS_TABLE_DATA(EFI_MISC_PORT_INTERNAL_CONNECTOR_DESIGNATOR_DATA, MiscPortFloppy) = {
+ STRING_TOKEN(STR_MISC_PORT_INTERNAL_FLOPPY),
+ STRING_TOKEN(STR_MISC_PORT_EXTERNAL_FLOPPY),
+ EfiPortConnectorTypeOnboardFloppy,
+ EfiPortConnectorTypeNone,
+ EfiPortTypeOther,
+ 0
+};
+
+/* eof - MiscPortInternalConnectorDesignatorData.c */
diff --git a/Nt32Pkg/MiscSubClassPlatformDxe/MiscPortInternalConnectorDesignatorFunction.c b/Nt32Pkg/MiscSubClassPlatformDxe/MiscPortInternalConnectorDesignatorFunction.c
new file mode 100644
index 0000000000..d493ef0bc7
--- /dev/null
+++ b/Nt32Pkg/MiscSubClassPlatformDxe/MiscPortInternalConnectorDesignatorFunction.c
@@ -0,0 +1,271 @@
+/*++
+
+Copyright (c) 2006, Intel Corporation
+All rights reserved. This program and the accompanying materials
+are licensed and made available under the terms and conditions of the BSD License
+which accompanies this distribution. The full text of the license may be found at
+http://opensource.org/licenses/bsd-license.php
+
+THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+
+Module Name:
+
+ MiscPortInternalConnectorDesignatorFunction.c
+
+Abstract:
+
+ This driver parses the mMiscSubclassDataTable structure and reports
+ any generated data to the DataHub.
+
+--*/
+
+//
+// Include common header file for this module.
+//
+#include "CommonHeader.h"
+
+#include "MiscSubclassDriver.h"
+
+//
+//
+//
+MISC_SUBCLASS_TABLE_FUNCTION (
+ MiscPortInternalConnectorDesignator
+ )
+/*++
+Description:
+
+ This function makes boot time changes to the contents of the
+ MiscPortConnectorInformation (Type 8).
+
+Parameters:
+
+ RecordType
+ Type of record to be processed from the Data Table.
+ mMiscSubclassDataTable[].RecordType
+
+ RecordLen
+ Size of static RecordData from the Data Table.
+ mMiscSubclassDataTable[].RecordLen
+
+ RecordData
+ Pointer to copy of RecordData from the Data Table. Changes made
+ to this copy will be written to the Data Hub but will not alter
+ the contents of the static Data Table.
+
+ LogRecordData
+ Set *LogRecordData to TRUE to log RecordData to Data Hub.
+ Set *LogRecordData to FALSE when there is no more data to log.
+
+Returns:
+
+ EFI_SUCCESS
+ All parameters were valid and *RecordData and *LogRecordData have
+ been set.
+
+ EFI_UNSUPPORTED
+ Unexpected RecordType value.
+
+ EFI_INVALID_PARAMETER
+ One of the following parameter conditions was true:
+ RecordLen was zero.
+ RecordData was NULL.
+ LogRecordData was NULL.
+--*/
+{
+ STATIC BOOLEAN Done = FALSE;
+ STATIC PS2_CONN_DEVICE_PATH mPs2KeyboardDevicePath = { DP_ACPI, DP_PCI (0x1F, 0x00), DP_LPC (0x0303, 0), DP_END };
+ STATIC PS2_CONN_DEVICE_PATH mPs2MouseDevicePath = { DP_ACPI, DP_PCI (0x1F, 0x00), DP_LPC (0x0303, 1), DP_END };
+ STATIC SERIAL_CONN_DEVICE_PATH mCom1DevicePath = { DP_ACPI, DP_PCI (0x1F, 0x00), DP_LPC (0x0501, 0), DP_END };
+ STATIC SERIAL_CONN_DEVICE_PATH mCom2DevicePath = { DP_ACPI, DP_PCI (0x1F, 0x00), DP_LPC (0x0501, 1), DP_END };
+ STATIC PARALLEL_CONN_DEVICE_PATH mLpt1DevicePath = { DP_ACPI, DP_PCI (0x1F, 0x00), DP_LPC (0x0401, 0), DP_END };
+ STATIC FLOOPY_CONN_DEVICE_PATH mFloopyADevicePath = { DP_ACPI, DP_PCI (0x1F, 0x00), DP_LPC (0x0604, 0), DP_END };
+ STATIC FLOOPY_CONN_DEVICE_PATH mFloopyBDevicePath = { DP_ACPI, DP_PCI (0x1F, 0x00), DP_LPC (0x0604, 1), DP_END };
+ STATIC USB_PORT_DEVICE_PATH mUsb0DevicePath = { DP_ACPI, DP_PCI (0x1d, 0x00), DP_END };
+ STATIC USB_PORT_DEVICE_PATH mUsb1DevicePath = { DP_ACPI, DP_PCI (0x1d, 0x01), DP_END };
+ STATIC USB_PORT_DEVICE_PATH mUsb2DevicePath = { DP_ACPI, DP_PCI (0x1d, 0x02), DP_END };
+ STATIC USB_PORT_DEVICE_PATH mUsb3DevicePath = { DP_ACPI, DP_PCI (0x1d, 0x07), DP_END };
+ STATIC IDE_DEVICE_PATH mIdeDevicePath = { DP_ACPI, DP_PCI (0x1F, 0x01), DP_END };
+ STATIC GB_NIC_DEVICE_PATH mGbNicDevicePath = { DP_ACPI, DP_PCI( 0x03,0x00 ),DP_PCI( 0x1F,0x00 ),DP_PCI( 0x07,0x00 ), DP_END };
+ EFI_DEVICE_PATH_PROTOCOL EndDevicePath = DP_END;
+
+ //
+ // First check for invalid parameters.
+ //
+ // Shanmu >> to fix the Device Path Issue...
+ // if (RecordLen == 0 || RecordData == NULL || LogRecordData == NULL) {
+ //
+ if (*RecordLen == 0 || RecordData == NULL || LogRecordData == NULL) {
+ //
+ // End Shanmu
+ //
+ return EFI_INVALID_PARAMETER;
+ }
+ //
+ // Then check for unsupported RecordType.
+ //
+ if (RecordType != EFI_MISC_PORT_INTERNAL_CONNECTOR_DESIGNATOR_RECORD_NUMBER) {
+ return EFI_UNSUPPORTED;
+ }
+ //
+ // Is this the first time through this function?
+ //
+ if (!Done) {
+ //
+ // Yes, this is the first time. Inspect/Change the contents of the
+ // RecordData structure.
+ //
+ //
+ // Device path is only updated here as it was not taking that in static data
+ //
+ // Shanmu >> to fix the Device Path Issue...
+ //
+
+ /*
+ switch (((EFI_MISC_PORT_INTERNAL_CONNECTOR_DESIGNATOR_DATA *)RecordData)->PortInternalConnectorDesignator)
+ {
+ case STR_MISC_PORT_INTERNAL_MOUSE:
+ {
+ (EFI_DEVICE_PATH_PROTOCOL)((EFI_MISC_PORT_INTERNAL_CONNECTOR_DESIGNATOR_DATA *)RecordData)->PortPath = *((EFI_DEVICE_PATH_PROTOCOL*)&mPs2MouseDevicePath);
+ }break;
+ case STR_MISC_PORT_INTERNAL_KEYBOARD:
+ {
+ (EFI_DEVICE_PATH_PROTOCOL)((EFI_MISC_PORT_INTERNAL_CONNECTOR_DESIGNATOR_DATA *)RecordData)->PortPath = *((EFI_DEVICE_PATH_PROTOCOL*)&mPs2KeyboardDevicePath);
+ }break;
+ case STR_MISC_PORT_INTERNAL_COM1:
+ {
+ (EFI_DEVICE_PATH_PROTOCOL)((EFI_MISC_PORT_INTERNAL_CONNECTOR_DESIGNATOR_DATA *)RecordData)->PortPath = *((EFI_DEVICE_PATH_PROTOCOL*)&mCom1DevicePath);
+ }break;
+ case STR_MISC_PORT_INTERNAL_COM2:
+ {
+ (EFI_DEVICE_PATH_PROTOCOL)((EFI_MISC_PORT_INTERNAL_CONNECTOR_DESIGNATOR_DATA *)RecordData)->PortPath = *((EFI_DEVICE_PATH_PROTOCOL*)&mCom2DevicePath);
+ }break;
+ case STR_MISC_PORT_INTERNAL_LPT1:
+ {
+ (EFI_DEVICE_PATH_PROTOCOL)((EFI_MISC_PORT_INTERNAL_CONNECTOR_DESIGNATOR_DATA *)RecordData)->PortPath = *((EFI_DEVICE_PATH_PROTOCOL*)&mLpt1DevicePath);
+ }break;
+ case STR_MISC_PORT_INTERNAL_USB1:
+ {
+ (EFI_DEVICE_PATH_PROTOCOL)((EFI_MISC_PORT_INTERNAL_CONNECTOR_DESIGNATOR_DATA *)RecordData)->PortPath = *((EFI_DEVICE_PATH_PROTOCOL*)&mUsb0DevicePath);
+ }break;
+ case STR_MISC_PORT_INTERNAL_USB2:
+ {
+ (EFI_DEVICE_PATH_PROTOCOL)((EFI_MISC_PORT_INTERNAL_CONNECTOR_DESIGNATOR_DATA *)RecordData)->PortPath = *((EFI_DEVICE_PATH_PROTOCOL*)&mUsb1DevicePath);
+ }break;
+ case STR_MISC_PORT_INTERNAL_USB3:
+ {
+ (EFI_DEVICE_PATH_PROTOCOL)((EFI_MISC_PORT_INTERNAL_CONNECTOR_DESIGNATOR_DATA *)RecordData)->PortPath = *((EFI_DEVICE_PATH_PROTOCOL*)&mUsb2DevicePath);
+ }break;
+ case STR_MISC_PORT_INTERNAL_NETWORK:
+ {
+ (EFI_DEVICE_PATH_PROTOCOL)((EFI_MISC_PORT_INTERNAL_CONNECTOR_DESIGNATOR_DATA *)RecordData)->PortPath = *((EFI_DEVICE_PATH_PROTOCOL*)&mGbNicDevicePath);
+ }break;
+ case STR_MISC_PORT_INTERNAL_FLOPPY:
+ {
+ (EFI_DEVICE_PATH_PROTOCOL)((EFI_MISC_PORT_INTERNAL_CONNECTOR_DESIGNATOR_DATA *)RecordData)->PortPath = *((EFI_DEVICE_PATH_PROTOCOL*)&mFloopyADevicePath);
+ }break;
+ case STR_MISC_PORT_INTERNAL_IDE1:
+ {
+ (EFI_DEVICE_PATH_PROTOCOL)((EFI_MISC_PORT_INTERNAL_CONNECTOR_DESIGNATOR_DATA *)RecordData)->PortPath = *((EFI_DEVICE_PATH_PROTOCOL*)&mIdeDevicePath);
+ }break;
+ case STR_MISC_PORT_INTERNAL_IDE2:
+ {
+ (EFI_DEVICE_PATH_PROTOCOL)((EFI_MISC_PORT_INTERNAL_CONNECTOR_DESIGNATOR_DATA *)RecordData)->PortPath = *((EFI_DEVICE_PATH_PROTOCOL*)&mIdeDevicePath);
+ }break;
+ default:
+ {
+ (EFI_DEVICE_PATH_PROTOCOL)((EFI_MISC_PORT_INTERNAL_CONNECTOR_DESIGNATOR_DATA *)RecordData)->PortPath = EndDevicePath;
+ }break;
+ }
+ */
+ switch (((EFI_MISC_PORT_INTERNAL_CONNECTOR_DESIGNATOR_DATA *) RecordData)->PortInternalConnectorDesignator) {
+ case STR_MISC_PORT_INTERNAL_MOUSE:
+ {
+ CopyMem (
+ &((EFI_MISC_PORT_INTERNAL_CONNECTOR_DESIGNATOR_DATA *) RecordData)->PortPath,
+ &mPs2MouseDevicePath,
+ GetDevicePathSize ((EFI_DEVICE_PATH_PROTOCOL *) &mPs2MouseDevicePath)
+ );
+ *RecordLen = *RecordLen - sizeof (EFI_MISC_PORT_DEVICE_PATH) + GetDevicePathSize ((EFI_DEVICE_PATH_PROTOCOL *) &mPs2MouseDevicePath);
+ }
+ break;
+
+ case STR_MISC_PORT_INTERNAL_KEYBOARD:
+ {
+ CopyMem (
+ &((EFI_MISC_PORT_INTERNAL_CONNECTOR_DESIGNATOR_DATA *) RecordData)->PortPath,
+ &mPs2KeyboardDevicePath,
+ GetDevicePathSize ((EFI_DEVICE_PATH_PROTOCOL *) &mPs2KeyboardDevicePath)
+ );
+ *RecordLen = *RecordLen - sizeof (EFI_MISC_PORT_DEVICE_PATH) + GetDevicePathSize ((EFI_DEVICE_PATH_PROTOCOL *) &mPs2KeyboardDevicePath);
+ }
+ break;
+
+ case STR_MISC_PORT_INTERNAL_COM1:
+ {
+ CopyMem (
+ &((EFI_MISC_PORT_INTERNAL_CONNECTOR_DESIGNATOR_DATA *) RecordData)->PortPath,
+ &mCom1DevicePath,
+ GetDevicePathSize ((EFI_DEVICE_PATH_PROTOCOL *) &mCom1DevicePath)
+ );
+ *RecordLen = *RecordLen - sizeof (EFI_MISC_PORT_DEVICE_PATH) + GetDevicePathSize ((EFI_DEVICE_PATH_PROTOCOL *) &mCom1DevicePath);
+ }
+ break;
+
+ case STR_MISC_PORT_INTERNAL_COM2:
+ {
+ CopyMem (
+ &((EFI_MISC_PORT_INTERNAL_CONNECTOR_DESIGNATOR_DATA *) RecordData)->PortPath,
+ &mCom2DevicePath,
+ GetDevicePathSize ((EFI_DEVICE_PATH_PROTOCOL *) &mCom2DevicePath)
+ );
+ *RecordLen = *RecordLen - sizeof (EFI_MISC_PORT_DEVICE_PATH) + GetDevicePathSize ((EFI_DEVICE_PATH_PROTOCOL *) &mCom2DevicePath);
+ }
+ break;
+
+ case STR_MISC_PORT_INTERNAL_FLOPPY:
+ {
+ CopyMem (
+ &((EFI_MISC_PORT_INTERNAL_CONNECTOR_DESIGNATOR_DATA *) RecordData)->PortPath,
+ &mFloopyADevicePath,
+ GetDevicePathSize ((EFI_DEVICE_PATH_PROTOCOL *) &mFloopyADevicePath)
+ );
+ *RecordLen = *RecordLen - sizeof (EFI_MISC_PORT_DEVICE_PATH) + GetDevicePathSize ((EFI_DEVICE_PATH_PROTOCOL *) &mFloopyADevicePath);
+ }
+ break;
+
+ default:
+ {
+ CopyMem (
+ &((EFI_MISC_PORT_INTERNAL_CONNECTOR_DESIGNATOR_DATA *) RecordData)->PortPath,
+ &EndDevicePath,
+ GetDevicePathSize ((EFI_DEVICE_PATH_PROTOCOL *) &EndDevicePath)
+ );
+ *RecordLen = *RecordLen - sizeof (EFI_MISC_PORT_DEVICE_PATH) + GetDevicePathSize ((EFI_DEVICE_PATH_PROTOCOL *) &EndDevicePath);
+ }
+ break;
+ }
+ //
+ // End Shanmu
+ //
+ // Set Done flag to TRUE for next pass through this function.
+ // Set *LogRecordData to TRUE so data will get logged to Data Hub.
+ //
+ Done = TRUE;
+ *LogRecordData = TRUE;
+ } else {
+ //
+ // No, this is the second time. Reset the state of the Done flag
+ // to FALSE and tell the data logger that there is no more data
+ // to be logged for this record type. If any memory allocations
+ // were made by earlier passes, they must be released now.
+ //
+ Done = FALSE;
+ *LogRecordData = FALSE;
+ }
+
+ return EFI_SUCCESS;
+}
+
+/* eof - MiscSystemManufacturerFunction.c */
diff --git a/Nt32Pkg/MiscSubClassPlatformDxe/MiscResetCapabilitiesData.c b/Nt32Pkg/MiscSubClassPlatformDxe/MiscResetCapabilitiesData.c
new file mode 100644
index 0000000000..65bd0b5049
--- /dev/null
+++ b/Nt32Pkg/MiscSubClassPlatformDxe/MiscResetCapabilitiesData.c
@@ -0,0 +1,47 @@
+/*++
+
+Copyright (c) 2006, Intel Corporation
+All rights reserved. This program and the accompanying materials
+are licensed and made available under the terms and conditions of the BSD License
+which accompanies this distribution. The full text of the license may be found at
+http://opensource.org/licenses/bsd-license.php
+
+THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+
+Module Name:
+
+ MiscResetCapabilitiesData.c
+
+Abstract:
+
+ This driver parses the mMiscSubclassDataTable structure and reports
+ any generated data to the DataHub.
+
+--*/
+
+//
+// Include common header file for this module.
+//
+#include "CommonHeader.h"
+
+#include "MiscSubclassDriver.h"
+
+//
+// Static (possibly build generated) Bios Vendor data.
+//
+MISC_SUBCLASS_TABLE_DATA(EFI_MISC_RESET_CAPABILITIES, MiscResetCapabilities) = {
+ { // ResetCapabilities
+ 0, // Status
+ 0, // BootOption
+ 0, // BootOptionOnLimit
+ 0, // WatchdogTimerPresent
+ 0 // Reserved
+ },
+ 0, // ResetCount
+ 0, // ResetLimit
+ 0, // ResetTimerInterval
+ 0 // ResetTimeout
+};
+
+/* eof - MiscResetCapabilities.c */
diff --git a/Nt32Pkg/MiscSubClassPlatformDxe/MiscSubclassDriver.dxs b/Nt32Pkg/MiscSubClassPlatformDxe/MiscSubclassDriver.dxs
new file mode 100644
index 0000000000..c9592dedab
--- /dev/null
+++ b/Nt32Pkg/MiscSubClassPlatformDxe/MiscSubclassDriver.dxs
@@ -0,0 +1,31 @@
+/*++
+
+Copyright (c) 2006, Intel Corporation
+All rights reserved. This program and the accompanying materials
+are licensed and made available under the terms and conditions of the BSD License
+which accompanies this distribution. The full text of the license may be found at
+http://opensource.org/licenses/bsd-license.php
+
+THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+
+Module Name:
+
+ MiscSubclassDriver.dxs
+
+Abstract:
+
+ Dependency expression file for MiscSubclass Driver.
+
+--*/
+
+//
+// Include common header file for this module.
+//
+#include "CommonHeader.h"
+
+#include <DxeDepex.h>
+
+DEPENDENCY_START
+ EFI_DATA_HUB_PROTOCOL_GUID AND EFI_HII_PROTOCOL_GUID
+DEPENDENCY_END
diff --git a/Nt32Pkg/MiscSubClassPlatformDxe/MiscSubclassDriver.h b/Nt32Pkg/MiscSubClassPlatformDxe/MiscSubclassDriver.h
new file mode 100644
index 0000000000..c468b59fb5
--- /dev/null
+++ b/Nt32Pkg/MiscSubClassPlatformDxe/MiscSubclassDriver.h
@@ -0,0 +1,109 @@
+/*++
+
+Copyright (c) 2006, Intel Corporation
+All rights reserved. This program and the accompanying materials
+are licensed and made available under the terms and conditions of the BSD License
+which accompanies this distribution. The full text of the license may be found at
+http://opensource.org/licenses/bsd-license.php
+
+THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+
+Module Name:
+
+ MiscSubclassDriver.h
+
+Abstract:
+
+ Header file for MiscSubclass Driver.
+
+--*/
+
+#ifndef _MISC_SUBCLASS_DRIVER_H
+#define _MISC_SUBCLASS_DRIVER_H
+
+
+//
+// Include common header file for this module.
+//
+#include "CommonHeader.h"
+
+#include <MiscDevicePath.h>
+
+//
+// Autogen string file
+//
+#include <MiscSubclassStrDefs.h>
+
+//
+// Data table entry update function.
+//
+typedef
+EFI_STATUS
+(EFIAPI EFI_MISC_SUBCLASS_DATA_FUNCTION) (
+ IN UINT16 RecordType,
+ IN UINT32 *RecordLen,
+ IN OUT EFI_MISC_SUBCLASS_RECORDS *RecordData,
+ OUT BOOLEAN *LogRecordData
+ );
+
+//
+// Data table entry definition.
+//
+typedef struct {
+ UINT16 RecordType;
+ UINT32 RecordLen;
+ VOID *RecordData;
+ EFI_MISC_SUBCLASS_DATA_FUNCTION *Function;
+} EFI_MISC_SUBCLASS_DATA_TABLE;
+
+//
+// Data Table extern definitions.
+//
+#define MISC_SUBCLASS_TABLE_EXTERNS(NAME1, NAME2) \
+ extern NAME1 NAME2 ## Data; \
+ extern EFI_MISC_SUBCLASS_DATA_FUNCTION NAME2 ## Function
+
+//
+// Data Table entries
+//
+#define MISC_SUBCLASS_TABLE_ENTRY_DATA_ONLY(NAME1, NAME2) { \
+ NAME1 ## _RECORD_NUMBER, sizeof (NAME1 ## _DATA), &NAME2 ## Data, NULL \
+ }
+
+#define MISC_SUBCLASS_TABLE_ENTRY_FUNCTION_ONLY(NAME1, NAME2) \
+ { \
+ NAME1 ## _RECORD_NUMBER, 0, NULL, &NAME2 ## Function \
+ }
+
+#define MISC_SUBCLASS_TABLE_ENTRY_DATA_AND_FUNCTION(NAME1, NAME2, NAME3) \
+ { \
+ NAME1 ## _RECORD_NUMBER, sizeof (NAME1 ## _DATA), &NAME2 ## Data, &NAME3 ## Function \
+ }
+
+//
+// Global definition macros.
+//
+#define MISC_SUBCLASS_TABLE_DATA(NAME1, NAME2) NAME1 NAME2 ## Data
+
+#define MISC_SUBCLASS_TABLE_FUNCTION(NAME2) \
+ EFI_STATUS EFIAPI NAME2 ## Function ( \
+ IN UINT16 RecordType, \
+ IN UINT32 *RecordLen, \
+ IN OUT EFI_MISC_SUBCLASS_RECORDS * RecordData, \
+ OUT BOOLEAN *LogRecordData \
+ )
+
+//
+// Data Table Array
+//
+extern EFI_MISC_SUBCLASS_DATA_TABLE mMiscSubclassDataTable[];
+
+//
+// Data Table Array Entries
+//
+extern UINTN mMiscSubclassDataTableEntries;
+
+#endif /* _MISC_SUBCLASS_DRIVER_H */
+
+/* eof - MiscSubclassDriver.h */
diff --git a/Nt32Pkg/MiscSubClassPlatformDxe/MiscSubclassDriver.inf b/Nt32Pkg/MiscSubClassPlatformDxe/MiscSubclassDriver.inf
new file mode 100644
index 0000000000..c9a43c20f4
--- /dev/null
+++ b/Nt32Pkg/MiscSubClassPlatformDxe/MiscSubclassDriver.inf
@@ -0,0 +1,145 @@
+#/** @file
+# Misc Sub class driver
+#
+# Parses the MiscSubclassDataTable and reports any generated data to the DataHub.
+# All .uni file who tagged with "ToolCode="DUMMY"" in following file list is included by
+# MiscSubclassDriver.uni file, the StrGather tool will expand MiscSubclassDriver.uni file
+# and parse all .uni file.
+# Copyright (c) 2006 - 2007, Intel Corporation
+#
+# All rights reserved. This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+#
+#
+#**/
+
+################################################################################
+#
+# Defines Section - statements that will be processed to create a Makefile.
+#
+################################################################################
+[Defines]
+ INF_VERSION = 0x00010005
+ BASE_NAME = MiscSubclass
+ FILE_GUID = 4A9B9DB8-EC62-4A92-818F-8AA0246D246E
+ MODULE_TYPE = DXE_DRIVER
+ VERSION_STRING = 1.0
+ EDK_RELEASE_VERSION = 0x00020000
+ EFI_SPECIFICATION_VERSION = 0x00020000
+
+ ENTRY_POINT = MiscSubclassDriverEntryPoint
+
+#
+# The following information is for reference only and not required by the build tools.
+#
+# VALID_ARCHITECTURES = IA32
+#
+
+################################################################################
+#
+# Sources Section - list of files that are required for the build to succeed.
+#
+################################################################################
+
+[Sources.common]
+ MiscSubclassDriver.dxs
+ MiscPortInternalConnectorDesignatorFunction.c
+ MiscSystemSlotDesignationData.c
+ MiscSystemOptionStringData.c
+ MiscSystemManufacturerFunction.c
+ MiscSystemManufacturerData.c
+ MiscSystemLanguageStringData.c
+ MiscResetCapabilitiesData.c
+ MiscPortInternalConnectorDesignatorData.c
+ MiscOemStringData.c
+ MiscNumberOfInstallableLanguagesData.c
+ MiscChassisManufacturerData.c
+ MiscBootInformationData.c
+ MiscBiosVendorData.c
+ MiscBaseBoardManufacturerData.c
+ MiscSubclassDriverDataTable.c
+ MiscSubclassDriverEntryPoint.c
+ MiscSubclassDriver.h
+ MiscDevicePath.h
+ MiscSubclassDriver.uni
+ MiscSystemSlotDesignation.uni
+ MiscSystemOptionString.uni
+ MiscSystemManufacturer.uni
+ MiscSystemLanguageString.uni
+ MiscPortInternalConnectorDesignator.uni
+ MiscOemString.uni
+ MiscChassisManufacturer.uni
+ MiscBiosVendor.uni
+ MiscBaseBoardManufacturer.uni
+ CommonHeader.h
+
+
+################################################################################
+#
+# Includes Section - list of Include locations that are required for
+# this module.
+#
+################################################################################
+
+[Includes]
+ $(WORKSPACE)/MdePkg/Include/Library
+
+################################################################################
+#
+# Package Dependency Section - list of Package files that are required for
+# this module.
+#
+################################################################################
+
+[Packages]
+ MdePkg/MdePkg.dec
+ #MdeModulePkg/MdeModulePkg.dec
+ IntelFrameworkPkg/IntelFrameworkPkg.dec
+ Nt32Pkg/Nt32Pkg.dec
+
+
+################################################################################
+#
+# Library Class Section - list of Library Classes that are required for
+# this module.
+#
+################################################################################
+
+[LibraryClasses]
+ DevicePathLib
+ UefiBootServicesTableLib
+ MemoryAllocationLib
+ BaseMemoryLib
+ UefiDriverEntryPoint
+ UefiLib
+ HiiLib
+ DebugLib
+ BaseLib
+
+
+################################################################################
+#
+# Guid C Name Section - list of Guids that this module uses or produces.
+#
+################################################################################
+
+[Guids]
+ gEfiWinNtMemoryGuid # SOMETIMES_CONSUMED
+
+
+################################################################################
+#
+# Protocol C Name Section - list of Protocol and Protocol Notify C Names
+# that this module uses or produces.
+#
+################################################################################
+
+[Protocols]
+ gEfiWinNtIoProtocolGuid # PROTOCOL_NOTIFY SOMETIMES_CONSUMED
+ gEfiHiiProtocolGuid # PROTOCOL ALWAYS_CONSUMED
+ gEfiDataHubProtocolGuid # PROTOCOL ALWAYS_CONSUMED
+
diff --git a/Nt32Pkg/MiscSubClassPlatformDxe/MiscSubclassDriver.msa b/Nt32Pkg/MiscSubClassPlatformDxe/MiscSubclassDriver.msa
new file mode 100644
index 0000000000..533ec7e1da
--- /dev/null
+++ b/Nt32Pkg/MiscSubClassPlatformDxe/MiscSubclassDriver.msa
@@ -0,0 +1,128 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<ModuleSurfaceArea xmlns="http://www.TianoCore.org/2006/Edk2.0">
+ <MsaHeader>
+ <ModuleName>MiscSubclass</ModuleName>
+ <ModuleType>DXE_DRIVER</ModuleType>
+ <GuidValue>4A9B9DB8-EC62-4A92-818F-8AA0246D246E</GuidValue>
+ <Version>1.0</Version>
+ <Abstract>Misc Sub class driver</Abstract>
+ <Description>
+ Parses the MiscSubclassDataTable and reports any generated data to the DataHub.
+ All .uni file who tagged with "ToolCode="DUMMY"" in following file list is included by
+ MiscSubclassDriver.uni file, the StrGather tool will expand MiscSubclassDriver.uni file
+ and parse all .uni file.
+ </Description>
+ <Copyright>Copyright (c) 2006 - 2007, Intel Corporation</Copyright>
+ <License>All rights reserved. This program and the accompanying materials
+ are licensed and made available under the terms and conditions of the BSD License
+ which accompanies this distribution. The full text of the license may be found at
+ http://opensource.org/licenses/bsd-license.php
+ THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.</License>
+ <Specification>FRAMEWORK_BUILD_PACKAGING_SPECIFICATION 0x00000052</Specification>
+ </MsaHeader>
+ <ModuleDefinitions>
+ <SupportedArchitectures>IA32</SupportedArchitectures>
+ <BinaryModule>false</BinaryModule>
+ <OutputFileBasename>MiscSubclass</OutputFileBasename>
+ </ModuleDefinitions>
+ <LibraryClassDefinitions>
+ <LibraryClass Usage="ALWAYS_CONSUMED">
+ <Keyword>BaseLib</Keyword>
+ </LibraryClass>
+ <LibraryClass Usage="ALWAYS_CONSUMED">
+ <Keyword>DebugLib</Keyword>
+ </LibraryClass>
+ <LibraryClass Usage="ALWAYS_CONSUMED">
+ <Keyword>HiiLib</Keyword>
+ </LibraryClass>
+ <LibraryClass Usage="ALWAYS_CONSUMED">
+ <Keyword>UefiLib</Keyword>
+ </LibraryClass>
+ <LibraryClass Usage="ALWAYS_CONSUMED">
+ <Keyword>UefiDriverEntryPoint</Keyword>
+ </LibraryClass>
+ <LibraryClass Usage="ALWAYS_CONSUMED">
+ <Keyword>BaseMemoryLib</Keyword>
+ </LibraryClass>
+ <LibraryClass Usage="ALWAYS_CONSUMED">
+ <Keyword>MemoryAllocationLib</Keyword>
+ </LibraryClass>
+ <LibraryClass Usage="ALWAYS_CONSUMED">
+ <Keyword>UefiBootServicesTableLib</Keyword>
+ </LibraryClass>
+ <LibraryClass Usage="ALWAYS_CONSUMED">
+ <Keyword>DevicePathLib</Keyword>
+ </LibraryClass>
+ </LibraryClassDefinitions>
+ <SourceFiles>
+ <Filename ToolCode="DUMMY">MiscBaseBoardManufacturer.uni</Filename>
+ <Filename ToolCode="DUMMY">MiscBiosVendor.uni</Filename>
+ <Filename ToolCode="DUMMY">MiscChassisManufacturer.uni</Filename>
+ <Filename ToolCode="DUMMY">MiscOemString.uni</Filename>
+ <Filename ToolCode="DUMMY">MiscPortInternalConnectorDesignator.uni</Filename>
+ <Filename ToolCode="DUMMY">MiscSystemLanguageString.uni</Filename>
+ <Filename ToolCode="DUMMY">MiscSystemManufacturer.uni</Filename>
+ <Filename ToolCode="DUMMY">MiscSystemOptionString.uni</Filename>
+ <Filename ToolCode="DUMMY">MiscSystemSlotDesignation.uni</Filename>
+ <Filename>MiscSubclassDriver.uni</Filename>
+ <Filename>MiscDevicePath.h</Filename>
+ <Filename>MiscSubclassDriver.h</Filename>
+ <Filename>MiscSubclassDriverEntryPoint.c</Filename>
+ <Filename>MiscSubclassDriverDataTable.c</Filename>
+ <Filename>MiscBaseBoardManufacturerData.c</Filename>
+ <Filename>MiscBiosVendorData.c</Filename>
+ <Filename>MiscBootInformationData.c</Filename>
+ <Filename>MiscChassisManufacturerData.c</Filename>
+ <Filename>MiscNumberOfInstallableLanguagesData.c</Filename>
+ <Filename>MiscOemStringData.c</Filename>
+ <Filename>MiscPortInternalConnectorDesignatorData.c</Filename>
+ <Filename>MiscResetCapabilitiesData.c</Filename>
+ <Filename>MiscSystemLanguageStringData.c</Filename>
+ <Filename>MiscSystemManufacturerData.c</Filename>
+ <Filename>MiscSystemManufacturerFunction.c</Filename>
+ <Filename>MiscSystemOptionStringData.c</Filename>
+ <Filename>MiscSystemSlotDesignationData.c</Filename>
+ <Filename>MiscPortInternalConnectorDesignatorFunction.c</Filename>
+ <Filename>MiscSubclassDriver.dxs</Filename>
+ </SourceFiles>
+ <PackageDependencies>
+ <Package PackageGuid="5e0e9358-46b6-4ae2-8218-4ab8b9bbdcec"/>
+ <Package PackageGuid="2759ded5-bb57-4b06-af4f-c398fa552719"/>
+ </PackageDependencies>
+ <Protocols>
+ <Protocol Usage="ALWAYS_CONSUMED">
+ <ProtocolCName>gEfiDataHubProtocolGuid</ProtocolCName>
+ </Protocol>
+ <Protocol Usage="ALWAYS_CONSUMED">
+ <ProtocolCName>gEfiHiiProtocolGuid</ProtocolCName>
+ </Protocol>
+ <ProtocolNotify Usage="SOMETIMES_CONSUMED">
+ <ProtocolNotifyCName>gEfiWinNtIoProtocolGuid</ProtocolNotifyCName>
+ </ProtocolNotify>
+ </Protocols>
+ <Guids>
+ <GuidCNames Usage="ALWAYS_CONSUMED">
+ <GuidCName>gEfiMiscSubClassGuid</GuidCName>
+ </GuidCNames>
+ <GuidCNames Usage="SOMETIMES_CONSUMED">
+ <GuidCName>gEfiProcessorSubClassGuid</GuidCName>
+ </GuidCNames>
+ <GuidCNames Usage="SOMETIMES_CONSUMED">
+ <GuidCName>gEfiMemoryProducerGuid</GuidCName>
+ </GuidCNames>
+ <GuidCNames Usage="SOMETIMES_CONSUMED">
+ <GuidCName>gEfiMemorySubClassGuid</GuidCName>
+ </GuidCNames>
+ <GuidCNames Usage="SOMETIMES_CONSUMED">
+ <GuidCName>gEfiWinNtMemoryGuid</GuidCName>
+ </GuidCNames>
+ </Guids>
+ <Externs>
+ <Specification>EFI_SPECIFICATION_VERSION 0x00020000</Specification>
+ <Specification>EDK_RELEASE_VERSION 0x00020000</Specification>
+ <Extern>
+ <ModuleEntryPoint>MiscSubclassDriverEntryPoint</ModuleEntryPoint>
+ </Extern>
+ </Externs>
+</ModuleSurfaceArea> \ No newline at end of file
diff --git a/Nt32Pkg/MiscSubClassPlatformDxe/MiscSubclassDriver.uni b/Nt32Pkg/MiscSubClassPlatformDxe/MiscSubclassDriver.uni
new file mode 100644
index 0000000000..cc426403cd
--- /dev/null
+++ b/Nt32Pkg/MiscSubClassPlatformDxe/MiscSubclassDriver.uni
Binary files differ
diff --git a/Nt32Pkg/MiscSubClassPlatformDxe/MiscSubclassDriverDataTable.c b/Nt32Pkg/MiscSubClassPlatformDxe/MiscSubclassDriverDataTable.c
new file mode 100644
index 0000000000..77abb9c6b5
--- /dev/null
+++ b/Nt32Pkg/MiscSubClassPlatformDxe/MiscSubclassDriverDataTable.c
@@ -0,0 +1,104 @@
+/*++
+
+Copyright (c) 2006, Intel Corporation
+All rights reserved. This program and the accompanying materials
+are licensed and made available under the terms and conditions of the BSD License
+which accompanies this distribution. The full text of the license may be found at
+http://opensource.org/licenses/bsd-license.php
+
+THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+
+Module Name:
+
+ MiscSubclassDriverDataTable.c
+
+Abstract:
+
+ This driver parses the mMiscSubclassDataTable structure and reports
+ any generated data to the DataHub.
+
+--*/
+
+//
+// Include common header file for this module.
+//
+#include "CommonHeader.h"
+
+#include "MiscSubclassDriver.h"
+
+//
+// External definitions referenced by Data Table entries.
+//
+MISC_SUBCLASS_TABLE_EXTERNS (
+ EFI_MISC_CHASSIS_MANUFACTURER_DATA,
+ MiscChassisManufacturer
+ );
+MISC_SUBCLASS_TABLE_EXTERNS (
+ EFI_MISC_BIOS_VENDOR_DATA,
+ MiscBiosVendor
+ );
+MISC_SUBCLASS_TABLE_EXTERNS (
+ EFI_MISC_SYSTEM_MANUFACTURER_DATA,
+ MiscSystemManufacturer
+ );
+MISC_SUBCLASS_TABLE_EXTERNS (
+ EFI_MISC_BASE_BOARD_MANUFACTURER_DATA,
+ MiscBaseBoardManufacturer
+ );
+MISC_SUBCLASS_TABLE_EXTERNS (
+ EFI_MISC_PORT_INTERNAL_CONNECTOR_DESIGNATOR_DATA,
+ MiscPortInternalConnectorDesignator
+ );
+MISC_SUBCLASS_TABLE_EXTERNS (
+ EFI_MISC_PORT_INTERNAL_CONNECTOR_DESIGNATOR_DATA,
+ MiscPortKeyboard
+ );
+MISC_SUBCLASS_TABLE_EXTERNS (
+ EFI_MISC_PORT_INTERNAL_CONNECTOR_DESIGNATOR_DATA,
+ MiscPortMouse
+ );
+MISC_SUBCLASS_TABLE_EXTERNS (
+ EFI_MISC_PORT_INTERNAL_CONNECTOR_DESIGNATOR_DATA,
+ MiscPortCom1
+ );
+MISC_SUBCLASS_TABLE_EXTERNS (
+ EFI_MISC_PORT_INTERNAL_CONNECTOR_DESIGNATOR_DATA,
+ MiscPortCom2
+ );
+MISC_SUBCLASS_TABLE_EXTERNS (
+ EFI_MISC_SYSTEM_SLOT_DESIGNATION_DATA,
+ MiscSystemSlotDesignation
+ );
+MISC_SUBCLASS_TABLE_EXTERNS (
+ EFI_MISC_OEM_STRING_DATA,
+ OemString
+ );
+MISC_SUBCLASS_TABLE_EXTERNS (
+ EFI_MISC_SYSTEM_OPTION_STRING_DATA,
+ SystemOptionString
+ );
+
+//
+// Data Table.
+//
+EFI_MISC_SUBCLASS_DATA_TABLE mMiscSubclassDataTable[] = {
+ MISC_SUBCLASS_TABLE_ENTRY_DATA_AND_FUNCTION(EFI_MISC_PORT_INTERNAL_CONNECTOR_DESIGNATOR, MiscPortKeyboard, MiscPortInternalConnectorDesignator),
+ MISC_SUBCLASS_TABLE_ENTRY_DATA_AND_FUNCTION(EFI_MISC_PORT_INTERNAL_CONNECTOR_DESIGNATOR, MiscPortMouse, MiscPortInternalConnectorDesignator),
+ MISC_SUBCLASS_TABLE_ENTRY_DATA_AND_FUNCTION(EFI_MISC_PORT_INTERNAL_CONNECTOR_DESIGNATOR, MiscPortCom1, MiscPortInternalConnectorDesignator),
+ MISC_SUBCLASS_TABLE_ENTRY_DATA_AND_FUNCTION(EFI_MISC_PORT_INTERNAL_CONNECTOR_DESIGNATOR, MiscPortCom2, MiscPortInternalConnectorDesignator),
+ MISC_SUBCLASS_TABLE_ENTRY_DATA_ONLY(EFI_MISC_BIOS_VENDOR, MiscBiosVendor),
+ MISC_SUBCLASS_TABLE_ENTRY_DATA_ONLY(EFI_MISC_SYSTEM_MANUFACTURER, MiscSystemManufacturer),
+ MISC_SUBCLASS_TABLE_ENTRY_DATA_ONLY(EFI_MISC_BASE_BOARD_MANUFACTURER, MiscBaseBoardManufacturer),
+ MISC_SUBCLASS_TABLE_ENTRY_DATA_ONLY(EFI_MISC_CHASSIS_MANUFACTURER, MiscChassisManufacturer),
+ MISC_SUBCLASS_TABLE_ENTRY_DATA_ONLY(EFI_MISC_SYSTEM_SLOT_DESIGNATION, MiscSystemSlotDesignation),
+ MISC_SUBCLASS_TABLE_ENTRY_DATA_ONLY(EFI_MISC_OEM_STRING, OemString),
+ MISC_SUBCLASS_TABLE_ENTRY_DATA_ONLY(EFI_MISC_SYSTEM_OPTION_STRING, SystemOptionString),
+};
+
+//
+// Number of Data Table entries.
+//
+UINTN mMiscSubclassDataTableEntries = (sizeof mMiscSubclassDataTable) / sizeof (EFI_MISC_SUBCLASS_DATA_TABLE);
+
+/* eof - MiscSubclassDriverDataTable.c */
diff --git a/Nt32Pkg/MiscSubClassPlatformDxe/MiscSubclassDriverEntryPoint.c b/Nt32Pkg/MiscSubClassPlatformDxe/MiscSubclassDriverEntryPoint.c
new file mode 100644
index 0000000000..5eff1d9502
--- /dev/null
+++ b/Nt32Pkg/MiscSubClassPlatformDxe/MiscSubclassDriverEntryPoint.c
@@ -0,0 +1,523 @@
+/*++
+
+Copyright (c) 2006 - 2007, Intel Corporation
+All rights reserved. This program and the accompanying materials
+are licensed and made available under the terms and conditions of the BSD License
+which accompanies this distribution. The full text of the license may be found at
+http://opensource.org/licenses/bsd-license.php
+
+THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+
+Module Name:
+
+ MiscSubclassDriverEntryPoint.c
+
+Abstract:
+
+ This driver parses the mMiscSubclassDataTable structure and reports
+ any generated data to the DataHub.
+
+--*/
+
+//
+// Include common header file for this module.
+//
+#include "CommonHeader.h"
+
+#include "MiscSubclassDriver.h"
+
+
+extern UINT8 MiscSubclassStrings[];
+
+VOID
+EFIAPI
+WinNtIoProtocolNotifyFunction (
+ IN EFI_EVENT Event,
+ IN VOID *Context
+ );
+
+//
+//
+//
+EFI_STATUS
+LogRecordDataToDataHub (
+ EFI_DATA_HUB_PROTOCOL *DataHub,
+ UINT32 RecordType,
+ UINT32 RecordLen,
+ VOID *RecordData
+ )
+/*++
+Description:
+
+Parameters:
+
+ DataHub
+ %%TBD
+
+ RecordType
+ %%TBD
+
+ RecordLen
+ %%TBD
+
+ RecordData
+ %%TBD
+
+Returns:
+
+ EFI_INVALID_PARAMETER
+
+ EFI_SUCCESS
+
+ Other Data Hub errors
+
+--*/
+{
+ EFI_MISC_SUBCLASS_DRIVER_DATA MiscSubclass;
+ EFI_STATUS EfiStatus;
+
+ //
+ // Do nothing if data parameters are not valid.
+ //
+ if (RecordLen == 0 || RecordData == NULL) {
+ DEBUG (
+ (EFI_D_ERROR,
+ "RecordLen == %d RecordData == %xh\n",
+ RecordLen,
+ RecordData)
+ );
+
+ return EFI_INVALID_PARAMETER;
+ }
+ //
+ // Assemble Data Hub record.
+ //
+ MiscSubclass.Header.Version = EFI_MISC_SUBCLASS_VERSION;
+ MiscSubclass.Header.HeaderSize = sizeof (EFI_SUBCLASS_TYPE1_HEADER);
+ MiscSubclass.Header.Instance = 1;
+ MiscSubclass.Header.SubInstance = 1;
+ MiscSubclass.Header.RecordType = RecordType;
+
+ CopyMem (
+ &MiscSubclass.Record,
+ RecordData,
+ RecordLen
+ );
+
+ //
+ // Log Data Hub record.
+ //
+ EfiStatus = DataHub->LogData (
+ DataHub,
+ &gEfiMiscSubClassGuid,
+ &gEfiMiscSubClassGuid,
+ EFI_DATA_RECORD_CLASS_DATA,
+ &MiscSubclass,
+ sizeof (EFI_SUBCLASS_TYPE1_HEADER) + RecordLen
+ );
+
+ if (EFI_ERROR (EfiStatus)) {
+ DEBUG (
+ (EFI_D_ERROR,
+ "LogData(%d bytes) == %r\n",
+ sizeof (EFI_SUBCLASS_TYPE1_HEADER) + RecordLen,
+ EfiStatus)
+ );
+ }
+
+ return EfiStatus;
+}
+
+
+EFI_STATUS
+EFIAPI
+MiscSubclassDriverEntryPoint (
+ IN EFI_HANDLE ImageHandle,
+ IN EFI_SYSTEM_TABLE *SystemTable
+ )
+/*++
+Description:
+
+ Standard EFI driver point. This driver parses the mMiscSubclassDataTable
+ structure and reports any generated data to the DataHub.
+
+Arguments:
+
+ ImageHandle
+ Handle for the image of this driver
+
+ SystemTable
+ Pointer to the EFI System Table
+
+Returns:
+
+ EFI_SUCCESS
+ The data was successfully reported to the Data Hub.
+
+--*/
+{
+ EFI_MISC_SUBCLASS_DRIVER_DATA RecordData;
+ EFI_DATA_HUB_PROTOCOL *DataHub;
+ EFI_HII_PROTOCOL *Hii;
+ EFI_HII_PACKAGES *PackageList;
+ EFI_HII_HANDLE HiiHandle;
+ EFI_STATUS EfiStatus;
+ UINTN Index;
+ BOOLEAN LogRecordData;
+ EFI_EVENT Event;
+ VOID *Registration;
+
+
+ //
+ // Initialize constant portion of subclass header.
+ //
+ RecordData.Header.Version = EFI_MISC_SUBCLASS_VERSION;
+ RecordData.Header.HeaderSize = sizeof (EFI_SUBCLASS_TYPE1_HEADER);
+ RecordData.Header.Instance = 1;
+ RecordData.Header.SubInstance = 1;
+
+ //
+ // Locate data hub protocol.
+ //
+ EfiStatus = gBS->LocateProtocol (&gEfiDataHubProtocolGuid, NULL, &DataHub);
+
+ if (EFI_ERROR (EfiStatus)) {
+ DEBUG ((EFI_D_ERROR, "Could not locate DataHub protocol. %r\n", EfiStatus));
+ return EfiStatus;
+ } else if (DataHub == NULL) {
+ DEBUG ((EFI_D_ERROR, "LocateProtocol(DataHub) returned NULL pointer!\n"));
+ return EFI_DEVICE_ERROR;
+ }
+ //
+ // Locate hii protocol.
+ //
+ EfiStatus = gBS->LocateProtocol (&gEfiHiiProtocolGuid, NULL, &Hii);
+
+ if (EFI_ERROR (EfiStatus)) {
+ DEBUG ((EFI_D_ERROR, "Could not locate Hii protocol. %r\n", EfiStatus));
+ return EfiStatus;
+ } else if (Hii == NULL) {
+ DEBUG ((EFI_D_ERROR, "LocateProtocol(Hii) returned NULL pointer!\n"));
+ return EFI_DEVICE_ERROR;
+ }
+ //
+ // Add our default strings to the HII database. They will be modified later.
+ //
+ PackageList = PreparePackages (1, &gEfiMiscSubClassGuid, MiscSubclassStrings);
+ EfiStatus = Hii->NewPack (Hii, PackageList, &HiiHandle);
+ FreePool (PackageList);
+
+ if (EFI_ERROR (EfiStatus)) {
+ DEBUG ((EFI_D_ERROR, "Could not log default strings to Hii. %r\n", EfiStatus));
+ return EfiStatus;
+ }
+ //
+ //
+ //
+ for (Index = 0; Index < mMiscSubclassDataTableEntries; ++Index) {
+ //
+ // Stupidity check! Do nothing if RecordLen is zero.
+ // %%TBD - Should this be an error or a mechanism for ignoring
+ // records in the Data Table?
+ //
+ if (mMiscSubclassDataTable[Index].RecordLen == 0) {
+ DEBUG (
+ (EFI_D_ERROR,
+ "mMiscSubclassDataTable[%d].RecordLen == 0\n",
+ Index)
+ );
+
+ continue;
+ }
+ //
+ // Initialize per-record portion of subclass header and
+ // copy static data into data portion of subclass record.
+ //
+ RecordData.Header.RecordType = mMiscSubclassDataTable[Index].RecordType;
+
+ if (mMiscSubclassDataTable[Index].RecordData == NULL) {
+ ZeroMem (
+ &RecordData.Record,
+ mMiscSubclassDataTable[Index].RecordLen
+ );
+ } else {
+ CopyMem (
+ &RecordData.Record,
+ mMiscSubclassDataTable[Index].RecordData,
+ mMiscSubclassDataTable[Index].RecordLen
+ );
+ }
+ //
+ // If the entry does not have a function pointer, just log the data.
+ //
+ if (mMiscSubclassDataTable[Index].Function == NULL) {
+ //
+ // Log RecordData to Data Hub.
+ //
+ EfiStatus = DataHub->LogData (
+ DataHub,
+ &gEfiMiscSubClassGuid,
+ &gEfiMiscSubClassGuid,
+ EFI_DATA_RECORD_CLASS_DATA,
+ &RecordData,
+ sizeof (EFI_SUBCLASS_TYPE1_HEADER) + mMiscSubclassDataTable[Index].RecordLen
+ );
+
+ if (EFI_ERROR (EfiStatus)) {
+ DEBUG (
+ (EFI_D_ERROR,
+ "LogData(%d bytes) == %r\n",
+ sizeof (EFI_SUBCLASS_TYPE1_HEADER) + mMiscSubclassDataTable[Index].RecordLen,
+ EfiStatus)
+ );
+ }
+
+ continue;
+ }
+ //
+ // The entry has a valid function pointer.
+ // Keep calling the function and logging data until there
+ // is no more data to log.
+ //
+ for (;;) {
+ //
+ //
+ //
+ EfiStatus = (*mMiscSubclassDataTable[Index].Function)
+ (
+ mMiscSubclassDataTable[Index].RecordType, &mMiscSubclassDataTable[Index].RecordLen, &RecordData.Record, &
+ LogRecordData
+ );
+
+ //
+ //
+ //
+ if (EFI_ERROR (EfiStatus)) {
+ break;
+ }
+
+ if (!LogRecordData) {
+ break;
+ }
+ //
+ //
+ //
+ EfiStatus = DataHub->LogData (
+ DataHub,
+ &gEfiMiscSubClassGuid,
+ &gEfiMiscSubClassGuid,
+ EFI_DATA_RECORD_CLASS_DATA,
+ &RecordData,
+ sizeof (EFI_SUBCLASS_TYPE1_HEADER) + mMiscSubclassDataTable[Index].RecordLen
+ );
+
+ if (EFI_ERROR (EfiStatus)) {
+ DEBUG (
+ (EFI_D_ERROR,
+ "LogData(%d bytes) == %r\n",
+ sizeof (EFI_SUBCLASS_TYPE1_HEADER) + mMiscSubclassDataTable[Index].RecordLen,
+ EfiStatus)
+ );
+ }
+ }
+ }
+ //
+ // Install notify function to fetch memory data through WinNtIo protocol and store to data hub.
+ //
+ EfiStatus = gBS->CreateEvent (
+ EVT_NOTIFY_SIGNAL,
+ TPL_CALLBACK,
+ WinNtIoProtocolNotifyFunction,
+ ImageHandle,
+ &Event
+ );
+ ASSERT (!EFI_ERROR (EfiStatus));
+
+ EfiStatus = gBS->RegisterProtocolNotify (
+ &gEfiWinNtIoProtocolGuid,
+ Event,
+ &Registration
+ );
+ ASSERT (!EFI_ERROR (EfiStatus));
+
+ return EFI_SUCCESS;
+}
+
+UINTN
+Atoi (
+ CHAR16 *String
+ )
+/*++
+
+Routine Description:
+ Convert a unicode string to a UINTN
+
+Arguments:
+ String - Unicode string.
+
+Returns:
+ UINTN of the number represented by String.
+
+--*/
+{
+ UINTN Number;
+ CHAR16 *Str;
+
+ //
+ // skip preceeding white space
+ //
+ Str = String;
+ while ((*Str) && (*Str == ' ' || *Str == '"')) {
+ Str++;
+ }
+ //
+ // Convert ot a Number
+ //
+ Number = 0;
+ while (*Str != '\0') {
+ if ((*Str >= '0') && (*Str <= '9')) {
+ Number = (Number * 10) +*Str - '0';
+ } else {
+ break;
+ }
+
+ Str++;
+ }
+
+ return Number;
+}
+
+VOID
+EFIAPI
+WinNtIoProtocolNotifyFunction (
+ IN EFI_EVENT Event,
+ IN VOID *Context
+ )
+/*++
+
+Routine Description:
+ This function will log memory size data to data hub.
+
+Arguments:
+Event - Event whose notification function is being invoked.
+Context - Pointer to the notification function's context.
+
+Returns:
+ EFI_STATUS.
+
+--*/
+{
+ EFI_STATUS Status;
+ EFI_MEMORY_SUBCLASS_DRIVER_DATA MemorySubClassData;
+ EFI_DATA_RECORD_HEADER *Record;
+ EFI_SUBCLASS_TYPE1_HEADER *DataHeader;
+ UINTN HandleCount;
+ UINTN HandleIndex;
+ UINT64 MonotonicCount;
+ BOOLEAN RecordFound;
+ EFI_HANDLE *HandleBuffer;
+ EFI_WIN_NT_IO_PROTOCOL *WinNtIo;
+ EFI_DATA_HUB_PROTOCOL *DataHub;
+ UINT64 TotalMemorySize;
+
+ DataHub = NULL;
+ MonotonicCount = 0;
+ RecordFound = FALSE;
+
+ //
+ // Retrieve the list of all handles from the handle database.
+ //
+ Status = gBS->LocateHandleBuffer (
+ AllHandles,
+ &gEfiWinNtIoProtocolGuid,
+ NULL,
+ &HandleCount,
+ &HandleBuffer
+ );
+ if (EFI_ERROR (Status)) {
+ return ;
+ }
+ //
+ // Locate DataHub protocol.
+ //
+ Status = gBS->LocateProtocol (&gEfiDataHubProtocolGuid, NULL, &DataHub);
+ if (EFI_ERROR (Status)) {
+ return ;
+ }
+ //
+ // Search the Handle array to find the meory size information.
+ //
+ for (HandleIndex = 0; HandleIndex < HandleCount; HandleIndex++) {
+ Status = gBS->OpenProtocol (
+ HandleBuffer[HandleIndex],
+ &gEfiWinNtIoProtocolGuid,
+ &WinNtIo,
+ Context,
+ NULL,
+ EFI_OPEN_PROTOCOL_GET_PROTOCOL
+ );
+ if (EFI_ERROR (Status)) {
+ continue;
+ }
+
+ if ((WinNtIo->WinNtThunk->Signature == EFI_WIN_NT_THUNK_PROTOCOL_SIGNATURE) &&
+ CompareGuid (WinNtIo->TypeGuid, &gEfiWinNtMemoryGuid)
+ ) {
+ //
+ // Check if this record has been stored in data hub.
+ //
+ do {
+ Status = DataHub->GetNextRecord (DataHub, &MonotonicCount, NULL, &Record);
+ if (Record->DataRecordClass == EFI_DATA_RECORD_CLASS_DATA) {
+ DataHeader = (EFI_SUBCLASS_TYPE1_HEADER *) (Record + 1);
+ if (CompareGuid (&Record->DataRecordGuid, &gEfiProcessorSubClassGuid) &&
+ (DataHeader->RecordType == EFI_MEMORY_ARRAY_START_ADDRESS_RECORD_NUMBER)
+ ) {
+ RecordFound = TRUE;
+ }
+ }
+ } while (MonotonicCount != 0);
+
+ if (RecordFound) {
+ RecordFound = FALSE;
+ continue;
+ }
+ //
+ // Initialize data record.
+ //
+ MemorySubClassData.Header.Instance = 1;
+ MemorySubClassData.Header.SubInstance = EFI_SUBCLASS_INSTANCE_NON_APPLICABLE;
+ MemorySubClassData.Header.RecordType = EFI_MEMORY_ARRAY_START_ADDRESS_RECORD_NUMBER;
+
+ TotalMemorySize = (UINT64) Atoi (WinNtIo->EnvString);
+
+ MemorySubClassData.Record.ArrayStartAddress.MemoryArrayStartAddress = 0;
+ MemorySubClassData.Record.ArrayStartAddress.MemoryArrayEndAddress = LShiftU64 (TotalMemorySize, 20) - 1;
+ MemorySubClassData.Record.ArrayStartAddress.PhysicalMemoryArrayLink.ProducerName = gEfiMemoryProducerGuid;
+ MemorySubClassData.Record.ArrayStartAddress.PhysicalMemoryArrayLink.Instance = 1;
+ MemorySubClassData.Record.ArrayStartAddress.PhysicalMemoryArrayLink.SubInstance = EFI_SUBCLASS_INSTANCE_NON_APPLICABLE;
+ MemorySubClassData.Record.ArrayStartAddress.MemoryArrayPartitionWidth = 0;
+
+ //
+ // Store memory size data record to data hub.
+ //
+ Status = DataHub->LogData (
+ DataHub,
+ &gEfiMemorySubClassGuid,
+ &gEfiMemoryProducerGuid,
+ EFI_DATA_RECORD_CLASS_DATA,
+ &MemorySubClassData,
+ sizeof (EFI_SUBCLASS_TYPE1_HEADER) + sizeof (EFI_MEMORY_ARRAY_START_ADDRESS_DATA)
+ );
+ }
+
+ gBS->CloseProtocol (
+ HandleBuffer[HandleIndex],
+ &gEfiWinNtIoProtocolGuid,
+ Context,
+ NULL
+ );
+ }
+}
+
diff --git a/Nt32Pkg/MiscSubClassPlatformDxe/MiscSystemLanguageString.uni b/Nt32Pkg/MiscSubClassPlatformDxe/MiscSystemLanguageString.uni
new file mode 100644
index 0000000000..c48a8b760a
--- /dev/null
+++ b/Nt32Pkg/MiscSubClassPlatformDxe/MiscSystemLanguageString.uni
Binary files differ
diff --git a/Nt32Pkg/MiscSubClassPlatformDxe/MiscSystemLanguageStringData.c b/Nt32Pkg/MiscSubClassPlatformDxe/MiscSystemLanguageStringData.c
new file mode 100644
index 0000000000..080c540c13
--- /dev/null
+++ b/Nt32Pkg/MiscSubClassPlatformDxe/MiscSystemLanguageStringData.c
@@ -0,0 +1,38 @@
+/*++
+
+Copyright (c) 2006, Intel Corporation
+All rights reserved. This program and the accompanying materials
+are licensed and made available under the terms and conditions of the BSD License
+which accompanies this distribution. The full text of the license may be found at
+http://opensource.org/licenses/bsd-license.php
+
+THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+
+Module Name:
+
+ MiscSystemLanguageStringData.c
+
+Abstract:
+
+ This driver parses the mMiscSubclassDataTable structure and reports
+ any generated data to the DataHub.
+
+--*/
+
+//
+// Include common header file for this module.
+//
+#include "CommonHeader.h"
+
+#include "MiscSubclassDriver.h"
+
+//
+// Static (possibly build generated) Bios Vendor data.
+//
+MISC_SUBCLASS_TABLE_DATA(EFI_MISC_SYSTEM_LANGUAGE_STRING_DATA, SystemLanguageString) = {
+ 0,
+ STRING_TOKEN(STR_MISC_SYSTEM_LANGUAGE_STRING)
+};
+
+/* eof - MiscSystemLanguageStringData.c */
diff --git a/Nt32Pkg/MiscSubClassPlatformDxe/MiscSystemManufacturer.uni b/Nt32Pkg/MiscSubClassPlatformDxe/MiscSystemManufacturer.uni
new file mode 100644
index 0000000000..2933b8a134
--- /dev/null
+++ b/Nt32Pkg/MiscSubClassPlatformDxe/MiscSystemManufacturer.uni
Binary files differ
diff --git a/Nt32Pkg/MiscSubClassPlatformDxe/MiscSystemManufacturerData.c b/Nt32Pkg/MiscSubClassPlatformDxe/MiscSystemManufacturerData.c
new file mode 100644
index 0000000000..dde795e88d
--- /dev/null
+++ b/Nt32Pkg/MiscSubClassPlatformDxe/MiscSystemManufacturerData.c
@@ -0,0 +1,60 @@
+/*++
+
+Copyright (c) 2006, Intel Corporation
+All rights reserved. This program and the accompanying materials
+are licensed and made available under the terms and conditions of the BSD License
+which accompanies this distribution. The full text of the license may be found at
+http://opensource.org/licenses/bsd-license.php
+
+THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+
+Module Name:
+
+ MiscSystemManufacturerData.c
+
+Abstract:
+
+ This driver parses the mMiscSubclassDataTable structure and reports
+ any generated data to the DataHub.
+
+--*/
+
+//
+// Include common header file for this module.
+//
+#include "CommonHeader.h"
+
+#include "MiscSubclassDriver.h"
+
+//
+// Static (possibly build generated) System Manufacturer data.
+//
+MISC_SUBCLASS_TABLE_DATA(EFI_MISC_SYSTEM_MANUFACTURER_DATA, MiscSystemManufacturer)
+= {
+ STRING_TOKEN(STR_MISC_SYSTEM_MANUFACTURER),
+ // SystemManufactrurer
+ STRING_TOKEN(STR_MISC_SYSTEM_PRODUCT_NAME),
+ // SystemProductName
+ STRING_TOKEN(STR_MISC_SYSTEM_VERSION),
+ // SystemVersion
+ STRING_TOKEN(STR_MISC_SYSTEM_SERIAL_NUMBER),
+ // SystemSerialNumber
+ {
+ 0xbadfaced,
+ 0xdead,
+ 0xbeef,
+ 0x13,
+ 0x13,
+ 0x13,
+ 0x13,
+ 0x13,
+ 0x13,
+ 0x13,
+ 0x13
+ },
+ // SystemUuid
+ EfiSystemWakeupTypePowerSwitch // SystemWakeupType
+};
+
+/* eof - MiscSystemManufacturerData.c */
diff --git a/Nt32Pkg/MiscSubClassPlatformDxe/MiscSystemManufacturerFunction.c b/Nt32Pkg/MiscSubClassPlatformDxe/MiscSystemManufacturerFunction.c
new file mode 100644
index 0000000000..aa428f1785
--- /dev/null
+++ b/Nt32Pkg/MiscSubClassPlatformDxe/MiscSystemManufacturerFunction.c
@@ -0,0 +1,127 @@
+/*++
+
+Copyright (c) 2006, Intel Corporation
+All rights reserved. This program and the accompanying materials
+are licensed and made available under the terms and conditions of the BSD License
+which accompanies this distribution. The full text of the license may be found at
+http://opensource.org/licenses/bsd-license.php
+
+THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+
+Module Name:
+
+ MiscSystemManufacturerFunction.c
+
+Abstract:
+
+ This driver parses the mMiscSubclassDataTable structure and reports
+ any generated data to the DataHub.
+
+--*/
+
+//
+// Include common header file for this module.
+//
+#include "CommonHeader.h"
+
+#include "MiscSubclassDriver.h"
+
+//
+//
+//
+MISC_SUBCLASS_TABLE_FUNCTION (
+ MiscSystemManufacturer
+ )
+/*++
+Description:
+
+ This function makes boot time changes to the contents of the
+ MiscSystemManufacturer (Type 13).
+
+Parameters:
+
+ RecordType
+ Type of record to be processed from the Data Table.
+ mMiscSubclassDataTable[].RecordType
+
+ RecordLen
+ Size of static RecordData from the Data Table.
+ mMiscSubclassDataTable[].RecordLen
+
+ RecordData
+ Pointer to copy of RecordData from the Data Table. Changes made
+ to this copy will be written to the Data Hub but will not alter
+ the contents of the static Data Table.
+
+ LogRecordData
+ Set *LogRecordData to TRUE to log RecordData to Data Hub.
+ Set *LogRecordData to FALSE when there is no more data to log.
+
+Returns:
+
+ EFI_SUCCESS
+ All parameters were valid and *RecordData and *LogRecordData have
+ been set.
+
+ EFI_UNSUPPORTED
+ Unexpected RecordType value.
+
+ EFI_INVALID_PARAMETER
+ One of the following parameter conditions was true:
+ RecordLen was zero.
+ RecordData was NULL.
+ LogRecordData was NULL.
+--*/
+{
+ STATIC BOOLEAN Done = FALSE;
+
+ //
+ // First check for invalid parameters.
+ //
+ if (*RecordLen == 0 || RecordData == NULL || LogRecordData == NULL) {
+ return EFI_INVALID_PARAMETER;
+ }
+ //
+ // Then check for unsupported RecordType.
+ //
+ if (RecordType != EFI_MISC_SYSTEM_MANUFACTURER_RECORD_NUMBER) {
+ return EFI_UNSUPPORTED;
+ }
+ //
+ // Is this the first time through this function?
+ //
+ if (!Done) {
+ //
+ // Yes, this is the first time. Inspect/Change the contents of the
+ // RecordData structure.
+ //
+ //
+ // Set system GUID.
+ //
+ // ((EFI_MISC_SYSTEM_MANUFACTURER_DATA *)RecordData)->SystemUuid = %%TBD
+ //
+ // Set power-on type.
+ //
+ // ((EFI_MISC_SYSTEM_MANUFACTURER_DATA *)RecordData)->SystemWakeupType = %%TBD
+ //
+ // Set Done flag to TRUE for next pass through this function.
+ // Set *LogRecordData to TRUE so data will get logged to Data Hub.
+ //
+ Done = TRUE;
+ *LogRecordData = TRUE;
+ } else {
+ //
+ // No, this is the second time. Reset the state of the Done flag
+ // to FALSE and tell the data logger that there is no more data
+ // to be logged for this record type. If any memory allocations
+ // were made by earlier passes, they must be released now.
+ //
+ Done = FALSE;
+ *LogRecordData = FALSE;
+ }
+
+ return EFI_SUCCESS;
+}
+
+/* eof - MiscSystemManufacturerFunction.c */
diff --git a/Nt32Pkg/MiscSubClassPlatformDxe/MiscSystemOptionString.uni b/Nt32Pkg/MiscSubClassPlatformDxe/MiscSystemOptionString.uni
new file mode 100644
index 0000000000..eec73f842f
--- /dev/null
+++ b/Nt32Pkg/MiscSubClassPlatformDxe/MiscSystemOptionString.uni
Binary files differ
diff --git a/Nt32Pkg/MiscSubClassPlatformDxe/MiscSystemOptionStringData.c b/Nt32Pkg/MiscSubClassPlatformDxe/MiscSystemOptionStringData.c
new file mode 100644
index 0000000000..20e55c33ff
--- /dev/null
+++ b/Nt32Pkg/MiscSubClassPlatformDxe/MiscSystemOptionStringData.c
@@ -0,0 +1,37 @@
+/*++
+
+Copyright (c) 2006, Intel Corporation
+All rights reserved. This program and the accompanying materials
+are licensed and made available under the terms and conditions of the BSD License
+which accompanies this distribution. The full text of the license may be found at
+http://opensource.org/licenses/bsd-license.php
+
+THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+
+Module Name:
+
+ MiscSystemOptionStringData.c
+
+Abstract:
+
+ This driver parses the mMiscSubclassDataTable structure and reports
+ any generated data to the DataHub.
+
+--*/
+
+//
+// Include common header file for this module.
+//
+#include "CommonHeader.h"
+
+#include "MiscSubclassDriver.h"
+
+//
+// Static (possibly build generated) Bios Vendor data.
+//
+MISC_SUBCLASS_TABLE_DATA(EFI_MISC_SYSTEM_OPTION_STRING_DATA, SystemOptionString) = {
+ STRING_TOKEN(STR_MISC_SYSTEM_OPTION_STRING)
+};
+
+/* eof - MiscSystemOptionStringData.c */
diff --git a/Nt32Pkg/MiscSubClassPlatformDxe/MiscSystemSlotDesignation.uni b/Nt32Pkg/MiscSubClassPlatformDxe/MiscSystemSlotDesignation.uni
new file mode 100644
index 0000000000..ac37d53670
--- /dev/null
+++ b/Nt32Pkg/MiscSubClassPlatformDxe/MiscSystemSlotDesignation.uni
Binary files differ
diff --git a/Nt32Pkg/MiscSubClassPlatformDxe/MiscSystemSlotDesignationData.c b/Nt32Pkg/MiscSubClassPlatformDxe/MiscSystemSlotDesignationData.c
new file mode 100644
index 0000000000..7610322c04
--- /dev/null
+++ b/Nt32Pkg/MiscSubClassPlatformDxe/MiscSystemSlotDesignationData.c
@@ -0,0 +1,57 @@
+/*++
+
+Copyright (c) 2006, Intel Corporation
+All rights reserved. This program and the accompanying materials
+are licensed and made available under the terms and conditions of the BSD License
+which accompanies this distribution. The full text of the license may be found at
+http://opensource.org/licenses/bsd-license.php
+
+THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+
+Module Name:
+
+ MiscSystemSlotDesignationData.c
+
+Abstract:
+
+ This driver parses the mMiscSubclassDataTable structure and reports
+ any generated data to the DataHub.
+
+--*/
+
+//
+// Include common header file for this module.
+//
+#include "CommonHeader.h"
+
+#include "MiscSubclassDriver.h"
+
+//
+// Static (possibly build generated) Bios Vendor data.
+//
+MISC_SUBCLASS_TABLE_DATA(EFI_MISC_SYSTEM_SLOT_DESIGNATION_DATA, MiscSystemSlotDesignation) = {
+ STRING_TOKEN(STR_MISC_SYSTEM_SLOT_DESIGNATION), // SlotDesignation
+ EfiSlotTypeOther, // SlotType
+ EfiSlotDataBusWidthOther, // SlotDataBusWidth
+ EfiSlotUsageOther, // SlotUsage
+ EfiSlotLengthOther, // SlotLength
+ 0, // SlotId
+ { // SlotCharacteristics
+ 0, // CharacteristicsUnknown :1;
+ 0, // Provides50Volts :1;
+ 0, // Provides33Volts :1;
+ 0, // SharedSlot :1;
+ 0, // PcCard16Supported :1;
+ 0, // CardBusSupported :1;
+ 0, // ZoomVideoSupported :1;
+ 0, // ModemRingResumeSupported:1;
+ 0, // PmeSignalSupported :1;
+ 0, // HotPlugDevicesSupported :1;
+ 0, // SmbusSignalSupported :1;
+ 0 // Reserved :21;
+ },
+ 0 // SlotDevicePath
+};
+
+/* eof - MiscSystemSlotsData.c */