diff --git a/drivers/storage/port/storport/storport.c b/drivers/storage/port/storport/storport.c index 39c6564c59e..61982fcb77b 100644 --- a/drivers/storage/port/storport/storport.c +++ b/drivers/storage/port/storport/storport.c @@ -996,6 +996,8 @@ StorPortNotification( PFDO_DEVICE_EXTENSION DeviceExtension = NULL; PHW_PASSIVE_INITIALIZE_ROUTINE HwPassiveInitRoutine; PBOOLEAN Result; + PSTOR_DPC Dpc; + PHW_DPC_ROUTINE HwDpcRoutine; va_list ap; DPRINT1("StorPortNotification(%x %p)\n", @@ -1033,6 +1035,19 @@ StorPortNotification( } break; + case InitializeDpc: + DPRINT1("InitializeDpc\n"); + Dpc = (PSTOR_DPC)va_arg(ap, PSTOR_DPC); + DPRINT1("Dpc %p\n", Dpc); + HwDpcRoutine = (PHW_DPC_ROUTINE)va_arg(ap, PHW_DPC_ROUTINE); + DPRINT1("HwDpcRoutine %p\n", HwDpcRoutine); + + KeInitializeDpc((PRKDPC)&Dpc->Dpc, + (PKDEFERRED_ROUTINE)HwDpcRoutine, + (PVOID)DeviceExtension); + KeInitializeSpinLock(&Dpc->Lock); + break; + default: DPRINT1("Unsupported Notification %lx\n", NotificationType); break;