mirror of
https://github.com/reactos/reactos.git
synced 2025-05-18 16:51:18 +00:00
[NDIS]
- Better stub power IRP handling. Failing IRP_MN_SET_POWER is illegal! CORE-10117 svn path=/trunk/; revision=69055
This commit is contained in:
parent
17301d5353
commit
a97581c62d
1 changed files with 19 additions and 0 deletions
|
@ -2398,6 +2398,19 @@ NdisIDispatchPnp(
|
|||
return IoCallDriver(Adapter->NdisMiniportBlock.NextDeviceObject, Irp);
|
||||
}
|
||||
|
||||
NTSTATUS
|
||||
NTAPI
|
||||
NdisIPower(
|
||||
_In_ PDEVICE_OBJECT DeviceObject,
|
||||
_In_ PIRP Irp)
|
||||
{
|
||||
PLOGICAL_ADAPTER Adapter = DeviceObject->DeviceExtension;
|
||||
|
||||
PoStartNextPowerIrp(Irp);
|
||||
IoSkipCurrentIrpStackLocation(Irp);
|
||||
return PoCallDriver(Adapter->NdisMiniportBlock.NextDeviceObject, Irp);
|
||||
}
|
||||
|
||||
NTSTATUS
|
||||
NTAPI
|
||||
NdisIAddDevice(
|
||||
|
@ -2580,6 +2593,12 @@ NdisGenericIrpHandler(
|
|||
{
|
||||
return NdisIDeviceIoControl(DeviceObject, Irp);
|
||||
}
|
||||
else if (IrpSp->MajorFunction == IRP_MJ_POWER)
|
||||
{
|
||||
return NdisIPower(DeviceObject, Irp);
|
||||
}
|
||||
NDIS_DbgPrint(MIN_TRACE, ("Unexpected IRP MajorFunction 0x%x\n", IrpSp->MajorFunction));
|
||||
ASSERT(FALSE);
|
||||
}
|
||||
else if (DeviceObject->DeviceType == FILE_DEVICE_NETWORK)
|
||||
{
|
||||
|
|
Loading…
Reference in a new issue