1. Add Protocol/StatusCode.h reference in FrameworkDxeCis.h
authorvanjeff <vanjeff@6f19259b-4bc3-4df7-8a09-765794883524>
Thu, 28 Jun 2007 02:38:21 +0000 (02:38 +0000)
committervanjeff <vanjeff@6f19259b-4bc3-4df7-8a09-765794883524>
Thu, 28 Jun 2007 02:38:21 +0000 (02:38 +0000)
2. Add SERIAL_MODE and PARALLEL_MODE in FrameworkLegacy16.h
3. Add file FrameworkStatusCodeDataTypeId.h

git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@2822 6f19259b-4bc3-4df7-8a09-765794883524

IntelFrameworkPkg/Include/Common/FrameworkDxeCis.h
IntelFrameworkPkg/Include/Common/FrameworkLegacy16.h
IntelFrameworkPkg/Include/Common/FrameworkStatusCodeDataTypeId.h [new file with mode: 0644]

index 93e3639..197fa7c 100644 (file)
@@ -22,6 +22,7 @@
 #define _FRAMEWORK_DXE_CIS_H_\r
 \r
 #include <PiDxe.h>\r
+#include <Protocol/StatusCode.h>\r
 \r
 typedef struct {\r
   EFI_TABLE_HEADER              Hdr;\r
@@ -65,4 +66,14 @@ typedef struct {
 #define EFI_EVENT_SIGNAL_READY_TO_BOOT  0x00000203\r
 #define EFI_EVENT_SIGNAL_LEGACY_BOOT    0x00000204\r
 \r
+//\r
+// Function prototype for invoking a function on an Application Processor\r
+// Used by both the SMM infrastructure and the MP Services Protocol\r
+//\r
+typedef\r
+VOID\r
+(EFIAPI *EFI_AP_PROCEDURE) (\r
+  IN  VOID                              *Buffer\r
+  );\r
+\r
 #endif\r
index ff7f2c0..fc1eab8 100644 (file)
@@ -109,6 +109,9 @@ typedef struct {
 // EFI_TO_COMPATIBILITY16_BOOT_TABLE\r
 ///////////////////////////////////////////////////////////////////////////////\r
 \r
+typedef UINT8 SERIAL_MODE;\r
+typedef UINT8 PARALLEL_MODE;\r
+\r
 //\r
 // DEVICE_PRODUCER_SERIAL & its modes\r
 //\r
diff --git a/IntelFrameworkPkg/Include/Common/FrameworkStatusCodeDataTypeId.h b/IntelFrameworkPkg/Include/Common/FrameworkStatusCodeDataTypeId.h
new file mode 100644 (file)
index 0000000..ecefeeb
--- /dev/null
@@ -0,0 +1,337 @@
+/** @file\r
+  This file defines the data structures to support Status Code Data.\r
+\r
+  Copyright (c) 2007, Intel Corporation\r
+  All rights reserved. This program and the accompanying materials\r
+  are licensed and made available under the terms and conditions of the BSD License\r
+  which accompanies this distribution.  The full text of the license may be found at\r
+  http://opensource.org/licenses/bsd-license.php\r
+\r
+  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
+  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
+\r
+  Module Name:  FrameworkStatusCodeDataTypeId.h\r
+\r
+  @par Revision Reference:\r
+  These definitions are from Framework of EFI Status Code Spec\r
+  Version 0.92.\r
+\r
+**/\r
+\r
+#ifndef __FRAMEWORK_STATUS_CODE_DATA_TYPE_ID_H__\r
+#define __FRAMEWORK_STATUS_CODE_DATA_TYPE_ID_H__\r
+\r
+#include <Protocol/DebugSupport.h>\r
+\r
+///\r
+/// The size of string\r
+///\r
+#define EFI_STATUS_CODE_DATA_MAX_STRING_SIZE  150\r
+\r
+///\r
+/// This is the max data size including all the headers which can be passed\r
+/// as Status Code data. This data should be multiple of 8 byte\r
+/// to avoid any kind of boundary issue. Also, sum of this data size (inclusive\r
+/// of size of EFI_STATUS_CODE_DATA should not exceed the max record size of\r
+/// data hub\r
+///\r
+#define EFI_STATUS_CODE_DATA_MAX_SIZE 200\r
+\r
+#pragma pack(1)\r
+typedef enum {\r
+  EfiStringAscii,\r
+  EfiStringUnicode,\r
+  EfiStringToken\r
+} EFI_STRING_TYPE;\r
+\r
+typedef struct {\r
+  EFI_HII_HANDLE  Handle;\r
+  STRING_REF      Token;\r
+} EFI_STATUS_CODE_STRING_TOKEN;\r
+\r
+typedef union {\r
+  CHAR8                         *Ascii;\r
+  CHAR16                        *Unicode;\r
+  EFI_STATUS_CODE_STRING_TOKEN  Hii;\r
+} EFI_STATUS_CODE_STRING;\r
+\r
+typedef struct {\r
+  EFI_STATUS_CODE_DATA                          DataHeader;\r
+  EFI_STRING_TYPE                               StringType;\r
+  EFI_STATUS_CODE_STRING                        String;\r
+} EFI_STATUS_CODE_STRING_DATA;\r
+\r
+#pragma pack()\r
+\r
+#pragma pack(1)\r
+\r
+typedef struct {\r
+  UINT32  ErrorLevel;\r
+  //\r
+  // 12 * sizeof (UINT64) Var Arg stack\r
+  //\r
+  // ascii DEBUG () Format string\r
+  //\r
+} EFI_DEBUG_INFO;\r
+\r
+#pragma pack()\r
+\r
+//\r
+// declaration for EFI_EXP_DATA. This may change\r
+//\r
+// typedef UINTN   EFI_EXP_DATA;\r
+\r
+///\r
+/// Voltage Extended Error Data\r
+///\r
+typedef struct {\r
+  EFI_STATUS_CODE_DATA  DataHeader;\r
+  EFI_EXP_BASE10_DATA   Voltage;\r
+  EFI_EXP_BASE10_DATA   Threshold;\r
+} EFI_COMPUTING_UNIT_VOLTAGE_ERROR_DATA;\r
+\r
+///\r
+/// Microcode Update Extended Error Data\r
+///\r
+typedef struct {\r
+  EFI_STATUS_CODE_DATA  DataHeader;\r
+  UINT32                Version;\r
+} EFI_COMPUTING_UNIT_MICROCODE_UPDATE_ERROR_DATA;\r
+\r
+///\r
+/// Asynchronous Timer Extended Error Data\r
+///\r
+typedef struct {\r
+  EFI_STATUS_CODE_DATA  DataHeader;\r
+  EFI_EXP_BASE10_DATA   TimerLimit;\r
+} EFI_COMPUTING_UNIT_TIMER_EXPIRED_ERROR_DATA;\r
+\r
+///\r
+/// Host Processor Mismatch Extended Error Data\r
+///\r
+typedef struct {\r
+  EFI_STATUS_CODE_DATA  DataHeader;\r
+  UINT32                Instance;\r
+  UINT16                Attributes;\r
+} EFI_HOST_PROCESSOR_MISMATCH_ERROR_DATA;\r
+\r
+//\r
+// EFI_COMPUTING_UNIT_MISMATCH_ATTRIBUTES\r
+// All other attributes are reserved for future use and\r
+// must be initialized to 0.\r
+//\r
+#define EFI_COMPUTING_UNIT_MISMATCH_SPEED       0x0001\r
+#define EFI_COMPUTING_UNIT_MISMATCH_FSB_SPEED   0x0002\r
+#define EFI_COMPUTING_UNIT_MISMATCH_FAMILY      0x0004\r
+#define EFI_COMPUTING_UNIT_MISMATCH_MODEL       0x0008\r
+#define EFI_COMPUTING_UNIT_MISMATCH_STEPPING    0x0010\r
+#define EFI_COMPUTING_UNIT_MISMATCH_CACHE_SIZE  0x0020\r
+#define EFI_COMPUTING_UNIT_MISMATCH_OEM1        0x1000\r
+#define EFI_COMPUTING_UNIT_MISMATCH_OEM2        0x2000\r
+#define EFI_COMPUTING_UNIT_MISMATCH_OEM3        0x4000\r
+#define EFI_COMPUTING_UNIT_MISMATCH_OEM4        0x8000\r
+\r
+///\r
+/// Thermal Extended Error Data\r
+///\r
+typedef struct {\r
+  EFI_STATUS_CODE_DATA  DataHeader;\r
+  EFI_EXP_BASE10_DATA   Temperature;\r
+  EFI_EXP_BASE10_DATA   Threshold;\r
+} EFI_COMPUTING_UNIT_THERMAL_ERROR_DATA;\r
+\r
+///\r
+/// Processor Disabled Extended Error Data\r
+///\r
+typedef struct {\r
+  EFI_STATUS_CODE_DATA  DataHeader;\r
+  UINT32                Cause;\r
+  BOOLEAN               SoftwareDisabled;\r
+} EFI_COMPUTING_UNIT_CPU_DISABLED_ERROR_DATA;\r
+\r
+typedef enum {\r
+  EfiInitCacheDataOnly,\r
+  EfiInitCacheInstrOnly,\r
+  EfiInitCacheBoth,\r
+  EfiInitCacheUnspecified\r
+} EFI_INIT_CACHE_TYPE;\r
+\r
+///\r
+/// Embedded cache init extended data\r
+///\r
+typedef struct {\r
+  EFI_STATUS_CODE_DATA  DataHeader;\r
+  UINT32                Level;\r
+  EFI_INIT_CACHE_TYPE   Type;\r
+} EFI_CACHE_INIT_DATA;\r
+\r
+//\r
+// Memory Extended Error Data\r
+//\r
+\r
+///\r
+/// Memory Error Granularity Definition\r
+///\r
+typedef UINT8 EFI_MEMORY_ERROR_GRANULARITY;\r
+\r
+///\r
+/// Memory Error Operation Definition\r
+///\r
+typedef UINT8 EFI_MEMORY_ERROR_OPERATION;\r
+\r
+typedef struct {\r
+  EFI_STATUS_CODE_DATA          DataHeader;\r
+  EFI_MEMORY_ERROR_GRANULARITY  Granularity;\r
+  EFI_MEMORY_ERROR_OPERATION    Operation;\r
+  UINTN                         Syndrome;\r
+  EFI_PHYSICAL_ADDRESS          Address;\r
+  UINTN                         Resolution;\r
+} EFI_MEMORY_EXTENDED_ERROR_DATA;\r
+\r
+//\r
+// Memory Error Granularities\r
+//\r
+#define EFI_MEMORY_ERROR_OTHER      0x01\r
+#define EFI_MEMORY_ERROR_UNKNOWN    0x02\r
+#define EFI_MEMORY_ERROR_DEVICE     0x03\r
+#define EFI_MEMORY_ERROR_PARTITION  0x04\r
+\r
+//\r
+// Memory Error Operations\r
+//\r
+#define EFI_MEMORY_OPERATION_OTHER          0x01\r
+#define EFI_MEMORY_OPERATION_UNKNOWN        0x02\r
+#define EFI_MEMORY_OPERATION_READ           0x03\r
+#define EFI_MEMORY_OPERATION_WRITE          0x04\r
+#define EFI_MEMORY_OPERATION_PARTIAL_WRITE  0x05\r
+\r
+//\r
+// Define shorthands to describe Group Operations\r
+// Many memory init operations are essentially group\r
+// operations.\r
+\r
+/// A shorthand to describe that the operation is performed\r
+/// on multiple devices within the array\r
+///\r
+#define EFI_MULTIPLE_MEMORY_DEVICE_OPERATION  0xfffe\r
+///\r
+/// A shorthand to describe that the operation is performed on all devices within the array\r
+///\r
+#define EFI_ALL_MEMORY_DEVICE_OPERATION 0xffff\r
+///\r
+/// A shorthand to describe that the operation is performed on multiple arrays\r
+///\r
+#define EFI_MULTIPLE_MEMORY_ARRAY_OPERATION 0xfffe\r
+///\r
+/// A shorthand to describe that the operation is performed on all the arrays\r
+///\r
+#define EFI_ALL_MEMORY_ARRAY_OPERATION  0xffff\r
+\r
+//\r
+// DIMM number\r
+//\r
+#pragma pack(1)\r
+typedef struct {\r
+  EFI_STATUS_CODE_DATA  DataHeader;\r
+  UINT16                Array;\r
+  UINT16                Device;\r
+} EFI_STATUS_CODE_DIMM_NUMBER;\r
+#pragma pack()\r
+\r
+///\r
+/// Memory Module Mismatch Extended Error Data\r
+///\r
+typedef struct {\r
+  EFI_STATUS_CODE_DATA        DataHeader;\r
+  EFI_STATUS_CODE_DIMM_NUMBER Instance;\r
+} EFI_MEMORY_MODULE_MISMATCH_ERROR_DATA;\r
+\r
+///\r
+/// Memory Range Extended Data\r
+///\r
+typedef struct {\r
+  EFI_STATUS_CODE_DATA  DataHeader;\r
+  EFI_PHYSICAL_ADDRESS  Start;\r
+  EFI_PHYSICAL_ADDRESS  Length;\r
+} EFI_MEMORY_RANGE_EXTENDED_DATA;\r
+\r
+///\r
+/// Device handle Extended Data. Used for many\r
+/// errors and progress codes to point to the device.\r
+///\r
+typedef struct {\r
+  EFI_STATUS_CODE_DATA  DataHeader;\r
+  EFI_HANDLE            Handle;\r
+} EFI_DEVICE_HANDLE_EXTENDED_DATA;\r
+\r
+typedef struct {\r
+  EFI_STATUS_CODE_DATA                 DataHeader;\r
+  UINT8                                *DevicePath;\r
+} EFI_DEVICE_PATH_EXTENDED_DATA;\r
+\r
+typedef struct {\r
+  EFI_STATUS_CODE_DATA           DataHeader;\r
+  EFI_HANDLE                     ControllerHandle;\r
+  EFI_HANDLE                     DriverBindingHandle;\r
+  UINT16                         DevicePathSize;\r
+  UINT8                          *RemainingDevicePath;\r
+} EFI_STATUS_CODE_START_EXTENDED_DATA;\r
+\r
+///\r
+/// Resource Allocation Failure Extended Error Data\r
+///\r
+\r
+/*\r
+typedef struct {\r
+  EFI_STATUS_CODE_DATA      DataHeader;\r
+  EFI_DEVICE_PATH_PROTOCOL  *DevicePath;\r
+  UINT32                    Bar;\r
+  VOID                      *ReqRes;\r
+  VOID                      *AllocRes;\r
+} EFI_RESOURCE_ALLOC_FAILURE_ERROR_DATA;\r
+*/\r
+typedef struct {\r
+  EFI_STATUS_CODE_DATA               DataHeader;\r
+  UINT32                             Bar;\r
+  UINT16                             DevicePathSize;\r
+  UINT16                             ReqResSize;\r
+  UINT16                             AllocResSize;\r
+  UINT8                              *DevicePath;\r
+  UINT8                              *ReqRes;\r
+  UINT8                              *AllocRes;\r
+} EFI_RESOURCE_ALLOC_FAILURE_ERROR_DATA;\r
+\r
+///\r
+/// Extended Error Data for Assert\r
+///\r
+typedef struct {\r
+  EFI_STATUS_CODE_DATA        DataHeader;\r
+  UINT32                      LineNumber;\r
+  UINT32                      FileNameSize;\r
+  EFI_STATUS_CODE_STRING_DATA *FileName;\r
+} EFI_DEBUG_ASSERT_DATA;\r
+\r
+///\r
+/// System Context Data EBC/IA32/IPF\r
+///\r
+typedef union {\r
+  EFI_SYSTEM_CONTEXT_EBC  SystemContextEbc;\r
+  EFI_SYSTEM_CONTEXT_IA32 SystemContextIa32;\r
+  EFI_SYSTEM_CONTEXT_IPF  SystemContextIpf;\r
+} EFI_STATUS_CODE_EXCEP_SYSTEM_CONTEXT;\r
+\r
+typedef struct {\r
+  EFI_STATUS_CODE_DATA                  DataHeader;\r
+  EFI_STATUS_CODE_EXCEP_SYSTEM_CONTEXT  Context;\r
+} EFI_STATUS_CODE_EXCEP_EXTENDED_DATA;\r
+\r
+///\r
+/// Legacy Oprom extended data\r
+///\r
+typedef struct {\r
+  EFI_STATUS_CODE_DATA  DataHeader;\r
+  EFI_HANDLE            DeviceHandle;\r
+  EFI_PHYSICAL_ADDRESS  RomImageBase;\r
+} EFI_LEGACY_OPROM_EXTENDED_DATA;\r
+\r
+#endif\r