]>
Commit | Line | Data |
---|---|---|
b205f267 | 1 | /** @file\r |
2 | GUID used to identify id for the caller who is initiating the Status Code.\r | |
3 | \r | |
2b005f41 | 4 | Copyright (c) 2006 - 2019, Intel Corporation. All rights reserved.<BR>\r |
9344f092 | 5 | SPDX-License-Identifier: BSD-2-Clause-Patent\r |
b205f267 | 6 | \r |
7 | @par Revision Reference:\r | |
9095d37b | 8 | These GUIDs and structures are defined in UEFI Platform Initialization Specification 1.2\r |
b205f267 | 9 | Volume 3: Shared Architectural Elements\r |
10 | \r | |
11 | **/\r | |
12 | \r | |
13 | #ifndef __PI_STATUS_CODE_DATA_TYPE_ID_GUID_H__\r | |
14 | #define __PI_STATUS_CODE_DATA_TYPE_ID_GUID_H__\r | |
15 | \r | |
16 | #include <PiDxe.h>\r | |
17 | #include <Protocol/DebugSupport.h>\r | |
18 | \r | |
19 | ///\r | |
20 | /// Global ID for the EFI_STATUS_CODE_STRING structure\r | |
21 | ///\r | |
22 | #define EFI_STATUS_CODE_DATA_TYPE_STRING_GUID \\r | |
23 | { 0x92D11080, 0x496F, 0x4D95, { 0xBE, 0x7E, 0x03, 0x74, 0x88, 0x38, 0x2B, 0x0A } }\r | |
ad0ecbcf | 24 | \r |
b205f267 | 25 | typedef enum {\r |
26 | ///\r | |
27 | /// A NULL-terminated ASCII string.\r | |
28 | ///\r | |
29 | EfiStringAscii,\r | |
30 | ///\r | |
31 | /// A double NULL-terminated Unicode string.\r | |
32 | ///\r | |
33 | EfiStringUnicode,\r | |
34 | ///\r | |
9095d37b | 35 | /// An EFI_STATUS_CODE_STRING_TOKEN representing the string. The actual\r |
b205f267 | 36 | /// string can be obtained by querying the HII Database\r |
37 | ///\r | |
38 | EfiStringToken\r | |
39 | } EFI_STRING_TYPE;\r | |
9095d37b | 40 | \r |
b205f267 | 41 | ///\r |
42 | /// Specifies the format of the data in EFI_STATUS_CODE_STRING_DATA.String.\r | |
43 | ///\r | |
44 | typedef struct {\r | |
45 | ///\r | |
46 | /// The HII package list which contains the string. Handle is a dynamic value that may\r | |
47 | /// not be the same for different boots. Type EFI_HII_HANDLE is defined in\r | |
48 | /// EFI_HII_DATABASE_PROTOCOL.NewPackageList() in the UEFI Specification.\r | |
49 | ///\r | |
50 | EFI_HII_HANDLE Handle;\r | |
51 | ///\r | |
52 | /// When combined with Handle, the string token can be used to retrieve the string.\r | |
53 | /// Type EFI_STRING_ID is defined in EFI_IFR_OP_HEADER in the UEFI Specification.\r | |
54 | ///\r | |
55 | EFI_STRING_ID Token;\r | |
56 | } EFI_STATUS_CODE_STRING_TOKEN;\r | |
9095d37b | 57 | \r |
b205f267 | 58 | typedef union {\r |
59 | ///\r | |
60 | /// ASCII formatted string.\r | |
61 | ///\r | |
62 | CHAR8 *Ascii;\r | |
63 | ///\r | |
64 | /// Unicode formatted string.\r | |
65 | ///\r | |
66 | CHAR16 *Unicode;\r | |
67 | ///\r | |
68 | /// HII handle/token pair.\r | |
69 | ///\r | |
70 | EFI_STATUS_CODE_STRING_TOKEN Hii;\r | |
71 | } EFI_STATUS_CODE_STRING;\r | |
9095d37b | 72 | \r |
b205f267 | 73 | ///\r |
9095d37b LG |
74 | /// This data type defines a string type of extended data. A string can accompany\r |
75 | /// any status code. The string can provide additional information about the\r | |
76 | /// status code. The string can be ASCII, Unicode, or a Human Interface Infrastructure\r | |
b205f267 | 77 | /// (HII) token/GUID pair.\r |
78 | ///\r | |
79 | typedef struct {\r | |
80 | ///\r | |
81 | /// The data header identifying the data. DataHeader.HeaderSize should be\r | |
82 | /// sizeof (EFI_STATUS_CODE_DATA), DataHeader.Size should be\r | |
d1eff2f5 | 83 | /// sizeof (EFI_STATUS_CODE_STRING_DATA) - HeaderSize, and\r |
b205f267 | 84 | /// DataHeader.Type should be\r |
85 | /// EFI_STATUS_CODE_DATA_TYPE_STRING_GUID.\r | |
9095d37b LG |
86 | ///\r |
87 | EFI_STATUS_CODE_DATA DataHeader;\r | |
b205f267 | 88 | ///\r |
89 | /// Specifies the format of the data in String.\r | |
90 | ///\r | |
91 | EFI_STRING_TYPE StringType;\r | |
92 | ///\r | |
9095d37b | 93 | /// A pointer to the extended data. The data follows the format specified by\r |
b205f267 | 94 | /// StringType.\r |
95 | ///\r | |
96 | EFI_STATUS_CODE_STRING String;\r | |
97 | } EFI_STATUS_CODE_STRING_DATA;\r | |
98 | \r | |
b205f267 | 99 | extern EFI_GUID gEfiStatusCodeDataTypeStringGuid;\r |
100 | \r | |
101 | ///\r | |
102 | /// Global ID for the following structures:\r | |
103 | /// - EFI_DEVICE_PATH_EXTENDED_DATA\r | |
104 | /// - EFI_DEVICE_HANDLE_EXTENDED_DATA\r | |
105 | /// - EFI_RESOURCE_ALLOC_FAILURE_ERROR_DATA\r | |
106 | /// - EFI_COMPUTING_UNIT_VOLTAGE_ERROR_DATA\r | |
107 | /// - EFI_COMPUTING_UNIT_MICROCODE_UPDATE_ERROR_DATA\r | |
108 | /// - EFI_COMPUTING_UNIT_TIMER_EXPIRED_ERROR_DATA\r | |
109 | /// - EFI_HOST_PROCESSOR_MISMATCH_ERROR_DATA\r | |
110 | /// - EFI_MEMORY_RANGE_EXTENDED_DATA\r | |
111 | /// - EFI_DEBUG_ASSERT_DATA\r | |
112 | /// - EFI_STATUS_CODE_EXCEP_EXTENDED_DATA\r | |
113 | /// - EFI_STATUS_CODE_START_EXTENDED_DATA\r | |
114 | /// - EFI_LEGACY_OPROM_EXTENDED_DATA\r | |
2b005f41 | 115 | /// - EFI_RETURN_STATUS_EXTENDED_DATA\r |
b205f267 | 116 | ///\r |
117 | #define EFI_STATUS_CODE_SPECIFIC_DATA_GUID \\r | |
118 | { 0x335984bd, 0xe805, 0x409a, { 0xb8, 0xf8, 0xd2, 0x7e, 0xce, 0x5f, 0xf7, 0xa6 } }\r | |
119 | \r | |
b205f267 | 120 | ///\r |
9095d37b | 121 | /// Extended data about the device path, which is used for many errors and\r |
b205f267 | 122 | /// progress codes to point to the device.\r |
123 | ///\r | |
124 | /// The device path is used to point to the physical device in case there is more than one device\r | |
125 | /// belonging to the same subclass. For example, the system may contain two USB keyboards and one\r | |
126 | /// PS/2* keyboard. The driver that parses the status code can use the device path extended data to\r | |
127 | /// differentiate between the three. The index field is not useful in this case because there is no standard\r | |
128 | /// numbering convention. Device paths are preferred over using device handles because device handles\r | |
129 | /// for a given device can change from one boot to another and do not mean anything beyond Boot\r | |
130 | /// Services time. In certain cases, the bus driver may not create a device handle for a given device if it\r | |
131 | /// detects a critical error. In these cases, the device path extended data can be used to refer to the\r | |
132 | /// device, but there may not be any device handles with an instance of\r | |
133 | /// EFI_DEVICE_PATH_PROTOCOL that matches DevicePath. The variable device path structure\r | |
134 | /// is included in this structure to make it self sufficient.\r | |
135 | ///\r | |
136 | typedef struct {\r | |
137 | ///\r | |
138 | /// The data header identifying the data. DataHeader.HeaderSize should be\r | |
139 | /// sizeof (EFI_STATUS_CODE_DATA). DataHeader.Size should be the size\r | |
140 | /// of variable-length DevicePath, and DataHeader.Size is zero for a virtual\r | |
141 | /// device that does not have a device path. DataHeader.Type should be\r | |
142 | /// EFI_STATUS_CODE_SPECIFIC_DATA_GUID.\r | |
143 | ///\r | |
144 | EFI_STATUS_CODE_DATA DataHeader;\r | |
145 | ///\r | |
9095d37b | 146 | /// The device path to the controller or the hardware device. Note that this parameter is a\r |
6ce55357 SQ |
147 | /// variable-length device path structure and not a pointer to such a structure. This structure is\r |
148 | /// populated only if it is a physical device. For virtual devices, the Size field in DataHeader\r | |
149 | /// is set to zero and this field is not populated.\r | |
b205f267 | 150 | ///\r |
6ce55357 | 151 | // EFI_DEVICE_PATH_PROTOCOL DevicePath;\r |
b205f267 | 152 | } EFI_DEVICE_PATH_EXTENDED_DATA;\r |
153 | \r | |
154 | ///\r | |
155 | /// Device handle Extended Data. Used for many\r | |
156 | /// errors and progress codes to point to the device.\r | |
157 | ///\r | |
158 | /// The handle of the device with which the progress or error code is associated. The handle is\r | |
159 | /// guaranteed to be accurate only at the time the status code is reported. Handles are dynamic entities\r | |
160 | /// between boots, so handles cannot be considered to be valid if the system has reset subsequent to the\r | |
161 | /// status code being reported. Handles may be used to determine a wide variety of useful information\r | |
162 | /// about the source of the status code.\r | |
163 | ///\r | |
164 | typedef struct {\r | |
165 | ///\r | |
166 | /// The data header identifying the data. DataHeader.HeaderSize should be\r | |
167 | /// sizeof (EFI_STATUS_CODE_DATA), DataHeader.Size should be\r | |
168 | /// sizeof (EFI_DEVICE_HANDLE_EXTENDED_DATA) - HeaderSize, and\r | |
169 | /// DataHeader.Type should be EFI_STATUS_CODE_SPECIFIC_DATA_GUID.\r | |
170 | ///\r | |
171 | EFI_STATUS_CODE_DATA DataHeader;\r | |
172 | ///\r | |
173 | /// The device handle.\r | |
174 | ///\r | |
175 | EFI_HANDLE Handle;\r | |
176 | } EFI_DEVICE_HANDLE_EXTENDED_DATA;\r | |
177 | \r | |
178 | ///\r | |
179 | /// This structure defines extended data describing a PCI resource allocation error.\r | |
180 | ///\r | |
9095d37b | 181 | /// @par Note:\r |
b205f267 | 182 | /// The following structure contains variable-length fields and cannot be defined as a C-style\r |
183 | /// structure.\r | |
184 | ///\r | |
185 | /// This extended data conveys details for a PCI resource allocation failure error. See the PCI\r | |
186 | /// specification and the ACPI specification for details on PCI resource allocations and the format for\r | |
187 | /// resource descriptors. This error does not detail why the resource allocation failed. It may be due to a\r | |
188 | /// bad resource request or a lack of available resources to satisfy a valid request. The variable device\r | |
189 | /// path structure and the resource structures are included in this structure to make it self sufficient.\r | |
190 | ///\r | |
191 | typedef struct {\r | |
192 | ///\r | |
193 | /// The data header identifying the data. DataHeader.HeaderSize should be sizeof\r | |
194 | /// (EFI_STATUS_CODE_DATA), DataHeader.Size should be\r | |
195 | /// (DevicePathSize + DevicePathSize + DevicePathSize +\r | |
196 | /// sizeof(UINT32) + 3 * sizeof (UINT16) ), and DataHeader.Type\r | |
197 | /// should be EFI_STATUS_CODE_SPECIFIC_DATA_GUID.\r | |
198 | ///\r | |
199 | EFI_STATUS_CODE_DATA DataHeader;\r | |
200 | ///\r | |
201 | /// The PCI BAR. Applicable only for PCI devices. Ignored for all other devices.\r | |
202 | ///\r | |
203 | UINT32 Bar;\r | |
204 | ///\r | |
205 | /// DevicePathSize should be zero if it is a virtual device that is not associated with\r | |
206 | /// a device path. Otherwise, this parameter is the length of the variable-length\r | |
9095d37b | 207 | /// DevicePath.\r |
b205f267 | 208 | ///\r |
209 | UINT16 DevicePathSize;\r | |
210 | ///\r | |
211 | /// Represents the size the ReqRes parameter. ReqResSize should be zero if the\r | |
212 | /// requested resources are not provided as a part of extended data.\r | |
213 | ///\r | |
214 | UINT16 ReqResSize;\r | |
215 | ///\r | |
216 | /// Represents the size the AllocRes parameter. AllocResSize should be zero if the\r | |
217 | /// allocated resources are not provided as a part of extended data.\r | |
218 | ///\r | |
219 | UINT16 AllocResSize;\r | |
220 | ///\r | |
9095d37b LG |
221 | /// The device path to the controller or the hardware device that did not get the requested\r |
222 | /// resources. Note that this parameter is the variable-length device path structure and not\r | |
223 | /// a pointer to this structure.\r | |
b205f267 | 224 | ///\r |
6ce55357 | 225 | // EFI_DEVICE_PATH_PROTOCOL DevicePath;\r |
b205f267 | 226 | ///\r |
227 | /// The requested resources in the format of an ACPI 2.0 resource descriptor. This\r | |
228 | /// parameter is not a pointer; it is the complete resource descriptor.\r | |
229 | ///\r | |
cb1366a8 | 230 | // UINT8 ReqRes[];\r |
b205f267 | 231 | ///\r |
9095d37b | 232 | /// The allocated resources in the format of an ACPI 2.0 resource descriptor. This\r |
b205f267 | 233 | /// parameter is not a pointer; it is the complete resource descriptor.\r |
234 | ///\r | |
cb1366a8 | 235 | // UINT8 AllocRes[];\r |
b205f267 | 236 | } EFI_RESOURCE_ALLOC_FAILURE_ERROR_DATA;\r |
237 | \r | |
238 | ///\r | |
239 | /// This structure provides a calculation for base-10 representations.\r | |
240 | ///\r | |
241 | /// Not consistent with PI 1.2 Specification.\r | |
9095d37b | 242 | /// This data type is not defined in the PI 1.2 Specification, but is\r |
b205f267 | 243 | /// required by several of the other data structures in this file.\r |
244 | ///\r | |
245 | typedef struct {\r | |
246 | ///\r | |
247 | /// The INT16 number by which to multiply the base-2 representation.\r | |
248 | ///\r | |
249 | INT16 Value;\r | |
250 | ///\r | |
9095d37b | 251 | /// The INT16 number by which to raise the base-2 calculation.\r |
b205f267 | 252 | ///\r |
253 | INT16 Exponent;\r | |
254 | } EFI_EXP_BASE10_DATA;\r | |
255 | \r | |
256 | ///\r | |
9095d37b LG |
257 | /// This structure provides the voltage at the time of error. It also provides\r |
258 | /// the threshold value indicating the minimum or maximum voltage that is considered\r | |
259 | /// an error. If the voltage is less then the threshold, the error indicates that the\r | |
260 | /// voltage fell below the minimum acceptable value. If the voltage is greater then the threshold,\r | |
b205f267 | 261 | /// the error indicates that the voltage rose above the maximum acceptable value.\r |
262 | ///\r | |
263 | typedef struct {\r | |
264 | ///\r | |
265 | /// The data header identifying the data. DataHeader.HeaderSize should be\r | |
266 | /// sizeof (EFI_STATUS_CODE_DATA), DataHeader.Size should be\r | |
267 | /// sizeof (EFI_COMPUTING_UNIT_VOLTAGE_ERROR_DATA) -\r | |
268 | /// HeaderSize, and DataHeader.Type should be\r | |
269 | /// EFI_STATUS_CODE_SPECIFIC_DATA_GUID.\r | |
270 | ///\r | |
271 | EFI_STATUS_CODE_DATA DataHeader;\r | |
272 | ///\r | |
273 | /// The voltage value at the time of the error.\r | |
274 | ///\r | |
275 | EFI_EXP_BASE10_DATA Voltage;\r | |
276 | ///\r | |
277 | /// The voltage threshold.\r | |
278 | ///\r | |
279 | EFI_EXP_BASE10_DATA Threshold;\r | |
280 | } EFI_COMPUTING_UNIT_VOLTAGE_ERROR_DATA;\r | |
281 | \r | |
282 | ///\r | |
283 | /// Microcode Update Extended Error Data\r | |
284 | ///\r | |
285 | typedef struct {\r | |
286 | ///\r | |
287 | /// The data header identifying the data. DataHeader.HeaderSize should be\r | |
288 | /// sizeof (EFI_STATUS_CODE_DATA), DataHeader.Size should be\r | |
289 | /// sizeof (EFI_COMPUTING_UNIT_MICROCODE_UPDATE_ERROR_DATA) -\r | |
290 | /// HeaderSize, and DataHeader.Type should be\r | |
291 | /// EFI_STATUS_CODE_SPECIFIC_DATA_GUID.\r | |
292 | ///\r | |
293 | EFI_STATUS_CODE_DATA DataHeader;\r | |
294 | ///\r | |
295 | /// The version of the microcode update from the header.\r | |
296 | ///\r | |
297 | UINT32 Version;\r | |
298 | } EFI_COMPUTING_UNIT_MICROCODE_UPDATE_ERROR_DATA;\r | |
299 | \r | |
300 | ///\r | |
301 | /// This structure provides details about the computing unit timer expiration error.\r | |
302 | /// The timer limit provides the timeout value of the timer prior to expiration.\r | |
303 | ///\r | |
304 | typedef struct {\r | |
305 | ///\r | |
306 | /// The data header identifying the data. DataHeader.HeaderSize should be\r | |
307 | /// sizeof (EFI_STATUS_CODE_DATA), DataHeader.Size should be\r | |
308 | /// sizeof (EFI_COMPUTING_UNIT_TIMER_EXPIRED_ERROR_DATA) -\r | |
309 | /// HeaderSize, and DataHeader.Type should be\r | |
9095d37b | 310 | /// EFI_STATUS_CODE_SPECIFIC_DATA_GUID.\r |
b205f267 | 311 | ///\r |
312 | EFI_STATUS_CODE_DATA DataHeader;\r | |
313 | ///\r | |
314 | /// The number of seconds that the computing unit timer was configured to expire.\r | |
315 | ///\r | |
316 | EFI_EXP_BASE10_DATA TimerLimit;\r | |
317 | } EFI_COMPUTING_UNIT_TIMER_EXPIRED_ERROR_DATA;\r | |
318 | \r | |
319 | ///\r | |
320 | /// Attribute bits for EFI_HOST_PROCESSOR_MISMATCH_ERROR_DATA.Attributes\r | |
321 | /// All other attributes are reserved for future use and must be initialized to 0.\r | |
322 | ///\r | |
323 | ///@{\r | |
324 | #define EFI_COMPUTING_UNIT_MISMATCH_SPEED 0x0001\r | |
325 | #define EFI_COMPUTING_UNIT_MISMATCH_FSB_SPEED 0x0002\r | |
326 | #define EFI_COMPUTING_UNIT_MISMATCH_FAMILY 0x0004\r | |
327 | #define EFI_COMPUTING_UNIT_MISMATCH_MODEL 0x0008\r | |
328 | #define EFI_COMPUTING_UNIT_MISMATCH_STEPPING 0x0010\r | |
329 | #define EFI_COMPUTING_UNIT_MISMATCH_CACHE_SIZE 0x0020\r | |
330 | #define EFI_COMPUTING_UNIT_MISMATCH_OEM1 0x1000\r | |
331 | #define EFI_COMPUTING_UNIT_MISMATCH_OEM2 0x2000\r | |
332 | #define EFI_COMPUTING_UNIT_MISMATCH_OEM3 0x4000\r | |
333 | #define EFI_COMPUTING_UNIT_MISMATCH_OEM4 0x8000\r | |
334 | ///@}\r | |
335 | \r | |
336 | ///\r | |
337 | /// This structure defines extended data for processor mismatch errors.\r | |
338 | ///\r | |
9095d37b LG |
339 | /// This provides information to indicate which processors mismatch, and how they mismatch. The\r |
340 | /// status code contains the instance number of the processor that is in error. This structure's\r | |
341 | /// Instance indicates the second processor that does not match. This differentiation allows the\r | |
342 | /// consumer to determine which two processors do not match. The Attributes indicate what\r | |
343 | /// mismatch is being reported. Because Attributes is a bit field, more than one mismatch can be\r | |
b205f267 | 344 | /// reported with one error code.\r |
345 | ///\r | |
346 | typedef struct {\r | |
347 | ///\r | |
348 | /// The data header identifying the data. DataHeader.HeaderSize should be\r | |
349 | /// sizeof (EFI_STATUS_CODE_DATA), DataHeader.Size should be\r | |
350 | /// sizeof (EFI_ HOST_PROCESSOR_MISMATCH_ERROR_DATA) -\r | |
351 | /// HeaderSize , and DataHeader.Type should be\r | |
9095d37b | 352 | /// EFI_STATUS_CODE_SPECIFIC_DATA_GUID.\r |
b205f267 | 353 | ///\r |
354 | EFI_STATUS_CODE_DATA DataHeader;\r | |
355 | ///\r | |
356 | /// The unit number of the computing unit that does not match.\r | |
9095d37b | 357 | ///\r |
b205f267 | 358 | UINT32 Instance;\r |
9095d37b LG |
359 | ///\r |
360 | /// The attributes describing the failure.\r | |
361 | ///\r | |
b205f267 | 362 | UINT16 Attributes;\r |
363 | } EFI_HOST_PROCESSOR_MISMATCH_ERROR_DATA;\r | |
364 | \r | |
365 | ///\r | |
366 | /// This structure provides details about the computing unit thermal failure.\r | |
367 | ///\r | |
9095d37b | 368 | /// This structure provides the temperature at the time of error. It also provides the threshold value\r |
b205f267 | 369 | /// indicating the minimum temperature that is considered an error.\r |
370 | ///\r | |
371 | typedef struct {\r | |
372 | ///\r | |
373 | /// The data header identifying the data. DataHeader.HeaderSize should be\r | |
374 | /// sizeof (EFI_STATUS_CODE_DATA), DataHeader.Size should be\r | |
375 | /// sizeof (EFI_COMPUTING_UNIT_THERMAL_ERROR_DATA) -\r | |
376 | /// HeaderSize , and DataHeader.Type should be\r | |
9095d37b | 377 | /// EFI_STATUS_CODE_SPECIFIC_DATA_GUID.\r |
b205f267 | 378 | ///\r |
379 | EFI_STATUS_CODE_DATA DataHeader;\r | |
380 | ///\r | |
381 | /// The thermal value at the time of the error.\r | |
382 | ///\r | |
383 | EFI_EXP_BASE10_DATA Temperature;\r | |
384 | ///\r | |
385 | /// The thermal threshold.\r | |
386 | ///\r | |
387 | EFI_EXP_BASE10_DATA Threshold;\r | |
388 | } EFI_COMPUTING_UNIT_THERMAL_ERROR_DATA;\r | |
389 | \r | |
390 | ///\r | |
391 | /// Enumeration of valid cache types\r | |
392 | ///\r | |
393 | typedef enum {\r | |
394 | EfiInitCacheDataOnly,\r | |
395 | EfiInitCacheInstrOnly,\r | |
396 | EfiInitCacheBoth,\r | |
397 | EfiInitCacheUnspecified\r | |
398 | } EFI_INIT_CACHE_TYPE;\r | |
399 | \r | |
400 | ///\r | |
401 | /// Embedded cache init extended data\r | |
402 | ///\r | |
403 | typedef struct {\r | |
404 | ///\r | |
405 | /// The data header identifying the data. DataHeader.HeaderSize should be\r | |
406 | /// sizeof (EFI_STATUS_CODE_DATA), DataHeader.Size should be\r | |
407 | /// sizeof (EFI_CACHE_INIT_DATA) - HeaderSize , and\r | |
408 | /// DataHeader.Type should be EFI_STATUS_CODE_SPECIFIC_DATA_GUID.\r | |
409 | ///\r | |
410 | EFI_STATUS_CODE_DATA DataHeader;\r | |
411 | ///\r | |
412 | /// The cache level. Starts with 1 for level 1 cache.\r | |
413 | ///\r | |
414 | UINT32 Level;\r | |
415 | ///\r | |
416 | /// The type of cache.\r | |
417 | ///\r | |
418 | EFI_INIT_CACHE_TYPE Type;\r | |
419 | } EFI_CACHE_INIT_DATA;\r | |
420 | \r | |
421 | ///\r | |
422 | ///\r | |
423 | ///\r | |
424 | typedef UINT32 EFI_CPU_STATE_CHANGE_CAUSE;\r | |
425 | \r | |
426 | ///\r | |
9095d37b | 427 | /// The reasons that the processor is disabled.\r |
b205f267 | 428 | /// Used to fill in EFI_COMPUTING_UNIT_CPU_DISABLED_ERROR_DATA.Cause.\r |
429 | ///\r | |
430 | ///@{\r | |
431 | #define EFI_CPU_CAUSE_INTERNAL_ERROR 0x0001\r | |
432 | #define EFI_CPU_CAUSE_THERMAL_ERROR 0x0002\r | |
433 | #define EFI_CPU_CAUSE_SELFTEST_FAILURE 0x0004\r | |
434 | #define EFI_CPU_CAUSE_PREBOOT_TIMEOUT 0x0008\r | |
435 | #define EFI_CPU_CAUSE_FAILED_TO_START 0x0010\r | |
436 | #define EFI_CPU_CAUSE_CONFIG_ERROR 0x0020\r | |
437 | #define EFI_CPU_CAUSE_USER_SELECTION 0x0080\r | |
438 | #define EFI_CPU_CAUSE_BY_ASSOCIATION 0x0100\r | |
439 | #define EFI_CPU_CAUSE_UNSPECIFIED 0x8000\r | |
440 | ///@}\r | |
441 | \r | |
442 | ///\r | |
443 | /// This structure provides information about the disabled computing unit.\r | |
444 | ///\r | |
9095d37b LG |
445 | /// This structure provides details as to why and how the computing unit was disabled. The causes\r |
446 | /// should cover the typical reasons a processor would be disabled. How the processor was disabled is\r | |
b205f267 | 447 | /// important because there are distinct differences between hardware and software disabling.\r |
448 | ///\r | |
449 | typedef struct {\r | |
450 | ///\r | |
451 | /// The data header identifying the data. DataHeader.HeaderSize should be\r | |
452 | /// sizeof (EFI_STATUS_CODE_DATA), DataHeader.Size should be\r | |
453 | /// sizeof (EFI_COMPUTING_UNIT_CPU_DISABLED_ERROR_DATA) -\r | |
454 | /// HeaderSize, and DataHeader.Type should be\r | |
455 | /// EFI_STATUS_CODE_SPECIFIC_DATA_GUID.\r | |
456 | ///\r | |
457 | EFI_STATUS_CODE_DATA DataHeader;\r | |
458 | ///\r | |
9095d37b LG |
459 | /// The reason for disabling the processor.\r |
460 | ///\r | |
b205f267 | 461 | UINT32 Cause;\r |
462 | ///\r | |
9095d37b LG |
463 | /// TRUE if the processor is disabled via software means such as not listing it in the ACPI tables.\r |
464 | /// Such a processor will respond to Interprocessor Interrupts (IPIs). FALSE if the processor is hardware\r | |
b205f267 | 465 | /// disabled, which means it is invisible to software and will not respond to IPIs.\r |
466 | ///\r | |
467 | BOOLEAN SoftwareDisabled;\r | |
468 | } EFI_COMPUTING_UNIT_CPU_DISABLED_ERROR_DATA;\r | |
469 | \r | |
470 | ///\r | |
471 | /// Memory Error Granularity Definition\r | |
472 | ///\r | |
473 | typedef UINT8 EFI_MEMORY_ERROR_GRANULARITY;\r | |
474 | \r | |
475 | ///\r | |
476 | /// Memory Error Granularities. Used to fill in EFI_MEMORY_EXTENDED_ERROR_DATA.Granularity.\r | |
477 | ///\r | |
478 | ///@{\r | |
479 | #define EFI_MEMORY_ERROR_OTHER 0x01\r | |
480 | #define EFI_MEMORY_ERROR_UNKNOWN 0x02\r | |
481 | #define EFI_MEMORY_ERROR_DEVICE 0x03\r | |
482 | #define EFI_MEMORY_ERROR_PARTITION 0x04\r | |
483 | ///@}\r | |
484 | \r | |
485 | ///\r | |
486 | /// Memory Error Operation Definition\r | |
487 | ///\r | |
488 | typedef UINT8 EFI_MEMORY_ERROR_OPERATION;\r | |
489 | \r | |
490 | ///\r | |
491 | /// Memory Error Operations. Used to fill in EFI_MEMORY_EXTENDED_ERROR_DATA.Operation.\r | |
492 | ///\r | |
493 | ///@{\r | |
494 | #define EFI_MEMORY_OPERATION_OTHER 0x01\r | |
495 | #define EFI_MEMORY_OPERATION_UNKNOWN 0x02\r | |
496 | #define EFI_MEMORY_OPERATION_READ 0x03\r | |
497 | #define EFI_MEMORY_OPERATION_WRITE 0x04\r | |
498 | #define EFI_MEMORY_OPERATION_PARTIAL_WRITE 0x05\r | |
499 | ///@}\r | |
500 | \r | |
501 | ///\r | |
9095d37b LG |
502 | /// This structure provides specific details about the memory error that was detected. It provides\r |
503 | /// enough information so that consumers can identify the exact failure and provides enough\r | |
b205f267 | 504 | /// information to enable corrective action if necessary.\r |
505 | ///\r | |
506 | typedef struct {\r | |
507 | ///\r | |
508 | /// The data header identifying the data. DataHeader.HeaderSize should be\r | |
509 | /// sizeof (EFI_STATUS_CODE_DATA), DataHeader.Size should be\r | |
510 | /// sizeof (EFI_MEMORY_EXTENDED_ERROR_DATA) - HeaderSize, and\r | |
9095d37b | 511 | /// DataHeader.Type should be EFI_STATUS_CODE_SPECIFIC_DATA_GUID.\r |
b205f267 | 512 | ///\r |
513 | EFI_STATUS_CODE_DATA DataHeader;\r | |
514 | ///\r | |
515 | /// The error granularity type.\r | |
516 | ///\r | |
517 | EFI_MEMORY_ERROR_GRANULARITY Granularity;\r | |
518 | ///\r | |
9095d37b | 519 | /// The operation that resulted in the error being detected.\r |
b205f267 | 520 | ///\r |
521 | EFI_MEMORY_ERROR_OPERATION Operation;\r | |
522 | ///\r | |
9095d37b | 523 | /// The error syndrome, vendor-specific ECC syndrome, or CRC data associated with\r |
b205f267 | 524 | /// the error. If unknown, should be initialized to 0.\r |
9095d37b | 525 | /// Inconsistent with specification here:\r |
b205f267 | 526 | /// This field in StatusCodes spec0.9 is defined as UINT32, keep code unchanged.\r |
527 | ///\r | |
528 | UINTN Syndrome;\r | |
529 | ///\r | |
9095d37b | 530 | /// The physical address of the error.\r |
b205f267 | 531 | ///\r |
532 | EFI_PHYSICAL_ADDRESS Address;\r | |
533 | ///\r | |
534 | /// The range, in bytes, within which the error address can be determined.\r | |
535 | ///\r | |
536 | UINTN Resolution;\r | |
537 | } EFI_MEMORY_EXTENDED_ERROR_DATA;\r | |
538 | \r | |
539 | ///\r | |
540 | /// A definition to describe that the operation is performed on multiple devices within the array.\r | |
9095d37b | 541 | /// May be used for EFI_STATUS_CODE_DIMM_NUMBER.Array and EFI_STATUS_CODE_DIMM_NUMBER.Device.\r |
b205f267 | 542 | ///\r |
543 | #define EFI_MULTIPLE_MEMORY_DEVICE_OPERATION 0xfffe\r | |
544 | \r | |
545 | ///\r | |
546 | /// A definition to describe that the operation is performed on all devices within the array.\r | |
9095d37b | 547 | /// May be used for EFI_STATUS_CODE_DIMM_NUMBER.Array and EFI_STATUS_CODE_DIMM_NUMBER.Device.\r |
b205f267 | 548 | ///\r |
549 | #define EFI_ALL_MEMORY_DEVICE_OPERATION 0xffff\r | |
550 | \r | |
551 | ///\r | |
552 | /// A definition to describe that the operation is performed on multiple arrays.\r | |
9095d37b | 553 | /// May be used for EFI_STATUS_CODE_DIMM_NUMBER.Array and EFI_STATUS_CODE_DIMM_NUMBER.Device.\r |
b205f267 | 554 | ///\r |
555 | #define EFI_MULTIPLE_MEMORY_ARRAY_OPERATION 0xfffe\r | |
556 | \r | |
557 | ///\r | |
558 | /// A definition to describe that the operation is performed on all the arrays.\r | |
9095d37b | 559 | /// May be used for EFI_STATUS_CODE_DIMM_NUMBER.Array and EFI_STATUS_CODE_DIMM_NUMBER.Device.\r |
b205f267 | 560 | ///\r |
561 | #define EFI_ALL_MEMORY_ARRAY_OPERATION 0xffff\r | |
562 | \r | |
563 | ///\r | |
9095d37b LG |
564 | /// This extended data provides some context that consumers can use to locate a DIMM within the\r |
565 | /// overall memory scheme.\r | |
b205f267 | 566 | ///\r |
567 | /// This extended data provides some context that consumers can use to locate a DIMM within the\r | |
568 | /// overall memory scheme. The Array and Device numbers may indicate a specific DIMM, or they\r | |
569 | /// may be populated with the group definitions in "Related Definitions" below.\r | |
570 | ///\r | |
571 | typedef struct {\r | |
572 | ///\r | |
573 | /// The data header identifying the data. DataHeader.HeaderSize should be\r | |
574 | /// sizeof (EFI_STATUS_CODE_DATA), DataHeader.Size should be\r | |
575 | /// sizeof (EFI_STATUS_CODE_DIMM_NUMBER) - HeaderSize, and\r | |
576 | /// DataHeader.Type should be EFI_STATUS_CODE_SPECIFIC_DATA_GUID.\r | |
577 | ///\r | |
578 | EFI_STATUS_CODE_DATA DataHeader;\r | |
579 | ///\r | |
580 | /// The memory array number.\r | |
581 | ///\r | |
582 | UINT16 Array;\r | |
583 | ///\r | |
584 | /// The device number within that Array.\r | |
585 | ///\r | |
586 | UINT16 Device;\r | |
587 | } EFI_STATUS_CODE_DIMM_NUMBER;\r | |
588 | \r | |
589 | ///\r | |
590 | /// This structure defines extended data describing memory modules that do not match.\r | |
591 | ///\r | |
592 | /// This extended data may be used to convey the specifics of memory modules that do not match.\r | |
9095d37b | 593 | ///\r |
b205f267 | 594 | typedef struct {\r |
595 | ///\r | |
596 | /// The data header identifying the data. DataHeader.HeaderSize should be\r | |
597 | /// sizeof (EFI_STATUS_CODE_DATA), DataHeader.Size should be\r | |
598 | /// sizeof (EFI_MEMORY_MODULE_MISMATCH_ERROR_DATA) -\r | |
599 | /// HeaderSize, and DataHeader.Type should be\r | |
600 | /// EFI_STATUS_CODE_SPECIFIC_DATA_GUID.\r | |
601 | ///\r | |
602 | EFI_STATUS_CODE_DATA DataHeader;\r | |
603 | ///\r | |
9095d37b | 604 | /// The instance number of the memory module that does not match.\r |
b205f267 | 605 | ///\r |
606 | EFI_STATUS_CODE_DIMM_NUMBER Instance;\r | |
607 | } EFI_MEMORY_MODULE_MISMATCH_ERROR_DATA;\r | |
608 | \r | |
609 | ///\r | |
610 | /// This structure defines extended data describing a memory range.\r | |
611 | ///\r | |
9095d37b | 612 | /// This extended data may be used to convey the specifics of a memory range. Ranges are specified\r |
b205f267 | 613 | /// with a start address and a length.\r |
614 | ///\r | |
615 | typedef struct {\r | |
616 | ///\r | |
617 | /// The data header identifying the data. DataHeader.HeaderSize should be\r | |
618 | /// sizeof (EFI_STATUS_CODE_DATA), DataHeader.Size should be\r | |
619 | /// sizeof (EFI_MEMORY_RANGE_EXTENDED_DATA) - HeaderSize, and\r | |
9095d37b | 620 | /// DataHeader.Type should be EFI_STATUS_CODE_SPECIFIC_DATA_GUID.\r |
b205f267 | 621 | ///\r |
622 | EFI_STATUS_CODE_DATA DataHeader;\r | |
623 | ///\r | |
9095d37b | 624 | /// The starting address of the memory range.\r |
b205f267 | 625 | ///\r |
626 | EFI_PHYSICAL_ADDRESS Start;\r | |
627 | ///\r | |
628 | /// The length in bytes of the memory range.\r | |
629 | ///\r | |
630 | EFI_PHYSICAL_ADDRESS Length;\r | |
631 | } EFI_MEMORY_RANGE_EXTENDED_DATA;\r | |
632 | \r | |
633 | ///\r | |
634 | /// This structure provides the assert information that is typically associated with a debug assertion failing.\r | |
635 | ///\r | |
636 | /// The data indicates the location of the assertion that failed in the source code. This information\r | |
637 | /// includes the file name and line number that are necessary to find the failing assertion in source code.\r | |
638 | ///\r | |
639 | typedef struct {\r | |
640 | ///\r | |
641 | /// The data header identifying the data. DataHeader.HeaderSize should be\r | |
642 | /// sizeof (EFI_STATUS_CODE_DATA), DataHeader.Size should be\r | |
d1eff2f5 | 643 | /// sizeof (EFI_DEBUG_ASSERT_DATA) - HeaderSize , and\r |
b205f267 | 644 | /// DataHeader.Type should be EFI_STATUS_CODE_SPECIFIC_DATA_GUID.\r |
9095d37b | 645 | ///\r |
b205f267 | 646 | EFI_STATUS_CODE_DATA DataHeader;\r |
647 | ///\r | |
648 | /// The line number of the source file where the fault was generated.\r | |
649 | ///\r | |
650 | UINT32 LineNumber;\r | |
651 | ///\r | |
652 | /// The size in bytes of FileName.\r | |
653 | ///\r | |
654 | UINT32 FileNameSize;\r | |
655 | ///\r | |
9095d37b | 656 | /// A pointer to a NULL-terminated ASCII or Unicode string that represents\r |
b205f267 | 657 | /// the file name of the source file where the fault was generated.\r |
658 | ///\r | |
659 | EFI_STATUS_CODE_STRING_DATA *FileName;\r | |
660 | } EFI_DEBUG_ASSERT_DATA;\r | |
661 | \r | |
662 | ///\r | |
663 | /// System Context Data EBC/IA32/IPF\r | |
664 | ///\r | |
665 | typedef union {\r | |
666 | ///\r | |
667 | /// The context of the EBC virtual machine when the exception was generated. Type\r | |
668 | /// EFI_SYSTEM_CONTEXT_EBC is defined in EFI_DEBUG_SUPPORT_PROTOCOL\r | |
669 | /// in the UEFI Specification.\r | |
670 | ///\r | |
671 | EFI_SYSTEM_CONTEXT_EBC SystemContextEbc;\r | |
672 | ///\r | |
673 | /// The context of the IA-32 processor when the exception was generated. Type\r | |
674 | /// EFI_SYSTEM_CONTEXT_IA32 is defined in the\r | |
675 | /// EFI_DEBUG_SUPPORT_PROTOCOL in the UEFI Specification.\r | |
676 | ///\r | |
677 | EFI_SYSTEM_CONTEXT_IA32 SystemContextIa32;\r | |
678 | ///\r | |
679 | /// The context of the Itanium(R) processor when the exception was generated. Type\r | |
680 | /// EFI_SYSTEM_CONTEXT_IPF is defined in the\r | |
681 | /// EFI_DEBUG_SUPPORT_PROTOCOL in the UEFI Specification.\r | |
682 | ///\r | |
683 | EFI_SYSTEM_CONTEXT_IPF SystemContextIpf;\r | |
31c21fd3 | 684 | ///\r |
685 | /// The context of the X64 processor when the exception was generated. Type\r | |
686 | /// EFI_SYSTEM_CONTEXT_X64 is defined in the\r | |
687 | /// EFI_DEBUG_SUPPORT_PROTOCOL in the UEFI Specification.\r | |
688 | ///\r | |
9095d37b | 689 | EFI_SYSTEM_CONTEXT_X64 SystemContextX64;\r |
31c21fd3 | 690 | ///\r |
691 | /// The context of the ARM processor when the exception was generated. Type\r | |
692 | /// EFI_SYSTEM_CONTEXT_ARM is defined in the\r | |
693 | /// EFI_DEBUG_SUPPORT_PROTOCOL in the UEFI Specification.\r | |
694 | ///\r | |
695 | EFI_SYSTEM_CONTEXT_ARM SystemContextArm;\r | |
b205f267 | 696 | } EFI_STATUS_CODE_EXCEP_SYSTEM_CONTEXT;\r |
697 | \r | |
698 | ///\r | |
699 | /// This structure defines extended data describing a processor exception error.\r | |
700 | ///\r | |
701 | /// This extended data allows the processor context that is present at the time of the exception to be\r | |
702 | /// reported with the exception. The format and contents of the context data varies depending on the\r | |
703 | /// processor architecture.\r | |
704 | ///\r | |
705 | typedef struct {\r | |
706 | ///\r | |
707 | /// The data header identifying the data. DataHeader.HeaderSize should be\r | |
708 | /// sizeof (EFI_STATUS_CODE_DATA), DataHeader.Size should be\r | |
d1eff2f5 | 709 | /// sizeof (EFI_STATUS_CODE_EXCEP_EXTENDED_DATA) - HeaderSize,\r |
b205f267 | 710 | /// and DataHeader.Type should be\r |
9095d37b | 711 | /// EFI_STATUS_CODE_SPECIFIC_DATA_GUID.\r |
b205f267 | 712 | ///\r |
713 | EFI_STATUS_CODE_DATA DataHeader;\r | |
714 | ///\r | |
9095d37b | 715 | /// The system context.\r |
b205f267 | 716 | ///\r |
717 | EFI_STATUS_CODE_EXCEP_SYSTEM_CONTEXT Context;\r | |
718 | } EFI_STATUS_CODE_EXCEP_EXTENDED_DATA;\r | |
719 | \r | |
720 | ///\r | |
721 | /// This structure defines extended data describing a call to a driver binding protocol start function.\r | |
722 | ///\r | |
723 | /// This extended data records information about a Start() function call. Start() is a member of\r | |
724 | /// the UEFI Driver Binding Protocol.\r | |
725 | ///\r | |
726 | typedef struct {\r | |
9095d37b | 727 | ///\r |
b205f267 | 728 | /// The data header identifying the data. DataHeader.HeaderSize should be\r |
729 | /// sizeof (EFI_STATUS_CODE_DATA), DataHeader.Size should be\r | |
730 | /// sizeof (EFI_STATUS_CODE_START_EXTENDED_DATA) - HeaderSize,\r | |
731 | /// and DataHeader.Type should be\r | |
9095d37b | 732 | /// EFI_STATUS_CODE_SPECIFIC_DATA_GUID.\r |
b205f267 | 733 | ///\r |
734 | EFI_STATUS_CODE_DATA DataHeader;\r | |
735 | ///\r | |
9095d37b | 736 | /// The controller handle.\r |
b205f267 | 737 | ///\r |
738 | EFI_HANDLE ControllerHandle;\r | |
739 | ///\r | |
740 | /// The driver binding handle.\r | |
741 | ///\r | |
742 | EFI_HANDLE DriverBindingHandle;\r | |
9095d37b LG |
743 | ///\r |
744 | /// The size of the RemainingDevicePath. It is zero if the Start() function is\r | |
b205f267 | 745 | /// called with RemainingDevicePath = NULL. The UEFI Specification allows\r |
746 | /// that the Start() function of bus drivers can be called in this way.\r | |
747 | ///\r | |
748 | UINT16 DevicePathSize;\r | |
749 | ///\r | |
9095d37b LG |
750 | /// Matches the RemainingDevicePath parameter being passed to the Start() function.\r |
751 | /// Note that this parameter is the variable-length device path and not a pointer\r | |
b205f267 | 752 | /// to the device path.\r |
9095d37b | 753 | ///\r |
6ce55357 | 754 | // EFI_DEVICE_PATH_PROTOCOL RemainingDevicePath;\r |
b205f267 | 755 | } EFI_STATUS_CODE_START_EXTENDED_DATA;\r |
756 | \r | |
757 | ///\r | |
758 | /// This structure defines extended data describing a legacy option ROM (OpROM).\r | |
759 | ///\r | |
760 | /// The device handle and ROM image base can be used by consumers to determine which option ROM\r | |
761 | /// failed. Due to the black-box nature of legacy option ROMs, the amount of information that can be\r | |
762 | /// obtained may be limited.\r | |
763 | ///\r | |
764 | typedef struct {\r | |
765 | ///\r | |
766 | /// The data header identifying the data. DataHeader.HeaderSize should be\r | |
767 | /// sizeof (EFI_STATUS_CODE_DATA), DataHeader.Size should be\r | |
768 | /// sizeof (EFI_LEGACY_OPROM_EXTENDED_DATA) - HeaderSize, and\r | |
9095d37b | 769 | /// DataHeader.Type should be EFI_STATUS_CODE_SPECIFIC_DATA_GUID.\r |
b205f267 | 770 | ///\r |
771 | EFI_STATUS_CODE_DATA DataHeader;\r | |
772 | ///\r | |
773 | /// The handle corresponding to the device that this legacy option ROM is being invoked.\r | |
774 | ///\r | |
775 | EFI_HANDLE DeviceHandle;\r | |
776 | ///\r | |
9095d37b | 777 | /// The base address of the shadowed legacy ROM image. May or may not point to the shadow RAM area.\r |
b205f267 | 778 | ///\r |
779 | EFI_PHYSICAL_ADDRESS RomImageBase;\r | |
780 | } EFI_LEGACY_OPROM_EXTENDED_DATA;\r | |
781 | \r | |
2b005f41 DB |
782 | ///\r |
783 | /// This structure defines extended data describing an EFI_STATUS return value that stands for a\r | |
784 | /// failed function call (such as a UEFI boot service).\r | |
785 | ///\r | |
786 | typedef struct {\r | |
787 | ///\r | |
788 | /// The data header identifying the data:\r | |
789 | /// DataHeader.HeaderSize should be sizeof(EFI_STATUS_CODE_DATA),\r | |
790 | /// DataHeader.Size should be sizeof(EFI_RETURN_STATUS_EXTENDED_DATA) - HeaderSize,\r | |
791 | /// DataHeader.Type should be EFI_STATUS_CODE_SPECIFIC_DATA_GUID.\r | |
792 | ///\r | |
793 | EFI_STATUS_CODE_DATA DataHeader;\r | |
794 | ///\r | |
795 | /// The EFI_STATUS return value of the service or function whose failure triggered the\r | |
796 | /// reporting of the status code (generally an error code or a debug code).\r | |
797 | ///\r | |
798 | EFI_STATUS ReturnStatus;\r | |
799 | } EFI_RETURN_STATUS_EXTENDED_DATA;\r | |
800 | \r | |
b205f267 | 801 | extern EFI_GUID gEfiStatusCodeSpecificDataGuid;\r |
802 | \r | |
803 | #endif\r |