+++ /dev/null
-/*++\r
-\r
-Copyright (c) 2004 - 2010, Intel Corporation. All rights reserved.<BR>\r
-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
- DataHubSubClassMemory.h\r
- \r
-Abstract:\r
-\r
- Definitions for memory sub class data records\r
-\r
-Revision History\r
-\r
---*/\r
-\r
-#ifndef _DATAHUB_SUBCLASS_MEMORY_H_\r
-#define _DATAHUB_SUBCLASS_MEMORY_H_\r
-\r
-#include EFI_GUID_DEFINITION (DataHubRecords)\r
-\r
-\r
-#define EFI_MEMORY_SUBCLASS_GUID \\r
- {0x4E8F4EBB, 0x64B9, 0x4e05, {0x9B, 0x18, 0x4C, 0xFE, 0x49, 0x23, 0x50, 0x97}}\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
- UINT32 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
- EfiMemoryTypeDdr3 = 0x18,\r
- EfiMemoryTypeFbd2 = 0x19\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,\r
- EfiMemoryStateUnsupported,\r
- EfiMemoryStateError,\r
- EfiMemoryStateAbsent,\r
- EfiMemoryStateDisabled,\r
- EfiMemoryStatePartial\r
-} EFI_MEMORY_STATE;\r
-\r
-typedef struct {\r
- EFI_STRING_TOKEN MemoryDeviceLocator;\r
- EFI_STRING_TOKEN MemoryBankLocator;\r
- EFI_STRING_TOKEN MemoryManufacturer;\r
- EFI_STRING_TOKEN MemorySerialNumber;\r
- EFI_STRING_TOKEN MemoryAssetTag;\r
- EFI_STRING_TOKEN MemoryPartNumber;\r
- EFI_INTER_LINK_DATA MemoryArrayLink;\r
- EFI_INTER_LINK_DATA MemorySubArrayLink;\r
- UINT16 MemoryTotalWidth;\r
- UINT16 MemoryDataWidth;\r
- UINT64 MemoryDeviceSize;\r
- EFI_MEMORY_FORM_FACTOR MemoryFormFactor;\r
- UINT8 MemoryDeviceSet;\r
- EFI_MEMORY_ARRAY_TYPE MemoryType;\r
- EFI_MEMORY_TYPE_DETAIL MemoryTypeDetail;\r
- UINT16 MemorySpeed;\r
- EFI_MEMORY_STATE MemoryState;\r
- UINT8 MemoryAttributes;\r
- UINT8 MemoryBankConnections;\r
- UINT8 MemoryErrorStatus;\r
-} EFI_MEMORY_ARRAY_LINK;\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;\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;\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
-// Memory. Controller Information - SMBIOS Type 5\r
-//\r
-#define EFI_MEMORY_CONTROLLER_INFORMATION_RECORD_NUMBER 0x00000008\r
-\r
-typedef enum { \r
- EfiErrorDetectingMethodOther = 1,\r
- EfiErrorDetectingMethodUnknown = 2,\r
- EfiErrorDetectingMethodNone = 3,\r
- EfiErrorDetectingMethodParity = 4,\r
- EfiErrorDetectingMethod32Ecc = 5,\r
- EfiErrorDetectingMethod64Ecc = 6,\r
- EfiErrorDetectingMethod128Ecc = 7,\r
- EfiErrorDetectingMethodCrc = 8\r
-} EFI_MEMORY_ERROR_DETECT_METHOD_TYPE;\r
-\r
-typedef struct {\r
- UINT8 Other :1;\r
- UINT8 Unknown :1;\r
- UINT8 None :1;\r
- UINT8 SingleBitErrorCorrect :1;\r
- UINT8 DoubleBitErrorCorrect :1;\r
- UINT8 ErrorScrubbing :1;\r
- UINT8 Reserved :2;\r
-} EFI_MEMORY_ERROR_CORRECT_CAPABILITY;\r
-\r
-typedef enum { \r
- EfiMemoryInterleaveOther = 1,\r
- EfiMemoryInterleaveUnknown = 2,\r
- EfiMemoryInterleaveOneWay = 3,\r
- EfiMemoryInterleaveTwoWay = 4,\r
- EfiMemoryInterleaveFourWay = 5,\r
- EfiMemoryInterleaveEightWay = 6,\r
- EfiMemoryInterleaveSixteenWay = 7\r
-} EFI_MEMORY_SUPPORT_INTERLEAVE_TYPE;\r
-\r
-typedef struct {\r
- UINT16 Other :1;\r
- UINT16 Unknown :1;\r
- UINT16 SeventyNs :1;\r
- UINT16 SixtyNs :1;\r
- UINT16 FiftyNs :1;\r
- UINT16 Reserved :11;\r
-} EFI_MEMORY_SPEED_TYPE;\r
-\r
-typedef struct {\r
- UINT16 Other :1;\r
- UINT16 Unknown :1;\r
- UINT16 Standard :1;\r
- UINT16 FastPageMode :1;\r
- UINT16 EDO :1;\r
- UINT16 Parity :1;\r
- UINT16 ECC :1;\r
- UINT16 SIMM :1;\r
- UINT16 DIMM :1;\r
- UINT16 BurstEdo :1;\r
- UINT16 SDRAM :1;\r
- UINT16 Reserved :5;\r
-} EFI_MEMORY_SUPPORTED_TYPE;\r
-\r
-typedef struct {\r
- UINT8 Five :1;\r
- UINT8 Three :1;\r
- UINT8 Two :1;\r
- UINT8 Reserved :5;\r
-} EFI_MEMORY_MODULE_VOLTAGE_TYPE;\r
-\r
-//\r
-// EFI_MEMORY_CONTROLLER_INFORMATION is obsolete\r
-// Use EFI_MEMORY_CONTROLLER_INFORMATION_DATA instead\r
-//\r
-typedef struct {\r
- EFI_MEMORY_ERROR_DETECT_METHOD_TYPE ErrorDetectingMethod;\r
- EFI_MEMORY_ERROR_CORRECT_CAPABILITY ErrorCorrectingCapability;\r
- EFI_MEMORY_SUPPORT_INTERLEAVE_TYPE MemorySupportedInterleave;\r
- EFI_MEMORY_SUPPORT_INTERLEAVE_TYPE MemoryCurrentInterleave;\r
- UINT8 MaxMemoryModuleSize;\r
- EFI_MEMORY_SPEED_TYPE MemorySpeedType;\r
- EFI_MEMORY_SUPPORTED_TYPE MemorySupportedType;\r
- EFI_MEMORY_MODULE_VOLTAGE_TYPE MemoryModuleVoltage;\r
- UINT8 NumberofMemorySlot;\r
- EFI_MEMORY_ERROR_CORRECT_CAPABILITY EnabledCorrectingCapability;\r
- UINT16 *MemoryModuleConfigHandles;\r
-} EFI_MEMORY_CONTROLLER_INFORMATION;\r
-\r
-typedef struct {\r
- EFI_MEMORY_ERROR_DETECT_METHOD_TYPE ErrorDetectingMethod;\r
- EFI_MEMORY_ERROR_CORRECT_CAPABILITY ErrorCorrectingCapability;\r
- EFI_MEMORY_SUPPORT_INTERLEAVE_TYPE MemorySupportedInterleave;\r
- EFI_MEMORY_SUPPORT_INTERLEAVE_TYPE MemoryCurrentInterleave;\r
- UINT8 MaxMemoryModuleSize;\r
- EFI_MEMORY_SPEED_TYPE MemorySpeedType;\r
- EFI_MEMORY_SUPPORTED_TYPE MemorySupportedType;\r
- EFI_MEMORY_MODULE_VOLTAGE_TYPE MemoryModuleVoltage;\r
- UINT8 NumberofMemorySlot;\r
- EFI_MEMORY_ERROR_CORRECT_CAPABILITY EnabledCorrectingCapability;\r
- EFI_INTER_LINK_DATA MemoryModuleConfig[1];\r
-} EFI_MEMORY_CONTROLLER_INFORMATION_DATA;\r
-\r
-//\r
-// Memory. Error Information - SMBIOS Type 18\r
-//\r
-#define EFI_MEMORY_32BIT_ERROR_INFORMATION_RECORD_NUMBER 0x00000009\r
-\r
-typedef enum { \r
- EfiMemoryErrorOther = 1,\r
- EfiMemoryErrorUnknown = 2,\r
- EfiMemoryErrorOk = 3,\r
- EfiMemoryErrorBadRead = 4,\r
- EfiMemoryErrorParity = 5,\r
- EfiMemoryErrorSigleBit = 6,\r
- EfiMemoryErrorDoubleBit = 7,\r
- EfiMemoryErrorMultiBit = 8,\r
- EfiMemoryErrorNibble = 9,\r
- EfiMemoryErrorChecksum = 10,\r
- EfiMemoryErrorCrc = 11,\r
- EfiMemoryErrorCorrectSingleBit = 12,\r
- EfiMemoryErrorCorrected = 13,\r
- EfiMemoryErrorUnCorrectable = 14\r
-} EFI_MEMORY_ERROR_TYPE;\r
-\r
-typedef enum { \r
- EfiMemoryGranularityOther = 1,\r
- EfiMemoryGranularityOtherUnknown = 2,\r
- EfiMemoryGranularityDeviceLevel = 3,\r
- EfiMemoryGranularityMemPartitionLevel = 4\r
-} EFI_MEMORY_ERROR_GRANULARITY_TYPE;\r
-\r
-typedef enum { \r
- EfiMemoryErrorOperationOther = 1,\r
- EfiMemoryErrorOperationUnknown = 2,\r
- EfiMemoryErrorOperationRead = 3,\r
- EfiMemoryErrorOperationWrite = 4,\r
- EfiMemoryErrorOperationPartialWrite = 5\r
-} EFI_MEMORY_ERROR_OPERATION_TYPE;\r
-\r
-typedef struct {\r
- EFI_MEMORY_ERROR_TYPE MemoryErrorType;\r
- EFI_MEMORY_ERROR_GRANULARITY_TYPE MemoryErrorGranularity;\r
- EFI_MEMORY_ERROR_OPERATION_TYPE MemoryErrorOperation;\r
- UINT32 VendorSyndrome;\r
- UINT32 MemoryArrayErrorAddress;\r
- UINT32 DeviceErrorAddress;\r
- UINT32 DeviceErrorResolution;\r
-} EFI_MEMORY_32BIT_ERROR_INFORMATION;\r
-\r
-//\r
-// Memory. Error Information - SMBIOS Type 33\r
-//\r
-#define EFI_MEMORY_64BIT_ERROR_INFORMATION_RECORD_NUMBER 0x0000000A\r
-\r
-typedef struct {\r
- EFI_MEMORY_ERROR_TYPE MemoryErrorType;\r
- EFI_MEMORY_ERROR_GRANULARITY_TYPE MemoryErrorGranularity;\r
- EFI_MEMORY_ERROR_OPERATION_TYPE MemoryErrorOperation;\r
- UINT32 VendorSyndrome;\r
- UINT64 MemoryArrayErrorAddress;\r
- UINT64 DeviceErrorAddress;\r
- UINT32 DeviceErrorResolution;\r
-} EFI_MEMORY_64BIT_ERROR_INFORMATION;\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 ArrayLink;\r
- EFI_MEMORY_ARRAY_START_ADDRESS ArrayStartAddress;\r
- EFI_MEMORY_DEVICE_START_ADDRESS DeviceStartAddress;\r
- EFI_MEMORY_CHANNEL_TYPE_DATA ChannelTypeData;\r
- EFI_MEMORY_CHANNEL_DEVICE_DATA ChannelDeviceData;\r
- EFI_MEMORY_CONTROLLER_INFORMATION MemoryControllerInfo;\r
- EFI_MEMORY_32BIT_ERROR_INFORMATION Memory32bitErrorInfo;\r
- EFI_MEMORY_64BIT_ERROR_INFORMATION Memory64bitErrorInfo;\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
-\r
-\r
-#endif\r