]>
git.proxmox.com Git - mirror_edk2.git/blob - ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/QueryTable.h
2 Build a table, each item is (key, info) pair.
3 and give a interface of query a string out of a table.
5 Copyright (c) 2005 - 2011, Intel Corporation. All rights reserved.<BR>
6 This program and the accompanying materials
7 are licensed and made available under the terms and conditions of the BSD License
8 which accompanies this distribution. The full text of the license may be found at
9 http://opensource.org/licenses/bsd-license.php
11 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
12 WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
16 #ifndef _SMBIOS_QUERY_TABLE_H
17 #define _SMBIOS_QUERY_TABLE_H
19 #define QUERY_TABLE_UNFOUND 0xFF
21 typedef struct TABLE_ITEM
{
27 // Print info by option
29 #define PRINT_INFO_OPTION(Value, Option) \
31 if (Option == SHOW_NONE) { \
34 if (Option < SHOW_DETAIL) { \
35 Print (L"0x%x\n", Value); \
41 Given a table and a Key, return the responding info.
44 Table[Index].Key is change from UINT8 to UINT16,
45 in order to deal with "0xaa - 0xbb".
48 DisplaySELVariableDataFormatTypes(UINT8 Type, UINT8 Option)
51 Now define Key = 0x7F07, that is to say: High = 0x7F, Low = 0x07.
52 Then all the Key Value between Low and High gets the same string
55 @param[in] Table The begin address of table.
56 @param[in] Number The number of table items.
57 @param[in] Key The query Key.
58 @param[in,out] Info Input as empty buffer; output as data buffer.
59 @param[in] InfoLen The max number of characters for Info.
61 @return the found Key and Info is valid.
62 @retval QUERY_TABLE_UNFOUND and Info should be NULL.
81 // Display the element detail information
84 DisplayStructureTypeInfo (
90 // System Information (Type 1)
93 DisplaySystemWakeupType (
99 // System Enclosure (Type 3)
102 DisplaySystemEnclosureType (
107 DisplaySystemEnclosureStatus (
112 DisplaySESecurityStatus (
118 // Processor Information (Type 4)
121 DisplayProcessorType (
126 DisplayProcessorUpgrade (
132 // Memory Controller Information (Type 5)
135 DisplayMcErrorDetectMethod (
140 DisplayMcErrorCorrectCapability (
145 DisplayMcInterleaveSupport (
150 DisplayMcMemorySpeeds (
155 DisplayMemoryModuleVoltage (
161 // Memory Module Information (Type 6)
164 DisplayMmMemoryType (
169 DisplayMmErrorStatus (
175 // Cache Information (Type 7)
178 DisplayCacheSRAMType (
183 DisplayCacheErrCorrectingType (
188 DisplayCacheSystemCacheType (
193 DisplayCacheAssociativity (
199 // Port Connector Information (Type 8)
202 DisplayPortConnectorType (
213 // System Slots (Type 9)
216 DisplaySystemSlotType (
221 DisplaySystemSlotDataBusWidth (
226 DisplaySystemSlotCurrentUsage (
231 DisplaySystemSlotLength (
236 DisplaySlotCharacteristics1 (
241 DisplaySlotCharacteristics2 (
247 // On Board Devices Information (Type 10)
250 DisplayOnboardDeviceTypes (
256 // System Event Log (Type 15)
264 DisplaySELVarDataFormatType (
269 DisplayPostResultsBitmapDw1 (
274 DisplayPostResultsBitmapDw2 (
279 DisplaySELSysManagementTypes (
285 // Physical Memory Array (Type 16)
298 DisplayPMAErrorCorrectionTypes (
304 // Memory Device (Type 17)
307 DisplayMemoryDeviceFormFactor (
312 DisplayMemoryDeviceType (
317 DisplayMemoryDeviceTypeDetail (
323 // 32-bit Memory Error Information (Type 18)
326 DisplayMemoryErrorType (
331 DisplayMemoryErrorGranularity (
336 DisplayMemoryErrorOperation (
342 // Memory Array Mapped Address (Type 19)
343 // Memory Device Mapped Address (Type 20)
345 // Built-in Pointing Device (Type 21)
348 DisplayPointingDeviceType (
353 DisplayPointingDeviceInterface (
359 // Portable Battery (Type 22)
362 DisplayPBDeviceChemistry (
368 // Voltage Probe (Type 26)
382 // Voltage Probe (Type 27)
385 DisplayCoolingDeviceStatus (
390 DisplayCoolingDeviceType (
396 // Temperature Probe (Type 28)
399 DisplayTemperatureProbeStatus (
404 DisplayTemperatureProbeLoc (
410 // Electrical Current Probe (Type 29)
424 // Management Device (Type 34)
432 DisplayMDAddressType (
438 // Memory Channel (Type 37)
441 DisplayMemoryChannelType (
447 // IPMI Device Information (Type 38)
450 DisplayIPMIDIBMCInterfaceType (