PnpQueryStopDeviceNode
__int64 __fastcall PnpQueryStopDeviceNode(_DEVICE_NODE *DeviceNode, INT64 a2, INT64 a3){
unsigned int Reconfiguration;
char v5;
INT64 v6;
INT64 v7;
_DEVICE_OBJECT *PhysicalDeviceObject;
Reconfiguration = -1073741823;
if( DeviceNode->State == DeviceNodeStarted )
{
if( !(_BYTE)a2 || (PiRebalanceOptOut(DeviceNode), !v5) )
{
if( PnpFindMountableDevice((__int64)DeviceNode->PhysicalDeviceObject, a2, a3) )
{
PnpLockMountableDevice(&DeviceNode->PhysicalDeviceObject->Type, v6, v7);
PipSetDevNodeFlags(DeviceNode, 0x1000000ui64);
}
PoFxActivateDevice(DeviceNode->PhysicalDeviceObject);
PhysicalDeviceObject = DeviceNode->PhysicalDeviceObject;
DeviceNode->StateFlags |= 0x20u;
Reconfiguration = IopQueryReconfiguration(5u, PhysicalDeviceObject);
PipSetDevNodeState(DeviceNode, DeviceNodeQueryStopped);
}
}
return Reconfiguration;
}Referenced by:
PnpQueryRebalanceWorker