Jérémy Compostella has uploaded this change for review. ( https://review.coreboot.org/c/coreboot/+/77228?usp=email )
Change subject: vendorcode/intel: Add StatusCodeDataTypeDebug.h ......................................................................
vendorcode/intel: Add StatusCodeDataTypeDebug.h
Add the EDK2 Status Code Data Debug type in order to decode information reported in the PEI ReportStatusCode service function.
https://github.com/tianocore/edk2/blob/edk2-stable202005/MdeModulePkg/Includ... https://github.com/tianocore/edk2/blob/edk2-stable202302/MdeModulePkg/Includ...
BUG=b:279173035
Change-Id: Idab0139ff0313372e211f679e6e799e2b29781fa Signed-off-by: Jeremy Compostella jeremy.compostella@intel.com --- M src/vendorcode/intel/Makefile.inc A src/vendorcode/intel/edk2/UDK2017/MdeModulePkg/Include/Guid/StatusCodeDataTypeDebug.h A src/vendorcode/intel/edk2/edk2-stable202005/MdeModulePkg/Include/Guid/StatusCodeDataTypeDebug.h A src/vendorcode/intel/edk2/edk2-stable202302/MdeModulePkg/Include/Guid/StatusCodeDataTypeDebug.h 4 files changed, 138 insertions(+), 0 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/28/77228/1
diff --git a/src/vendorcode/intel/Makefile.inc b/src/vendorcode/intel/Makefile.inc index 4396ed3..c4e21e3 100644 --- a/src/vendorcode/intel/Makefile.inc +++ b/src/vendorcode/intel/Makefile.inc @@ -27,4 +27,5 @@ CPPFLAGS_common += -I$(src)/vendorcode/intel/edk2/edk2-stable202302/MdePkg/Include CPPFLAGS_common += -I$(src)/vendorcode/intel/edk2/edk2-stable202302/IntelFsp2Pkg/Include CPPFLAGS_common += -I$(src)/vendorcode/intel/edk2/edk2-stable202302/UefiCpuPkg/Include/ +CPPFLAGS_common += -I$(src)/vendorcode/intel/edk2/edk2-stable202302/MdeModulePkg/Include endif diff --git a/src/vendorcode/intel/edk2/UDK2017/MdeModulePkg/Include/Guid/StatusCodeDataTypeDebug.h b/src/vendorcode/intel/edk2/UDK2017/MdeModulePkg/Include/Guid/StatusCodeDataTypeDebug.h new file mode 100644 index 0000000..18a050c --- /dev/null +++ b/src/vendorcode/intel/edk2/UDK2017/MdeModulePkg/Include/Guid/StatusCodeDataTypeDebug.h @@ -0,0 +1,43 @@ +/** @file + This file defines the GUID and data structure used to pass DEBUG() macro + information to the Status Code Protocol and Status Code PPI. + +Copyright (c) 2007 - 2018, Intel Corporation. All rights reserved.<BR> +SPDX-License-Identifier: BSD-2-Clause-Patent + +**/ + +#ifndef _STATUS_CODE_DATA_TYPE_DEBUG_H_ +#define _STATUS_CODE_DATA_TYPE_DEBUG_H_ + +/// +/// The Global ID used to identify a structure of type EFI_DEBUG_INFO. +/// +#define EFI_STATUS_CODE_DATA_TYPE_DEBUG_GUID \ + { \ + 0x9A4E9246, 0xD553, 0x11D5, { 0x87, 0xE2, 0x00, 0x06, 0x29, 0x45, 0xC3, 0xb9 } \ + } + +/// +/// The maximum size of an EFI_DEBUG_INFO structure. +/// +#define EFI_STATUS_CODE_DATA_MAX_SIZE 200 + +/// +/// This structure contains the ErrorLevel passed into the DEBUG() macro, followed +/// by a 96-byte buffer that contains the variable argument list passed to the +/// DEBUG() macro that has been converted to a BASE_LIST. The 96-byte buffer is +/// followed by a Null-terminated ASCII string that is the Format string passed +/// to the DEBUG() macro. The maximum size of this structure is defined by +/// EFI_STATUS_CODE_DATA_MAX_SIZE. +/// +typedef struct { + /// + /// The debug error level passed into a DEBUG() macro. + /// + UINT32 ErrorLevel; +} EFI_DEBUG_INFO; + +extern EFI_GUID gEfiStatusCodeDataTypeDebugGuid; + +#endif // _STATUS_CODE_DATA_TYPE_DEBUG_H_ diff --git a/src/vendorcode/intel/edk2/edk2-stable202005/MdeModulePkg/Include/Guid/StatusCodeDataTypeDebug.h b/src/vendorcode/intel/edk2/edk2-stable202005/MdeModulePkg/Include/Guid/StatusCodeDataTypeDebug.h new file mode 100644 index 0000000..18a050c --- /dev/null +++ b/src/vendorcode/intel/edk2/edk2-stable202005/MdeModulePkg/Include/Guid/StatusCodeDataTypeDebug.h @@ -0,0 +1,43 @@ +/** @file + This file defines the GUID and data structure used to pass DEBUG() macro + information to the Status Code Protocol and Status Code PPI. + +Copyright (c) 2007 - 2018, Intel Corporation. All rights reserved.<BR> +SPDX-License-Identifier: BSD-2-Clause-Patent + +**/ + +#ifndef _STATUS_CODE_DATA_TYPE_DEBUG_H_ +#define _STATUS_CODE_DATA_TYPE_DEBUG_H_ + +/// +/// The Global ID used to identify a structure of type EFI_DEBUG_INFO. +/// +#define EFI_STATUS_CODE_DATA_TYPE_DEBUG_GUID \ + { \ + 0x9A4E9246, 0xD553, 0x11D5, { 0x87, 0xE2, 0x00, 0x06, 0x29, 0x45, 0xC3, 0xb9 } \ + } + +/// +/// The maximum size of an EFI_DEBUG_INFO structure. +/// +#define EFI_STATUS_CODE_DATA_MAX_SIZE 200 + +/// +/// This structure contains the ErrorLevel passed into the DEBUG() macro, followed +/// by a 96-byte buffer that contains the variable argument list passed to the +/// DEBUG() macro that has been converted to a BASE_LIST. The 96-byte buffer is +/// followed by a Null-terminated ASCII string that is the Format string passed +/// to the DEBUG() macro. The maximum size of this structure is defined by +/// EFI_STATUS_CODE_DATA_MAX_SIZE. +/// +typedef struct { + /// + /// The debug error level passed into a DEBUG() macro. + /// + UINT32 ErrorLevel; +} EFI_DEBUG_INFO; + +extern EFI_GUID gEfiStatusCodeDataTypeDebugGuid; + +#endif // _STATUS_CODE_DATA_TYPE_DEBUG_H_ diff --git a/src/vendorcode/intel/edk2/edk2-stable202302/MdeModulePkg/Include/Guid/StatusCodeDataTypeDebug.h b/src/vendorcode/intel/edk2/edk2-stable202302/MdeModulePkg/Include/Guid/StatusCodeDataTypeDebug.h new file mode 100644 index 0000000..451e829b --- /dev/null +++ b/src/vendorcode/intel/edk2/edk2-stable202302/MdeModulePkg/Include/Guid/StatusCodeDataTypeDebug.h @@ -0,0 +1,51 @@ +/** @file + This file defines the GUID and data structure used to pass DEBUG() macro + information to the Status Code Protocol and Status Code PPI. + +Copyright (c) 2007 - 2018, Intel Corporation. All rights reserved.<BR> +SPDX-License-Identifier: BSD-2-Clause-Patent + +**/ + +#ifndef _STATUS_CODE_DATA_TYPE_DEBUG_H_ +#define _STATUS_CODE_DATA_TYPE_DEBUG_H_ + +#include <Pi/PiStatusCode.h> + +/// +/// The Global ID used to identify a structure of type EFI_DEBUG_INFO. +/// +#define EFI_STATUS_CODE_DATA_TYPE_DEBUG_GUID \ + { \ + 0x9A4E9246, 0xD553, 0x11D5, { 0x87, 0xE2, 0x00, 0x06, 0x29, 0x45, 0xC3, 0xb9 } \ + } + +/// +/// The maximum size of an EFI_DEBUG_INFO structure. +/// +#define EFI_STATUS_CODE_DATA_MAX_SIZE 0x200 + +/// +/// Define the maximum extended data size that is supported when a +/// status code is reported. +/// +#define MAX_EXTENDED_DATA_SIZE (EFI_STATUS_CODE_DATA_MAX_SIZE + sizeof(EFI_STATUS_CODE_DATA)) + +/// +/// This structure contains the ErrorLevel passed into the DEBUG() macro, followed +/// by a 96-byte buffer that contains the variable argument list passed to the +/// DEBUG() macro that has been converted to a BASE_LIST. The 96-byte buffer is +/// followed by a Null-terminated ASCII string that is the Format string passed +/// to the DEBUG() macro. The maximum size of this structure is defined by +/// EFI_STATUS_CODE_DATA_MAX_SIZE. +/// +typedef struct { + /// + /// The debug error level passed into a DEBUG() macro. + /// + UINT32 ErrorLevel; +} EFI_DEBUG_INFO; + +extern EFI_GUID gEfiStatusCodeDataTypeDebugGuid; + +#endif // _STATUS_CODE_DATA_TYPE_DEBUG_H_