2 MCA/PMI/INIT Protocol as defined in PI Specification VOLUME 4.
4 This protocol provides services to handle Machine Checks (MCA),
5 Initialization (INIT) events, and Platform Management Interrupt (PMI) events
6 on an Intel Itanium Processor Family based system.
8 Copyright (c) 2009 - 2018, Intel Corporation. All rights reserved.<BR>
9 SPDX-License-Identifier: BSD-2-Clause-Patent
13 #ifndef __MCA_INIT_PMI_PROTOCOL_H__
14 #define __MCA_INIT_PMI_PROTOCOL_H__
17 /// Global ID for the MCA/PMI/INIT Protocol.
19 #define EFI_SAL_MCA_INIT_PMI_PROTOCOL_GUID \
20 { 0xb60dc6e8, 0x3b6f, 0x11d5, {0xaf, 0x9, 0x0, 0xa0, 0xc9, 0x44, 0xa0, 0x5b} }
24 /// Declare forward reference for the Timer Architectural Protocol
26 typedef struct _EFI_SAL_MCA_INIT_PMI_PROTOCOL EFI_SAL_MCA_INIT_PMI_PROTOCOL
;
30 /// MCA Records Structure
35 UINT64 EntryCount
: 16;
36 UINT64 DispatchedCount
: 16;
38 } SAL_MCA_COUNT_STRUCTURE
;
43 Prototype of MCA handler.
45 @param ModuleGlobal The context of MCA Handler
46 @param ProcessorStateParameters The processor state parameters (PSP)
47 @param MinstateBase Base address of the min-state
48 @param RendezvouseStateInformation Rendezvous state information to be passed to
49 the OS on OS MCA entry
50 @param CpuIndex Index of the logical processor
51 @param McaCountStructure Pointer to the MCA records structure
52 @param CorrectedMachineCheck This flag is set to TRUE is the MCA has been
53 corrected by the handler or by a previous handler
55 @retval EFI_SUCCESS Handler successfully returned
60 (EFIAPI
*EFI_SAL_MCA_HANDLER
)(
61 IN VOID
*ModuleGlobal
,
62 IN UINT64 ProcessorStateParameters
,
63 IN EFI_PHYSICAL_ADDRESS MinstateBase
,
64 IN UINT64 RendezvouseStateInformation
,
66 IN SAL_MCA_COUNT_STRUCTURE
*McaCountStructure
,
67 OUT BOOLEAN
*CorrectedMachineCheck
71 Prototype of INIT handler.
73 @param ModuleGlobal The context of INIT Handler
74 @param ProcessorStateParameters The processor state parameters (PSP)
75 @param MinstateBase Base address of the min-state
76 @param McaInProgress This flag indicates if an MCA is in progress
77 @param CpuIndex Index of the logical processor
78 @param McaCountStructure Pointer to the MCA records structure
79 @param DumpSwitchPressed This flag indicates the crash dump switch has been pressed
81 @retval EFI_SUCCESS Handler successfully returned
86 (EFIAPI
*EFI_SAL_INIT_HANDLER
)(
87 IN VOID
*ModuleGlobal
,
88 IN UINT64 ProcessorStateParameters
,
89 IN EFI_PHYSICAL_ADDRESS MinstateBase
,
90 IN BOOLEAN McaInProgress
,
92 IN SAL_MCA_COUNT_STRUCTURE
*McaCountStructure
,
93 OUT BOOLEAN
*DumpSwitchPressed
97 Prototype of PMI handler
99 @param ModuleGlobal The context of PMI Handler
100 @param CpuIndex Index of the logical processor
101 @param PmiVector The PMI vector number as received from the PALE_PMI exit state (GR24)
103 @retval EFI_SUCCESS Handler successfully returned
108 (EFIAPI
*EFI_SAL_PMI_HANDLER
)(
109 IN VOID
*ModuleGlobal
,
115 Register a MCA handler with the MCA dispatcher.
117 @param This The EFI_SAL_MCA_INIT_PMI_PROTOCOL instance
118 @param McaHandler The MCA handler to register
119 @param ModuleGlobal The context of MCA Handler
120 @param MakeFirst This flag specifies the handler should be made first in the list
121 @param MakeLast This flag specifies the handler should be made last in the list
123 @retval EFI_SUCCESS MCA Handle was registered
124 @retval EFI_OUT_OF_RESOURCES No more resources to register an MCA handler
125 @retval EFI_INVALID_PARAMETER Invalid parameters were passed
130 (EFIAPI
*EFI_SAL_REGISTER_MCA_HANDLER
)(
131 IN EFI_SAL_MCA_INIT_PMI_PROTOCOL
*This
,
132 IN EFI_SAL_MCA_HANDLER McaHandler
,
133 IN VOID
*ModuleGlobal
,
134 IN BOOLEAN MakeFirst
,
139 Register an INIT handler with the INIT dispatcher.
141 @param This The EFI_SAL_MCA_INIT_PMI_PROTOCOL instance
142 @param InitHandler The INIT handler to register
143 @param ModuleGlobal The context of INIT Handler
144 @param MakeFirst This flag specifies the handler should be made first in the list
145 @param MakeLast This flag specifies the handler should be made last in the list
147 @retval EFI_SUCCESS INIT Handle was registered
148 @retval EFI_OUT_OF_RESOURCES No more resources to register an INIT handler
149 @retval EFI_INVALID_PARAMETER Invalid parameters were passed
154 (EFIAPI
*EFI_SAL_REGISTER_INIT_HANDLER
)(
155 IN EFI_SAL_MCA_INIT_PMI_PROTOCOL
*This
,
156 IN EFI_SAL_INIT_HANDLER InitHandler
,
157 IN VOID
*ModuleGlobal
,
158 IN BOOLEAN MakeFirst
,
163 Register a PMI handler with the PMI dispatcher.
165 @param This The EFI_SAL_MCA_INIT_PMI_PROTOCOL instance
166 @param PmiHandler The PMI handler to register
167 @param ModuleGlobal The context of PMI Handler
168 @param MakeFirst This flag specifies the handler should be made first in the list
169 @param MakeLast This flag specifies the handler should be made last in the list
171 @retval EFI_SUCCESS PMI Handle was registered
172 @retval EFI_OUT_OF_RESOURCES No more resources to register an PMI handler
173 @retval EFI_INVALID_PARAMETER Invalid parameters were passed
178 (EFIAPI
*EFI_SAL_REGISTER_PMI_HANDLER
)(
179 IN EFI_SAL_MCA_INIT_PMI_PROTOCOL
*This
,
180 IN EFI_SAL_PMI_HANDLER PmiHandler
,
181 IN VOID
*ModuleGlobal
,
182 IN BOOLEAN MakeFirst
,
187 /// This protocol is used to register MCA, INIT and PMI handlers with their respective dispatcher
189 struct _EFI_SAL_MCA_INIT_PMI_PROTOCOL
{
190 EFI_SAL_REGISTER_MCA_HANDLER RegisterMcaHandler
;
191 EFI_SAL_REGISTER_INIT_HANDLER RegisterInitHandler
;
192 EFI_SAL_REGISTER_PMI_HANDLER RegisterPmiHandler
;
193 BOOLEAN McaInProgress
; ///< Whether MCA handler is in progress
194 BOOLEAN InitInProgress
; ///< Whether Init handler is in progress
195 BOOLEAN PmiInProgress
; ///< Whether Pmi handler is in progress
198 extern EFI_GUID gEfiSalMcaInitPmiProtocolGuid
;