diff options
author | qhuang8 <qhuang8@6f19259b-4bc3-4df7-8a09-765794883524> | 2008-09-12 01:12:31 +0000 |
---|---|---|
committer | qhuang8 <qhuang8@6f19259b-4bc3-4df7-8a09-765794883524> | 2008-09-12 01:12:31 +0000 |
commit | 7899b7971577075095266cc2af2010f2827e4096 (patch) | |
tree | 6514934da22b6dc4b1af22b87c465a31eedf02dd | |
parent | a8aba574e722ee8ea4e8774348c58bbc25d0959b (diff) | |
download | edk2-7899b7971577075095266cc2af2010f2827e4096.zip edk2-7899b7971577075095266cc2af2010f2827e4096.tar.gz edk2-7899b7971577075095266cc2af2010f2827e4096.tar.bz2 |
Remove the internal CoreCreateProtocolNotifyEvent() in DxeCore, for UefiLib provide the similar function EfiCreateProtocolNotifyEvent(). DxeCore can use that library function.
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@5883 6f19259b-4bc3-4df7-8a09-765794883524
-rw-r--r-- | MdeModulePkg/Core/Dxe/Dispatcher/Dispatcher.c | 5 | ||||
-rw-r--r-- | MdeModulePkg/Core/Dxe/FwVol/FwVol.c | 5 | ||||
-rw-r--r-- | MdeModulePkg/Core/Dxe/Library.h | 26 | ||||
-rw-r--r-- | MdeModulePkg/Core/Dxe/Library/Library.c | 62 |
4 files changed, 4 insertions, 94 deletions
diff --git a/MdeModulePkg/Core/Dxe/Dispatcher/Dispatcher.c b/MdeModulePkg/Core/Dxe/Dispatcher/Dispatcher.c index 0936fad..b2faff1 100644 --- a/MdeModulePkg/Core/Dxe/Dispatcher/Dispatcher.c +++ b/MdeModulePkg/Core/Dxe/Dispatcher/Dispatcher.c @@ -1140,13 +1140,12 @@ CoreInitializeDispatcher ( VOID
)
{
- mFwVolEvent = CoreCreateProtocolNotifyEvent (
+ mFwVolEvent = EfiCreateProtocolNotifyEvent (
&gEfiFirmwareVolume2ProtocolGuid,
TPL_CALLBACK,
CoreFwVolEventProtocolNotify,
NULL,
- &mFwVolEventRegistration,
- TRUE
+ &mFwVolEventRegistration
);
}
diff --git a/MdeModulePkg/Core/Dxe/FwVol/FwVol.c b/MdeModulePkg/Core/Dxe/FwVol/FwVol.c index f62be8f..c236282 100644 --- a/MdeModulePkg/Core/Dxe/FwVol/FwVol.c +++ b/MdeModulePkg/Core/Dxe/FwVol/FwVol.c @@ -511,13 +511,12 @@ FwVolDriverInit ( IN EFI_SYSTEM_TABLE *SystemTable
)
{
- gEfiFwVolBlockEvent = CoreCreateProtocolNotifyEvent (
+ gEfiFwVolBlockEvent = EfiCreateProtocolNotifyEvent (
&gEfiFirmwareVolumeBlockProtocolGuid,
TPL_CALLBACK,
NotifyFwVolBlock,
NULL,
- &gEfiFwVolBlockNotifyReg,
- TRUE
+ &gEfiFwVolBlockNotifyReg
);
return EFI_SUCCESS;
}
diff --git a/MdeModulePkg/Core/Dxe/Library.h b/MdeModulePkg/Core/Dxe/Library.h index c68e62d..0d907d8 100644 --- a/MdeModulePkg/Core/Dxe/Library.h +++ b/MdeModulePkg/Core/Dxe/Library.h @@ -65,30 +65,4 @@ CoreReleaseLock ( );
-/**
- Create a protocol notification event and return it.
-
- @param ProtocolGuid Protocol to register notification event on.
- @param NotifyTpl Maximum TPL to signal the NotifyFunction.
- @param NotifyFunction EFI notification routine.
- @param NotifyContext Context passed into Event when it is created.
- @param Registration Registration key returned from
- RegisterProtocolNotify().
- @param SignalFlag Boolean value to decide whether kick the event after
- register or not.
-
- @return The EFI_EVENT that has been registered to be signaled when a ProtocolGuid
- is added to the system.
-
-**/
-EFI_EVENT
-CoreCreateProtocolNotifyEvent (
- IN EFI_GUID *ProtocolGuid,
- IN EFI_TPL NotifyTpl,
- IN EFI_EVENT_NOTIFY NotifyFunction,
- IN VOID *NotifyContext,
- OUT VOID **Registration,
- IN BOOLEAN SignalFlag
- );
-
#endif
diff --git a/MdeModulePkg/Core/Dxe/Library/Library.c b/MdeModulePkg/Core/Dxe/Library/Library.c index 5ba89fd..19fa2dd 100644 --- a/MdeModulePkg/Core/Dxe/Library/Library.c +++ b/MdeModulePkg/Core/Dxe/Library/Library.c @@ -103,66 +103,4 @@ CoreReleaseLock ( }
-/**
- Create a protocol notification event and return it.
-
- @param ProtocolGuid Protocol to register notification event on.
- @param NotifyTpl Maximum TPL to signal the NotifyFunction.
- @param NotifyFunction EFI notification routine.
- @param NotifyContext Context passed into Event when it is created.
- @param Registration Registration key returned from
- RegisterProtocolNotify().
- @param SignalFlag Boolean value to decide whether kick the event after
- register or not.
-
- @return The EFI_EVENT that has been registered to be signaled when a ProtocolGuid
- is added to the system.
-
-**/
-EFI_EVENT
-CoreCreateProtocolNotifyEvent (
- IN EFI_GUID *ProtocolGuid,
- IN EFI_TPL NotifyTpl,
- IN EFI_EVENT_NOTIFY NotifyFunction,
- IN VOID *NotifyContext,
- OUT VOID **Registration,
- IN BOOLEAN SignalFlag
- )
-{
- EFI_STATUS Status;
- EFI_EVENT Event;
-
- //
- // Create the event
- //
- Status = CoreCreateEvent (
- EVT_NOTIFY_SIGNAL,
- NotifyTpl,
- NotifyFunction,
- NotifyContext,
- &Event
- );
- ASSERT_EFI_ERROR (Status);
-
- //
- // Register for protocol notifactions on this event
- //
- Status = CoreRegisterProtocolNotify (
- ProtocolGuid,
- Event,
- Registration
- );
- ASSERT_EFI_ERROR (Status);
-
- if (SignalFlag) {
- //
- // Kick the event so we will perform an initial pass of
- // current installed drivers
- //
- CoreSignalEvent (Event);
- }
-
- return Event;
-}
-
|