mirror of
https://github.com/reactos/reactos.git
synced 2025-05-07 10:46:58 +00:00
[KBDCLASS][MOUCLASS]
- Forward power IRPs to lower devices. Failing IRP_MN_SET_POWER is illegal! CORE-10117 svn path=/trunk/; revision=69054
This commit is contained in:
parent
9eaf6957f5
commit
17301d5353
2 changed files with 14 additions and 8 deletions
|
@ -193,15 +193,18 @@ IrpStub(
|
|||
IN PIRP Irp)
|
||||
{
|
||||
NTSTATUS Status = STATUS_NOT_SUPPORTED;
|
||||
PPORT_DEVICE_EXTENSION DeviceExtension;
|
||||
|
||||
if (!((PCOMMON_DEVICE_EXTENSION)DeviceObject->DeviceExtension)->IsClassDO)
|
||||
DeviceExtension = DeviceObject->DeviceExtension;
|
||||
if (!DeviceExtension->Common.IsClassDO)
|
||||
{
|
||||
/* Forward some IRPs to lower device */
|
||||
switch (IoGetCurrentIrpStackLocation(Irp)->MajorFunction)
|
||||
{
|
||||
case IRP_MJ_PNP:
|
||||
case IRP_MJ_INTERNAL_DEVICE_CONTROL:
|
||||
return ForwardIrpAndForget(DeviceObject, Irp);
|
||||
case IRP_MJ_POWER:
|
||||
PoStartNextPowerIrp(Irp);
|
||||
IoSkipCurrentIrpStackLocation(Irp);
|
||||
return PoCallDriver(DeviceExtension->LowerDevice, Irp);
|
||||
default:
|
||||
{
|
||||
ERR_(CLASS_NAME, "Port DO stub for major function 0x%lx\n",
|
||||
|
|
|
@ -170,15 +170,18 @@ IrpStub(
|
|||
IN PIRP Irp)
|
||||
{
|
||||
NTSTATUS Status = STATUS_NOT_SUPPORTED;
|
||||
PPORT_DEVICE_EXTENSION DeviceExtension;
|
||||
|
||||
if (!((PCOMMON_DEVICE_EXTENSION)DeviceObject->DeviceExtension)->IsClassDO)
|
||||
DeviceExtension = DeviceObject->DeviceExtension;
|
||||
if (!DeviceExtension->Common.IsClassDO)
|
||||
{
|
||||
/* Forward some IRPs to lower device */
|
||||
switch (IoGetCurrentIrpStackLocation(Irp)->MajorFunction)
|
||||
{
|
||||
case IRP_MJ_PNP:
|
||||
case IRP_MJ_INTERNAL_DEVICE_CONTROL:
|
||||
return ForwardIrpAndForget(DeviceObject, Irp);
|
||||
case IRP_MJ_POWER:
|
||||
PoStartNextPowerIrp(Irp);
|
||||
IoSkipCurrentIrpStackLocation(Irp);
|
||||
return PoCallDriver(DeviceExtension->LowerDevice, Irp);
|
||||
default:
|
||||
{
|
||||
ERR_(CLASS_NAME, "Port DO stub for major function 0x%lx\n",
|
||||
|
|
Loading…
Reference in a new issue