Initial directory structure of IntelFrameworkPkg.
[mirror_edk2.git] / IntelFrameworkPkg / Library / DxeReportStatusCodeLibFramework / ReportStatusCodeLib.c
1 /** @file
2 Report Status Code Library for DXE Phase.
3
4 Copyright (c) 2006 - 2007, Intel Corporation<BR>
5 All rights reserved. This program and the accompanying materials
6 are licensed and made available under the terms and conditions of the BSD License
7 which accompanies this distribution. The full text of the license may be found at
8 http://opensource.org/licenses/bsd-license.php
9
10 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
11 WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
12
13 **/
14
15 #include <Common/FrameworkDxeCis.h>
16 #include <Library/DebugLib.h>
17 #include <Library/UefiBootServicesTableLib.h>
18 #include <Library/UefiRuntimeServicesTableLib.h>
19 #include <Library/BaseLib.h>
20 #include <Library/BaseMemoryLib.h>
21 #include <Library/PcdLib.h>
22 #include <Library/ReportStatusCodeLib.h>
23
24 #include <Protocol/StatusCode.h>
25
26 /**
27 Internal worker function that reports a status code through the Status Code Protocol
28
29 This function checks to see if a Status Code Protocol is present in the handle
30 database. If a Status Code Protocol is not present, then EFI_UNSUPPORTED is
31 returned. If a Status Code Protocol is present, then it is cached in gStatusCode,
32 and the ReportStatusCode() service of the Status Code Protocol is called passing in
33 Type, Value, Instance, CallerId, and Data. The result of this call is returned.
34
35 @param Type Status code type.
36 @param Value Status code value.
37 @param Instance Status code instance number.
38 @param CallerId Pointer to a GUID that identifies the caller of this
39 function. This is an optional parameter that may be
40 NULL.
41 @param Data Pointer to the extended data buffer. This is an
42 optional parameter that may be NULL.
43
44 @retval EFI_SUCCESS The status code was reported.
45 @retval EFI_OUT_OF_RESOURCES There were not enough resources to report the status code.
46 @retval EFI_UNSUPPORTED Status Code Protocol is not available.
47
48 **/
49 STATIC
50 EFI_STATUS
51 InternalReportStatusCode (
52 IN EFI_STATUS_CODE_TYPE Type,
53 IN EFI_STATUS_CODE_VALUE Value,
54 IN UINT32 Instance,
55 IN CONST EFI_GUID *CallerId OPTIONAL,
56 IN EFI_STATUS_CODE_DATA *Data OPTIONAL
57 )
58 {
59 EFI_STATUS Status;
60 EFI_STATUS_CODE_PROTOCOL *StatusCode;
61 STATIC EFI_REPORT_STATUS_CODE ReportStatusCode = NULL;
62
63 //
64 // If gStatusCode is NULL, then see if a Status Code Protocol instance is present
65 // in the handle database.
66 //
67 if (ReportStatusCode == NULL) {
68 if (gBS == NULL) {
69 return EFI_UNSUPPORTED;
70 }
71 Status = gBS->LocateProtocol (&gEfiStatusCodeRuntimeProtocolGuid, NULL, &StatusCode);
72 if (!EFI_ERROR (Status) && StatusCode != NULL) {
73 ReportStatusCode = StatusCode->ReportStatusCode;
74 } else if (gRT->Hdr.Revision < 0x20000) {
75 ReportStatusCode = ((FRAMEWORK_EFI_RUNTIME_SERVICES*)gRT)->ReportStatusCode;
76 } else {
77 return EFI_UNSUPPORTED;
78 }
79 }
80
81 //
82 // A Status Code Protocol is present in the handle database, so pass in all the
83 // parameters to the ReportStatusCode() service of the Status Code Protocol
84 //
85 return (*ReportStatusCode) (Type, Value, Instance, (EFI_GUID *)CallerId, Data);
86 }
87
88
89 /**
90 Computes and returns the size, in bytes, of a device path.
91
92 @param DevicePath A pointer to a device path.
93
94 @return The size, in bytes, of DevicePath.
95
96 **/
97 STATIC
98 UINTN
99 InternalReportStatusCodeDevicePathSize (
100 IN CONST EFI_DEVICE_PATH_PROTOCOL *DevicePath
101 )
102 {
103 CONST EFI_DEVICE_PATH_PROTOCOL *Start;
104
105 //
106 // Search for the end of the device path structure
107 //
108 Start = DevicePath;
109 while (!EfiIsDevicePathEnd (DevicePath)) {
110 DevicePath = EfiNextDevicePathNode (DevicePath);
111 }
112
113 //
114 // Subtract the start node from the end node and add in the size of the end node
115 //
116 return ((UINTN) DevicePath - (UINTN) Start) + DevicePathNodeLength (DevicePath);
117 }
118
119
120 /**
121 Converts a status code to an 8-bit POST code value.
122
123 Converts the status code specified by CodeType and Value to an 8-bit POST code
124 and returns the 8-bit POST code in PostCode. If CodeType is an
125 EFI_PROGRESS_CODE or CodeType is an EFI_ERROR_CODE, then bits 0..4 of PostCode
126 are set to bits 16..20 of Value, and bits 5..7 of PostCode are set to bits
127 24..26 of Value., and TRUE is returned. Otherwise, FALSE is returned.
128
129 If PostCode is NULL, then ASSERT().
130
131 @param CodeType The type of status code being converted.
132 @param Value The status code value being converted.
133 @param PostCode A pointer to the 8-bit POST code value to return.
134
135 @retval TRUE The status code specified by CodeType and Value was converted
136 to an 8-bit POST code and returned in PostCode.
137 @retval FALSE The status code specified by CodeType and Value could not be
138 converted to an 8-bit POST code value.
139
140 **/
141 BOOLEAN
142 EFIAPI
143 CodeTypeToPostCode (
144 IN EFI_STATUS_CODE_TYPE CodeType,
145 IN EFI_STATUS_CODE_VALUE Value,
146 OUT UINT8 *PostCode
147 )
148 {
149 //
150 // If PostCode is NULL, then ASSERT()
151 //
152 ASSERT (PostCode != NULL);
153
154 //
155 // Convert Value to an 8 bit post code
156 //
157 if (((CodeType & EFI_STATUS_CODE_TYPE_MASK) == EFI_PROGRESS_CODE) ||
158 ((CodeType & EFI_STATUS_CODE_TYPE_MASK) == EFI_ERROR_CODE) ) {
159 *PostCode = (UINT8) ((((Value & EFI_STATUS_CODE_CLASS_MASK) >> 24) << 5) |
160 (((Value & EFI_STATUS_CODE_SUBCLASS_MASK) >> 16) & 0x1f));
161 return TRUE;
162 }
163 return FALSE;
164 }
165
166
167 /**
168 Extracts ASSERT() information from a status code structure.
169
170 Converts the status code specified by CodeType, Value, and Data to the ASSERT()
171 arguments specified by Filename, Description, and LineNumber. If CodeType is
172 an EFI_ERROR_CODE, and CodeType has a severity of EFI_ERROR_UNRECOVERED, and
173 Value has an operation mask of EFI_SW_EC_ILLEGAL_SOFTWARE_STATE, extract
174 Filename, Description, and LineNumber from the optional data area of the
175 status code buffer specified by Data. The optional data area of Data contains
176 a Null-terminated ASCII string for the FileName, followed by a Null-terminated
177 ASCII string for the Description, followed by a 32-bit LineNumber. If the
178 ASSERT() information could be extracted from Data, then return TRUE.
179 Otherwise, FALSE is returned.
180
181 If Data is NULL, then ASSERT().
182 If Filename is NULL, then ASSERT().
183 If Description is NULL, then ASSERT().
184 If LineNumber is NULL, then ASSERT().
185
186 @param CodeType The type of status code being converted.
187 @param Value The status code value being converted.
188 @param Data Pointer to status code data buffer.
189 @param Filename Pointer to the source file name that generated the ASSERT().
190 @param Description Pointer to the description of the ASSERT().
191 @param LineNumber Pointer to source line number that generated the ASSERT().
192
193 @retval TRUE The status code specified by CodeType, Value, and Data was
194 converted ASSERT() arguments specified by Filename, Description,
195 and LineNumber.
196 @retval FALSE The status code specified by CodeType, Value, and Data could
197 not be converted to ASSERT() arguments.
198
199 **/
200 BOOLEAN
201 EFIAPI
202 ReportStatusCodeExtractAssertInfo (
203 IN EFI_STATUS_CODE_TYPE CodeType,
204 IN EFI_STATUS_CODE_VALUE Value,
205 IN CONST EFI_STATUS_CODE_DATA *Data,
206 OUT CHAR8 **Filename,
207 OUT CHAR8 **Description,
208 OUT UINT32 *LineNumber
209 )
210 {
211 EFI_DEBUG_ASSERT_DATA *AssertData;
212
213 ASSERT (Data != NULL);
214 ASSERT (Filename != NULL);
215 ASSERT (Description != NULL);
216 ASSERT (LineNumber != NULL);
217
218 if (((CodeType & EFI_STATUS_CODE_TYPE_MASK) == EFI_ERROR_CODE) &&
219 ((CodeType & EFI_STATUS_CODE_SEVERITY_MASK) == EFI_ERROR_UNRECOVERED) &&
220 ((Value & EFI_STATUS_CODE_OPERATION_MASK) == EFI_SW_EC_ILLEGAL_SOFTWARE_STATE)) {
221 AssertData = (EFI_DEBUG_ASSERT_DATA *)(Data + 1);
222 *Filename = (CHAR8 *)(AssertData + 1);
223 *Description = *Filename + AsciiStrLen (*Filename) + 1;
224 *LineNumber = AssertData->LineNumber;
225 return TRUE;
226 }
227 return FALSE;
228 }
229
230
231 /**
232 Extracts DEBUG() information from a status code structure.
233
234 Converts the status code specified by Data to the DEBUG() arguments specified
235 by ErrorLevel, Marker, and Format. If type GUID in Data is
236 EFI_STATUS_CODE_DATA_TYPE_DEBUG_GUID, then extract ErrorLevel, Marker, and
237 Format from the optional data area of the status code buffer specified by Data.
238 The optional data area of Data contains a 32-bit ErrorLevel followed by Marker
239 which is 12 UINTN parameters, followed by a Null-terminated ASCII string for
240 the Format. If the DEBUG() information could be extracted from Data, then
241 return TRUE. Otherwise, FALSE is returned.
242
243 If Data is NULL, then ASSERT().
244 If ErrorLevel is NULL, then ASSERT().
245 If Marker is NULL, then ASSERT().
246 If Format is NULL, then ASSERT().
247
248 @param Data Pointer to status code data buffer.
249 @param ErrorLevel Pointer to error level mask for a debug message.
250 @param Marker Pointer to the variable argument list associated with Format.
251 @param Format Pointer to a Null-terminated ASCII format string of a
252 debug message.
253
254 @retval TRUE The status code specified by Data was converted DEBUG() arguments
255 specified by ErrorLevel, Marker, and Format.
256 @retval FALSE The status code specified by Data could not be converted to
257 DEBUG() arguments.
258
259 **/
260 BOOLEAN
261 EFIAPI
262 ReportStatusCodeExtractDebugInfo (
263 IN CONST EFI_STATUS_CODE_DATA *Data,
264 OUT UINT32 *ErrorLevel,
265 OUT VA_LIST *Marker,
266 OUT CHAR8 **Format
267 )
268 {
269 EFI_DEBUG_INFO *DebugInfo;
270
271 ASSERT (Data != NULL);
272 ASSERT (ErrorLevel != NULL);
273 ASSERT (Marker != NULL);
274 ASSERT (Format != NULL);
275
276 //
277 // If the GUID type is not EFI_STATUS_CODE_DATA_TYPE_DEBUG_GUID then return FALSE
278 //
279 if (!CompareGuid (&Data->Type, &gEfiStatusCodeDataTypeDebugGuid)) {
280 return FALSE;
281 }
282
283 //
284 // Retrieve the debug information from the status code record
285 //
286 DebugInfo = (EFI_DEBUG_INFO *)(Data + 1);
287
288 *ErrorLevel = DebugInfo->ErrorLevel;
289
290 //
291 // The first 12 * UINTN bytes of the string are really an
292 // argument stack to support varargs on the Format string.
293 //
294 *Marker = (VA_LIST) (DebugInfo + 1);
295 *Format = (CHAR8 *)(((UINT64 *)*Marker) + 12);
296
297 return TRUE;
298 }
299
300
301 /**
302 Reports a status code.
303
304 Reports the status code specified by the parameters Type and Value. Status
305 code also require an instance, caller ID, and extended data. This function
306 passed in a zero instance, NULL extended data, and a caller ID of
307 gEfiCallerIdGuid, which is the GUID for the module.
308
309 ReportStatusCode()must actively prevent recusrsion. If ReportStatusCode()
310 is called while processing another any other Report Status Code Library function,
311 then ReportStatusCode() must return immediately.
312
313 @param Type Status code type.
314 @param Value Status code value.
315
316 @retval EFI_SUCCESS The status code was reported.
317 @retval EFI_DEVICE_ERROR There status code could not be reported due to a
318 device error.
319 @retval EFI_UNSUPPORTED Report status code is not supported
320
321 **/
322 EFI_STATUS
323 EFIAPI
324 ReportStatusCode (
325 IN EFI_STATUS_CODE_TYPE Type,
326 IN EFI_STATUS_CODE_VALUE Value
327 )
328 {
329 return InternalReportStatusCode (Type, Value, 0, &gEfiCallerIdGuid, NULL);
330 }
331
332
333 /**
334 Reports a status code with a Device Path Protocol as the extended data.
335
336 Allocates and fills in the extended data section of a status code with the
337 Device Path Protocol specified by DevicePath. This function is responsible
338 for allocating a buffer large enough for the standard header and the device
339 path. The standard header is filled in with a GUID of
340 gEfiStatusCodeSpecificDataGuid. The status code is reported with a zero
341 instance and a caller ID of gEfiCallerIdGuid.
342
343 ReportStatusCodeWithDevicePath()must actively prevent recursion. If
344 ReportStatusCodeWithDevicePath() is called while processing another any other
345 Report Status Code Library function, then ReportStatusCodeWithDevicePath()
346 must return EFI_DEVICE_ERROR immediately.
347
348 If DevicePath is NULL, then ASSERT().
349
350 @param Type Status code type.
351 @param Value Status code value.
352 @param DevicePath Pointer to the Device Path Protocol to be reported.
353
354 @retval EFI_SUCCESS The status code was reported with the extended
355 data specified by DevicePath.
356 @retval EFI_OUT_OF_RESOURCES There were not enough resources to allocate the
357 extended data section.
358 @retval EFI_UNSUPPORTED Report status code is not supported
359
360 **/
361 EFI_STATUS
362 EFIAPI
363 ReportStatusCodeWithDevicePath (
364 IN EFI_STATUS_CODE_TYPE Type,
365 IN EFI_STATUS_CODE_VALUE Value,
366 IN CONST EFI_DEVICE_PATH_PROTOCOL *DevicePath
367 )
368 {
369 ASSERT (DevicePath != NULL);
370 return ReportStatusCodeWithExtendedData (
371 Type,
372 Value,
373 (VOID *)DevicePath,
374 InternalReportStatusCodeDevicePathSize (DevicePath)
375 );
376 }
377
378
379 /**
380 Reports a status code with an extended data buffer.
381
382 Allocates and fills in the extended data section of a status code with the
383 extended data specified by ExtendedData and ExtendedDataSize. ExtendedData
384 is assumed to be one of the data structures specified in Related Definitions.
385 These data structure do not have the standard header, so this function is
386 responsible for allocating a buffer large enough for the standard header and
387 the extended data passed into this function. The standard header is filled
388 in with a GUID of gEfiStatusCodeSpecificDataGuid. The status code is reported
389 with a zero instance and a caller ID of gEfiCallerIdGuid.
390
391 ReportStatusCodeWithExtendedData()must actively prevent recursion. If
392 ReportStatusCodeWithExtendedData() is called while processing another any other
393 Report Status Code Library function, then ReportStatusCodeWithExtendedData()
394 must return EFI_DEVICE_ERROR immediately.
395
396 If ExtendedData is NULL, then ASSERT().
397 If ExtendedDataSize is 0, then ASSERT().
398
399 @param Type Status code type.
400 @param Value Status code value.
401 @param ExtendedData Pointer to the extended data buffer to be reported.
402 @param ExtendedDataSize The size, in bytes, of the extended data buffer to
403 be reported.
404
405 @retval EFI_SUCCESS The status code was reported with the extended
406 data specified by ExtendedData and ExtendedDataSize.
407 @retval EFI_OUT_OF_RESOURCES There were not enough resources to allocate the
408 extended data section.
409 @retval EFI_UNSUPPORTED Report status code is not supported
410
411 **/
412 EFI_STATUS
413 EFIAPI
414 ReportStatusCodeWithExtendedData (
415 IN EFI_STATUS_CODE_TYPE Type,
416 IN EFI_STATUS_CODE_VALUE Value,
417 IN CONST VOID *ExtendedData,
418 IN UINTN ExtendedDataSize
419 )
420 {
421 ASSERT (ExtendedData != NULL);
422 ASSERT (ExtendedDataSize != 0);
423 return ReportStatusCodeEx (
424 Type,
425 Value,
426 0,
427 NULL,
428 NULL,
429 ExtendedData,
430 ExtendedDataSize
431 );
432 }
433
434
435 /**
436 Reports a status code with full parameters.
437
438 The function reports a status code. If ExtendedData is NULL and ExtendedDataSize
439 is 0, then an extended data buffer is not reported. If ExtendedData is not
440 NULL and ExtendedDataSize is not 0, then an extended data buffer is allocated.
441 ExtendedData is assumed not have the standard status code header, so this function
442 is responsible for allocating a buffer large enough for the standard header and
443 the extended data passed into this function. The standard header is filled in
444 with a GUID specified by ExtendedDataGuid. If ExtendedDataGuid is NULL, then a
445 GUID of gEfiStatusCodeSpecificDatauid is used. The status code is reported with
446 an instance specified by Instance and a caller ID specified by CallerId. If
447 CallerId is NULL, then a caller ID of gEfiCallerIdGuid is used.
448
449 ReportStatusCodeEx()must actively prevent recursion. If ReportStatusCodeEx()
450 is called while processing another any other Report Status Code Library function,
451 then ReportStatusCodeEx() must return EFI_DEVICE_ERROR immediately.
452
453 If ExtendedData is NULL and ExtendedDataSize is not zero, then ASSERT().
454 If ExtendedData is not NULL and ExtendedDataSize is zero, then ASSERT().
455
456 @param Type Status code type.
457 @param Value Status code value.
458 @param Instance Status code instance number.
459 @param CallerId Pointer to a GUID that identifies the caller of this
460 function. If this parameter is NULL, then a caller
461 ID of gEfiCallerIdGuid is used.
462 @param ExtendedDataGuid Pointer to the GUID for the extended data buffer.
463 If this parameter is NULL, then a the status code
464 standard header is filled in with
465 gEfiStatusCodeSpecificDataGuid.
466 @param ExtendedData Pointer to the extended data buffer. This is an
467 optional parameter that may be NULL.
468 @param ExtendedDataSize The size, in bytes, of the extended data buffer.
469
470 @retval EFI_SUCCESS The status code was reported.
471 @retval EFI_OUT_OF_RESOURCES There were not enough resources to allocate
472 the extended data section if it was specified.
473 @retval EFI_UNSUPPORTED Report status code is not supported
474
475 **/
476 EFI_STATUS
477 EFIAPI
478 ReportStatusCodeEx (
479 IN EFI_STATUS_CODE_TYPE Type,
480 IN EFI_STATUS_CODE_VALUE Value,
481 IN UINT32 Instance,
482 IN CONST EFI_GUID *CallerId OPTIONAL,
483 IN CONST EFI_GUID *ExtendedDataGuid OPTIONAL,
484 IN CONST VOID *ExtendedData OPTIONAL,
485 IN UINTN ExtendedDataSize
486 )
487 {
488 EFI_STATUS Status;
489 EFI_STATUS_CODE_DATA *StatusCodeData;
490
491 ASSERT (!((ExtendedData == NULL) && (ExtendedDataSize != 0)));
492 ASSERT (!((ExtendedData != NULL) && (ExtendedDataSize == 0)));
493
494 if (gBS == NULL) {
495 return EFI_UNSUPPORTED;
496 }
497
498 //
499 // Allocate space for the Status Code Header and its buffer
500 //
501 StatusCodeData = NULL;
502 gBS->AllocatePool (EfiBootServicesData, sizeof (EFI_STATUS_CODE_DATA) + ExtendedDataSize, (VOID **)&StatusCodeData);
503 if (StatusCodeData == NULL) {
504 return EFI_OUT_OF_RESOURCES;
505 }
506
507 //
508 // Fill in the extended data header
509 //
510 StatusCodeData->HeaderSize = sizeof (EFI_STATUS_CODE_DATA);
511 StatusCodeData->Size = (UINT16)ExtendedDataSize;
512 if (ExtendedDataGuid == NULL) {
513 ExtendedDataGuid = &gEfiStatusCodeSpecificDataGuid;
514 }
515 CopyGuid (&StatusCodeData->Type, ExtendedDataGuid);
516
517 //
518 // Fill in the extended data buffer
519 //
520 CopyMem (StatusCodeData + 1, ExtendedData, ExtendedDataSize);
521
522 //
523 // Report the status code
524 //
525 if (CallerId == NULL) {
526 CallerId = &gEfiCallerIdGuid;
527 }
528 Status = InternalReportStatusCode (Type, Value, Instance, CallerId, StatusCodeData);
529
530 //
531 // Free the allocated buffer
532 //
533 gBS->FreePool (StatusCodeData);
534
535 return Status;
536 }
537
538
539 /**
540 Returns TRUE if status codes of type EFI_PROGRESS_CODE are enabled
541
542 This function returns TRUE if the REPORT_STATUS_CODE_PROPERTY_PROGRESS_CODE_ENABLED
543 bit of PcdReportStatusCodeProperyMask is set. Otherwise FALSE is returned.
544
545 @retval TRUE The REPORT_STATUS_CODE_PROPERTY_PROGRESS_CODE_ENABLED bit of
546 PcdReportStatusCodeProperyMask is set.
547 @retval FALSE The REPORT_STATUS_CODE_PROPERTY_PROGRESS_CODE_ENABLED bit of
548 PcdReportStatusCodeProperyMask is clear.
549
550 **/
551 BOOLEAN
552 EFIAPI
553 ReportProgressCodeEnabled (
554 VOID
555 )
556 {
557 return (BOOLEAN) ((PcdGet8(PcdReportStatusCodePropertyMask) & REPORT_STATUS_CODE_PROPERTY_PROGRESS_CODE_ENABLED) != 0);
558 }
559
560
561 /**
562 Returns TRUE if status codes of type EFI_ERROR_CODE are enabled
563
564 This function returns TRUE if the REPORT_STATUS_CODE_PROPERTY_ERROR_CODE_ENABLED
565 bit of PcdReportStatusCodeProperyMask is set. Otherwise FALSE is returned.
566
567 @retval TRUE The REPORT_STATUS_CODE_PROPERTY_ERROR_CODE_ENABLED bit of
568 PcdReportStatusCodeProperyMask is set.
569 @retval FALSE The REPORT_STATUS_CODE_PROPERTY_ERROR_CODE_ENABLED bit of
570 PcdReportStatusCodeProperyMask is clear.
571
572 **/
573 BOOLEAN
574 EFIAPI
575 ReportErrorCodeEnabled (
576 VOID
577 )
578 {
579 return (BOOLEAN) ((PcdGet8(PcdReportStatusCodePropertyMask) & REPORT_STATUS_CODE_PROPERTY_ERROR_CODE_ENABLED) != 0);
580 }
581
582
583 /**
584 Returns TRUE if status codes of type EFI_DEBUG_CODE are enabled
585
586 This function returns TRUE if the REPORT_STATUS_CODE_PROPERTY_DEBUG_CODE_ENABLED
587 bit of PcdReportStatusCodeProperyMask is set. Otherwise FALSE is returned.
588
589 @retval TRUE The REPORT_STATUS_CODE_PROPERTY_DEBUG_CODE_ENABLED bit of
590 PcdReportStatusCodeProperyMask is set.
591 @retval FALSE The REPORT_STATUS_CODE_PROPERTY_DEBUG_CODE_ENABLED bit of
592 PcdReportStatusCodeProperyMask is clear.
593
594 **/
595 BOOLEAN
596 EFIAPI
597 ReportDebugCodeEnabled (
598 VOID
599 )
600 {
601 return (BOOLEAN) ((PcdGet8(PcdReportStatusCodePropertyMask) & REPORT_STATUS_CODE_PROPERTY_DEBUG_CODE_ENABLED) != 0);
602 }