TianoCore EDK2 master
Loading...
Searching...
No Matches
MmSmiHandlerProfileLib.c
Go to the documentation of this file.
1
10#include <PiMm.h>
14
15SMI_HANDLER_PROFILE_PROTOCOL *mSmiHandlerProfile;
16
38EFIAPI
40 IN EFI_GUID *HandlerGuid,
41 IN EFI_SMM_HANDLER_ENTRY_POINT2 Handler,
42 IN PHYSICAL_ADDRESS CallerAddress,
43 IN VOID *Context OPTIONAL,
44 IN UINTN ContextSize OPTIONAL
45 )
46{
47 if (mSmiHandlerProfile != NULL) {
48 return mSmiHandlerProfile->RegisterHandler (mSmiHandlerProfile, HandlerGuid, Handler, CallerAddress, Context, ContextSize);
49 }
50
51 return EFI_UNSUPPORTED;
52}
53
72EFIAPI
74 IN EFI_GUID *HandlerGuid,
75 IN EFI_SMM_HANDLER_ENTRY_POINT2 Handler,
76 IN VOID *Context OPTIONAL,
77 IN UINTN ContextSize OPTIONAL
78 )
79{
80 if (mSmiHandlerProfile != NULL) {
81 return mSmiHandlerProfile->UnregisterHandler (mSmiHandlerProfile, HandlerGuid, Handler, Context, ContextSize);
82 }
83
84 return EFI_UNSUPPORTED;
85}
86
94 VOID
95 )
96{
97 gMmst->MmLocateProtocol (
98 &gSmiHandlerProfileGuid,
99 NULL,
100 (VOID **)&mSmiHandlerProfile
101 );
102 return EFI_SUCCESS;
103}
UINT64 UINTN
#define NULL
Definition: Base.h:319
#define IN
Definition: Base.h:279
EFI_STATUS EFIAPI SmiHandlerProfileRegisterHandler(IN EFI_GUID *HandlerGuid, IN EFI_SMM_HANDLER_ENTRY_POINT2 Handler, IN PHYSICAL_ADDRESS CallerAddress, IN VOID *Context OPTIONAL, IN UINTN ContextSize OPTIONAL)
EFI_STATUS MmSmiHandlerProfileLibInitialization(VOID)
EFI_STATUS EFIAPI SmiHandlerProfileUnregisterHandler(IN EFI_GUID *HandlerGuid, IN EFI_SMM_HANDLER_ENTRY_POINT2 Handler, IN VOID *Context OPTIONAL, IN UINTN ContextSize OPTIONAL)
RETURN_STATUS EFI_STATUS
Definition: UefiBaseType.h:29
#define EFI_SUCCESS
Definition: UefiBaseType.h:112
Definition: Base.h:213