mirror of https://github.com/acidanthera/audk.git
Remove NULL_HANDLE. NULL_HANDLE should be replaced with NULL as consistency. For now, only DXE core is using this macro.
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@5836 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
parent
681b5c23c4
commit
4008328a99
|
@ -370,7 +370,7 @@ CoreInstallProtocolInterfaceNotify (
|
||||||
Prot = NULL;
|
Prot = NULL;
|
||||||
Handle = NULL;
|
Handle = NULL;
|
||||||
|
|
||||||
if (*UserHandle != NULL_HANDLE) {
|
if (*UserHandle != NULL) {
|
||||||
Status = CoreHandleProtocol (*UserHandle, Protocol, (VOID **)&ExistingInterface);
|
Status = CoreHandleProtocol (*UserHandle, Protocol, (VOID **)&ExistingInterface);
|
||||||
if (!EFI_ERROR (Status)) {
|
if (!EFI_ERROR (Status)) {
|
||||||
return EFI_INVALID_PARAMETER;
|
return EFI_INVALID_PARAMETER;
|
||||||
|
@ -564,7 +564,7 @@ CoreInstallMultipleProtocolInterfaces (
|
||||||
DeviceHandle = NULL;
|
DeviceHandle = NULL;
|
||||||
DevicePath = Interface;
|
DevicePath = Interface;
|
||||||
Status = CoreLocateDevicePath (&gEfiDevicePathProtocolGuid, &DevicePath, &DeviceHandle);
|
Status = CoreLocateDevicePath (&gEfiDevicePathProtocolGuid, &DevicePath, &DeviceHandle);
|
||||||
if (!EFI_ERROR (Status) && (DeviceHandle != NULL_HANDLE) && IsDevicePathEnd(DevicePath)) {
|
if (!EFI_ERROR (Status) && (DeviceHandle != NULL) && IsDevicePathEnd(DevicePath)) {
|
||||||
Status = EFI_ALREADY_STARTED;
|
Status = EFI_ALREADY_STARTED;
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
@ -1219,7 +1219,7 @@ CoreCloseProtocol (
|
||||||
if (EFI_ERROR (Status)) {
|
if (EFI_ERROR (Status)) {
|
||||||
return Status;
|
return Status;
|
||||||
}
|
}
|
||||||
if (ControllerHandle != NULL_HANDLE) {
|
if (ControllerHandle != NULL) {
|
||||||
Status = CoreValidateHandle (ControllerHandle);
|
Status = CoreValidateHandle (ControllerHandle);
|
||||||
if (EFI_ERROR (Status)) {
|
if (EFI_ERROR (Status)) {
|
||||||
return Status;
|
return Status;
|
||||||
|
|
|
@ -45,7 +45,7 @@ IHANDLE *
|
||||||
protocol.
|
protocol.
|
||||||
|
|
||||||
@return An pointer to IHANDLE if the next Position is not the end of the list.
|
@return An pointer to IHANDLE if the next Position is not the end of the list.
|
||||||
Otherwise,NULL_HANDLE is returned.
|
Otherwise,NULL is returned.
|
||||||
|
|
||||||
**/
|
**/
|
||||||
IHANDLE *
|
IHANDLE *
|
||||||
|
@ -63,7 +63,7 @@ CoreGetNextLocateAllHandles (
|
||||||
protocol.
|
protocol.
|
||||||
|
|
||||||
@return An pointer to IHANDLE if the next Position is not the end of the list.
|
@return An pointer to IHANDLE if the next Position is not the end of the list.
|
||||||
Otherwise,NULL_HANDLE is returned.
|
Otherwise,NULL is returned.
|
||||||
|
|
||||||
**/
|
**/
|
||||||
IHANDLE *
|
IHANDLE *
|
||||||
|
@ -80,7 +80,7 @@ CoreGetNextLocateByRegisterNotify (
|
||||||
protocol.
|
protocol.
|
||||||
|
|
||||||
@return An pointer to IHANDLE if the next Position is not the end of the list.
|
@return An pointer to IHANDLE if the next Position is not the end of the list.
|
||||||
Otherwise,NULL_HANDLE is returned.
|
Otherwise,NULL is returned.
|
||||||
|
|
||||||
**/
|
**/
|
||||||
IHANDLE *
|
IHANDLE *
|
||||||
|
@ -264,7 +264,7 @@ CoreLocateHandle (
|
||||||
protocol.
|
protocol.
|
||||||
|
|
||||||
@return An pointer to IHANDLE if the next Position is not the end of the list.
|
@return An pointer to IHANDLE if the next Position is not the end of the list.
|
||||||
Otherwise,NULL_HANDLE is returned.
|
Otherwise,NULL is returned.
|
||||||
|
|
||||||
**/
|
**/
|
||||||
IHANDLE *
|
IHANDLE *
|
||||||
|
@ -283,7 +283,7 @@ CoreGetNextLocateAllHandles (
|
||||||
//
|
//
|
||||||
// If not at the end of the list, get the handle
|
// If not at the end of the list, get the handle
|
||||||
//
|
//
|
||||||
Handle = NULL_HANDLE;
|
Handle = NULL;
|
||||||
*Interface = NULL;
|
*Interface = NULL;
|
||||||
if (Position->Position != &gHandleList) {
|
if (Position->Position != &gHandleList) {
|
||||||
Handle = CR (Position->Position, IHANDLE, AllHandles, EFI_HANDLE_SIGNATURE);
|
Handle = CR (Position->Position, IHANDLE, AllHandles, EFI_HANDLE_SIGNATURE);
|
||||||
|
@ -303,7 +303,7 @@ CoreGetNextLocateAllHandles (
|
||||||
protocol.
|
protocol.
|
||||||
|
|
||||||
@return An pointer to IHANDLE if the next Position is not the end of the list.
|
@return An pointer to IHANDLE if the next Position is not the end of the list.
|
||||||
Otherwise,NULL_HANDLE is returned.
|
Otherwise,NULL is returned.
|
||||||
|
|
||||||
**/
|
**/
|
||||||
IHANDLE *
|
IHANDLE *
|
||||||
|
@ -317,7 +317,7 @@ CoreGetNextLocateByRegisterNotify (
|
||||||
PROTOCOL_INTERFACE *Prot;
|
PROTOCOL_INTERFACE *Prot;
|
||||||
LIST_ENTRY *Link;
|
LIST_ENTRY *Link;
|
||||||
|
|
||||||
Handle = NULL_HANDLE;
|
Handle = NULL;
|
||||||
*Interface = NULL;
|
*Interface = NULL;
|
||||||
ProtNotify = Position->SearchKey;
|
ProtNotify = Position->SearchKey;
|
||||||
|
|
||||||
|
@ -351,7 +351,7 @@ CoreGetNextLocateByRegisterNotify (
|
||||||
protocol.
|
protocol.
|
||||||
|
|
||||||
@return An pointer to IHANDLE if the next Position is not the end of the list.
|
@return An pointer to IHANDLE if the next Position is not the end of the list.
|
||||||
Otherwise,NULL_HANDLE is returned.
|
Otherwise,NULL is returned.
|
||||||
|
|
||||||
**/
|
**/
|
||||||
IHANDLE *
|
IHANDLE *
|
||||||
|
@ -364,7 +364,7 @@ CoreGetNextLocateByProtocol (
|
||||||
LIST_ENTRY *Link;
|
LIST_ENTRY *Link;
|
||||||
PROTOCOL_INTERFACE *Prot;
|
PROTOCOL_INTERFACE *Prot;
|
||||||
|
|
||||||
Handle = NULL_HANDLE;
|
Handle = NULL;
|
||||||
*Interface = NULL;
|
*Interface = NULL;
|
||||||
for (; ;) {
|
for (; ;) {
|
||||||
//
|
//
|
||||||
|
@ -377,7 +377,7 @@ CoreGetNextLocateByProtocol (
|
||||||
// If not at the end, return the handle
|
// If not at the end, return the handle
|
||||||
//
|
//
|
||||||
if (Link == &Position->ProtEntry->Protocols) {
|
if (Link == &Position->ProtEntry->Protocols) {
|
||||||
Handle = NULL_HANDLE;
|
Handle = NULL;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -448,7 +448,7 @@ CoreLocateDevicePath (
|
||||||
return EFI_INVALID_PARAMETER;
|
return EFI_INVALID_PARAMETER;
|
||||||
}
|
}
|
||||||
|
|
||||||
*Device = NULL_HANDLE;
|
*Device = NULL;
|
||||||
SourcePath = *DevicePath;
|
SourcePath = *DevicePath;
|
||||||
SourceSize = GetDevicePathSize (SourcePath) - sizeof(EFI_DEVICE_PATH_PROTOCOL);
|
SourceSize = GetDevicePathSize (SourcePath) - sizeof(EFI_DEVICE_PATH_PROTOCOL);
|
||||||
|
|
||||||
|
|
|
@ -975,7 +975,7 @@ CoreStartImage (
|
||||||
UINTN SetJumpFlag;
|
UINTN SetJumpFlag;
|
||||||
|
|
||||||
Image = CoreLoadedImageInfo (ImageHandle);
|
Image = CoreLoadedImageInfo (ImageHandle);
|
||||||
if (Image == NULL_HANDLE || Image->Started) {
|
if (Image == NULL || Image->Started) {
|
||||||
return EFI_INVALID_PARAMETER;
|
return EFI_INVALID_PARAMETER;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1143,7 +1143,7 @@ CoreUnloadAndCloseImage (
|
||||||
//
|
//
|
||||||
// Free our references to the image handle
|
// Free our references to the image handle
|
||||||
//
|
//
|
||||||
if (Image->Handle != NULL_HANDLE) {
|
if (Image->Handle != NULL) {
|
||||||
|
|
||||||
Status = CoreLocateHandleBuffer (
|
Status = CoreLocateHandleBuffer (
|
||||||
AllHandles,
|
AllHandles,
|
||||||
|
@ -1289,7 +1289,7 @@ CoreExit (
|
||||||
OldTpl = CoreRaiseTpl (TPL_NOTIFY);
|
OldTpl = CoreRaiseTpl (TPL_NOTIFY);
|
||||||
|
|
||||||
Image = CoreLoadedImageInfo (ImageHandle);
|
Image = CoreLoadedImageInfo (ImageHandle);
|
||||||
if (Image == NULL_HANDLE) {
|
if (Image == NULL) {
|
||||||
Status = EFI_INVALID_PARAMETER;
|
Status = EFI_INVALID_PARAMETER;
|
||||||
goto Done;
|
goto Done;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue