Home | History | Annotate | Download | only in Guid
      1 /** @file
      2   GUID used to identify status code records HOB that originate from the PEI status code.
      3 
      4 Copyright (c) 2006 - 2010, Intel Corporation. All rights reserved.<BR>
      5 (C) Copyright 2016 Hewlett Packard Enterprise Development LP<BR>
      6 This program and the accompanying materials are licensed and made available under
      7 the terms and conditions of the BSD License that accompanies this distribution.
      8 The full text of the license may be found at
      9 http://opensource.org/licenses/bsd-license.php.
     10 
     11 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
     12 WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
     13 
     14 **/
     15 
     16 #ifndef __MEMORY_STATUS_CODE_RECORD_H__
     17 #define __MEMORY_STATUS_CODE_RECORD_H__
     18 
     19 ///
     20 /// Global ID used to identify GUIDed HOBs that start with a structure of type
     21 /// MEMORY_STATUSCODE_PACKET_HEADER, followed by an array of structures of type
     22 /// MEMORY_STATUSCODE_RECORD.  These GUIDed HOBs record all the information
     23 /// passed into the ReportStatusCode() service of PEI Services Table.
     24 ///
     25 ///  <pre>
     26 ///  Memory status code records packet structure :
     27 ///  +---------------+----------+----------+-----+----------+-----+----------+
     28 ///  | Packet Header | Record 1 | Record 2 | ... + Record n | ... | Record m |
     29 ///  +---------------+----------+----------+-----+----------+-----+----------+
     30 ///                  ^                                 ^                     ^
     31 ///                  +--------- RecordIndex -----------+                     |
     32 ///                  +---------------- MaxRecordsNumber----------------------+
     33 ///  </pre>
     34 ///
     35 #define MEMORY_STATUS_CODE_RECORD_GUID \
     36   { \
     37     0x60cc026, 0x4c0d, 0x4dda, {0x8f, 0x41, 0x59, 0x5f, 0xef, 0x0, 0xa5, 0x2} \
     38   }
     39 
     40 ///
     41 /// A header structure that is followed by an array of records that contain the
     42 /// parameters passed into the ReportStatusCode() service in the PEI Services Table.
     43 ///
     44 typedef struct {
     45   ///
     46   /// Index of the packet.
     47   ///
     48   UINT16  PacketIndex;
     49   ///
     50   /// The number of active records in the packet.
     51   ///
     52   UINT16  RecordIndex;
     53   ///
     54   /// The maximum number of records that the packet can store.
     55   ///
     56   UINT32  MaxRecordsNumber;
     57 } MEMORY_STATUSCODE_PACKET_HEADER;
     58 
     59 ///
     60 /// A header structure that is followed by an array of records that contain the
     61 /// parameters passed into the ReportStatusCode() service in the DXE Services Table.
     62 ///
     63 typedef struct {
     64   ///
     65   /// The index pointing to the last recored being stored.
     66   ///
     67   UINT32   RecordIndex;
     68   ///
     69   /// The number of records being stored.
     70   ///
     71   UINT32   NumberOfRecords;
     72   ///
     73   /// The maximum number of records that can be stored.
     74   ///
     75   UINT32   MaxRecordsNumber;
     76 } RUNTIME_MEMORY_STATUSCODE_HEADER;
     77 
     78 ///
     79 /// A structure that contains the parameters passed into the ReportStatusCode()
     80 /// service in the PEI Services Table.
     81 ///
     82 typedef struct {
     83   ///
     84   /// Status Code type to be reported.
     85   ///
     86   EFI_STATUS_CODE_TYPE   CodeType;
     87 
     88   ///
     89   /// An operation, plus value information about the class and subclass, used to
     90   /// classify the hardware and software entity.
     91   ///
     92   EFI_STATUS_CODE_VALUE  Value;
     93 
     94   ///
     95   /// The enumeration of a hardware or software entity within
     96   /// the system. Valid instance numbers start with the number 1.
     97   ///
     98   UINT32                 Instance;
     99 } MEMORY_STATUSCODE_RECORD;
    100 
    101 extern EFI_GUID gMemoryStatusCodeRecordGuid;
    102 
    103 #endif
    104