2 Provides the parent dispatch service for a given SMI source generator.
3 The EFI_SMM_ICHN_DISPATCH_PROTOCOL provides the ability to install child handlers for
6 Copyright (c) 2008 - 2009, Intel Corporation
7 All rights reserved. This program and the accompanying materials
8 are licensed and made available under the terms and conditions of the BSD License
9 which accompanies this distribution. The full text of the license may be found at
10 http://opensource.org/licenses/bsd-license.php
12 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
13 WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
15 @par Revision Reference:
16 This Protocol is defined in Framework of EFI SMM Core Interface Spec
21 #ifndef _EFI_SMM_ICHN_DISPATCH_H_
22 #define _EFI_SMM_ICHN_DISPATCH_H_
26 // Global ID for the ICH SMI Protocol
28 #define EFI_SMM_ICHN_DISPATCH_PROTOCOL_GUID \
30 0xc50b323e, 0x9075, 0x4f2a, {0xac, 0x8e, 0xd2, 0x59, 0x6a, 0x10, 0x85, 0xcc } \
33 typedef struct _EFI_SMM_ICHN_DISPATCH_PROTOCOL EFI_SMM_ICHN_DISPATCH_PROTOCOL
;
36 // Related Definitions
39 // ICHN Specific SMIs. These are miscellaneous SMI sources that are supported by the
40 // ICHN specific SMI implementation. These may change over time. TrapNumber is only
41 // valid if the Type is Trap.
45 // NOTE: NEVER delete items from this list/enumeration! Doing so will prevent other versions
46 // of the code from compiling. If the ICH version your driver is written for doesn't support
47 // some of these SMIs, then simply return EFI_UNSUPPORTED when a child/client tries to register
94 // INSERT NEW ITEMS JUST BEFORE THIS LINE
96 NUM_ICHN_TYPES
// the number of items in this enumeration
97 } EFI_SMM_ICHN_SMI_TYPE
;
100 EFI_SMM_ICHN_SMI_TYPE Type
;
101 } EFI_SMM_ICHN_DISPATCH_CONTEXT
;
107 Dispatch function for a ICHN specific SMI handler.
109 @param DispatchHandle Handle of this dispatch function.
110 @param DispatchContext Pointer to the dispatch function's context.
111 The DispatchContext fields are filled in
112 by the dispatching driver prior to
113 invoking this dispatch function.
120 (EFIAPI
*EFI_SMM_ICHN_DISPATCH
)(
121 IN EFI_HANDLE DispatchHandle
,
122 IN EFI_SMM_ICHN_DISPATCH_CONTEXT
*DispatchContext
126 Register a child SMI source dispatch function with a parent SMM driver
128 @param This Pointer to the EFI_SMM_ICHN_DISPATCH_PROTOCOL instance.
129 @param DispatchFunction Function to install.
130 @param DispatchContext Pointer to the dispatch function's context.
131 The caller fills in this context before calling
132 the register function to indicate to the register
133 function the ICHN SMI source for which the dispatch
134 function should be invoked.
135 @param DispatchHandle Handle generated by the dispatcher to track the function
138 @retval EFI_SUCCESS The dispatch function has been successfully
139 registered and the SMI source has been enabled.
140 @retval EFI_DEVICE_ERROR The driver could not enable the SMI source.
141 @retval EFI_OUT_OF_RESOURCES Not enough memory (system or SMM) to manage this
143 @retval EFI_INVALID_PARAMETER DispatchContext is invalid. The ICHN input value
144 is not within valid range.
149 (EFIAPI
*EFI_SMM_ICHN_REGISTER
)(
150 IN EFI_SMM_ICHN_DISPATCH_PROTOCOL
*This
,
151 IN EFI_SMM_ICHN_DISPATCH DispatchFunction
,
152 IN EFI_SMM_ICHN_DISPATCH_CONTEXT
*DispatchContext
,
153 OUT EFI_HANDLE
*DispatchHandle
157 Unregister a child SMI source dispatch function with a parent SMM driver
159 @param This Pointer to the EFI_SMM_ICHN_DISPATCH_PROTOCOL instance.
160 @param DispatchHandle Handle of the service to remove.
162 @retval EFI_SUCCESS The dispatch function has been successfully
163 unregistered and the SMI source has been disabled
164 if there are no other registered child dispatch
165 functions for this SMI source.
166 @retval EFI_INVALID_PARAMETER Handle is invalid.
171 (EFIAPI
*EFI_SMM_ICHN_UNREGISTER
)(
172 IN EFI_SMM_ICHN_DISPATCH_PROTOCOL
*This
,
173 IN EFI_HANDLE DispatchHandle
177 // Interface structure for the SMM ICHN specific SMI Dispatch Protocol
180 Provides the parent dispatch service for a given SMI source generator.
182 struct _EFI_SMM_ICHN_DISPATCH_PROTOCOL
{
183 EFI_SMM_ICHN_REGISTER Register
; ///< Installs a child service to be dispatched by this protocol.
184 EFI_SMM_ICHN_UNREGISTER UnRegister
; ///< Removes a child service dispatched by this protocol.
187 extern EFI_GUID gEfiSmmIchnDispatchProtocolGuid
;