]> git.proxmox.com Git - mirror_edk2.git/blob - ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/SmbiosView.h
MdePkg,ShellPkg: Fix typo in SMBIOS_TABLE_TYPE4 field ProcessorManufacturer
[mirror_edk2.git] / ShellPkg / Library / UefiShellDebug1CommandsLib / SmbiosView / SmbiosView.h
1 /** @file
2 Tools of clarify the content of the smbios table.
3
4 Copyright (c) 2005 - 2015, Intel Corporation. All rights reserved.<BR>
5 SPDX-License-Identifier: BSD-2-Clause-Patent
6
7 **/
8
9 #ifndef _SMBIOS_VIEW_H_
10 #define _SMBIOS_VIEW_H_
11
12 #define STRUCTURE_TYPE_RANDOM (UINT8) 0xFE
13 #define STRUCTURE_TYPE_INVALID (UINT8) 0xFF
14
15 typedef struct {
16 UINT16 Index;
17 UINT8 Type;
18 UINT16 Handle;
19 UINT16 Addr; // offset from table head
20 UINT16 Length; // total structure length
21 } STRUCTURE_STATISTICS;
22
23 /**
24 Query all structures Data from SMBIOS table and Display
25 the information to users as required display option.
26
27 @param[in] QueryType Structure type to view.
28 @param[in] QueryHandle Structure handle to view.
29 @param[in] Option Display option: none,outline,normal,detail.
30 @param[in] RandomView Support for -h parameter.
31
32 @retval EFI_SUCCESS print is successful.
33 @retval EFI_BAD_BUFFER_SIZE structure is out of the range of SMBIOS table.
34 **/
35 EFI_STATUS
36 SMBiosView (
37 IN UINT8 QueryType,
38 IN UINT16 QueryHandle,
39 IN UINT8 Option,
40 IN BOOLEAN RandomView
41 );
42
43 /**
44 Query all structures Data from SMBIOS table and Display
45 the information to users as required display option.
46
47 @param[in] QueryType Structure type to view.
48 @param[in] QueryHandle Structure handle to view.
49 @param[in] Option Display option: none,outline,normal,detail.
50 @param[in] RandomView Support for -h parameter.
51
52 @retval EFI_SUCCESS print is successful.
53 @retval EFI_BAD_BUFFER_SIZE structure is out of the range of SMBIOS table.
54 **/
55 EFI_STATUS
56 SMBios64View (
57 IN UINT8 QueryType,
58 IN UINT16 QueryHandle,
59 IN UINT8 Option,
60 IN BOOLEAN RandomView
61 );
62
63 /**
64 Function to initialize the global mStatisticsTable object.
65
66 @retval EFI_SUCCESS print is successful.
67 **/
68 EFI_STATUS
69 InitSmbiosTableStatistics (
70 VOID
71 );
72
73 /**
74 Function to initialize the global mSmbios64BitStatisticsTable object.
75
76 @retval EFI_SUCCESS print is successful.
77 **/
78 EFI_STATUS
79 InitSmbios64BitTableStatistics (
80 VOID
81 );
82
83 /**
84 Function to display the global mStatisticsTable object.
85
86 @param[in] Option ECHO, NORMAL, or DETAIL control the amount of detail displayed.
87
88 @retval EFI_SUCCESS print is successful.
89 **/
90 EFI_STATUS
91 DisplayStatisticsTable (
92 IN UINT8 Option
93 );
94
95 /**
96 Function to display the global mSmbios64BitStatisticsTable object.
97
98 @param[in] Option ECHO, NORMAL, or DETAIL control the amount of detail displayed.
99
100 @retval EFI_SUCCESS print is successful.
101 **/
102 EFI_STATUS
103 DisplaySmbios64BitStatisticsTable (
104 IN UINT8 Option
105 );
106
107 /**
108 function to return a string of the detail level.
109
110 @param[in] ShowType The detail level whose name is desired in clear text.
111
112 @return A pointer to a string representing the ShowType (or 'undefined type' if not known).
113 **/
114 CHAR16*
115 GetShowTypeString (
116 UINT8 ShowType
117 );
118
119 extern UINT8 gShowType;
120
121 extern UINTN mSmbios64BitTableLength;
122
123 #endif