PsRemoveLoadImageNotifyRoutine 函数 (ntddk.h)

PsRemoveLoadImageNotifyRoutine 例程删除由 PsSetLoadImageNotifyRoutine 例程注册的回调例程。

语法

NTSTATUS PsRemoveLoadImageNotifyRoutine(
  [in] PLOAD_IMAGE_NOTIFY_ROUTINE NotifyRoutine
);

参数

[in] NotifyRoutine

指向驱动程序以前通过 PsSetLoadImageNotifyRoutine注册的回调例程的指针。

返回值

PsRemoveLoadImageNotifyRoutine 如果成功删除回调例程,则返回STATUS_SUCCESS;如果 NotifyRoutine 的值与任何已注册的回调例程不匹配,则返回STATUS_PROCEDURE_NOT_FOUND。

言论

如果驱动程序的回调例程当前正在运行,PsRemoveLoadImageNotifyRoutine 等待回调例程退出,然后再将其删除。 因此,回调例程本身不得调用 PsRemoveLoadImageNotifyRoutine

要求

要求 价值
目标平台 普遍
标头 ntddk.h (包括 Ntddk.h)
NtosKrnl.lib
DLL NtosKrnl.exe
IRQL <=APC_LEVEL
DDI 符合性规则 HwStorPortProhibitedDIS(storport)PowerIrpDDis(wdm)

另请参阅

PsSetLoadImageNotifyRoutine