ReactOS
0.4.16-dev-533-gc7d1aa3
Functions
power.c File Reference
#include "
scsiport.h
"
Include dependency graph for power.c:
Go to the source code of this file.
Functions
NTSTATUS
NTAPI
ScsiPortDispatchPower
(
_In_
PDEVICE_OBJECT
DeviceObject
,
_Inout_
PIRP
Irp
)
Function Documentation
◆
ScsiPortDispatchPower()
NTSTATUS
NTAPI
ScsiPortDispatchPower
(
_In_
PDEVICE_OBJECT
DeviceObject
,
_Inout_
PIRP
Irp
)
Definition at line
13
of file
power.c
.
16
{
17
PSCSI_PORT_COMMON_EXTENSION
comExt =
DeviceObject
->DeviceExtension;
18
19
if
(comExt->
IsFDO
)
20
{
21
PoStartNextPowerIrp
(
Irp
);
22
IoSkipCurrentIrpStackLocation
(
Irp
);
23
return
PoCallDriver(comExt->
LowerDevice
,
Irp
);
24
}
25
else
26
{
27
PIO_STACK_LOCATION
ioStack =
IoGetCurrentIrpStackLocation
(
Irp
);
28
switch
(ioStack->
MinorFunction
)
29
{
30
case
IRP_MN_SET_POWER
:
31
case
IRP_MN_QUERY_POWER
:
32
Irp
->IoStatus.Status =
STATUS_SUCCESS
;
33
break
;
34
}
35
36
NTSTATUS
status
=
Irp
->IoStatus.Status;
37
PoStartNextPowerIrp
(
Irp
);
38
IoCompleteRequest
(
Irp
,
IO_NO_INCREMENT
);
39
return
status
;
40
}
41
}
IoGetCurrentIrpStackLocation
static PIO_STACK_LOCATION IoGetCurrentIrpStackLocation(PIRP Irp)
Definition:
Bus_PDO_EvalMethod.c:150
NTSTATUS
LONG NTSTATUS
Definition:
precomp.h:26
Irp
_In_ PIRP Irp
Definition:
csq.h:116
IoSkipCurrentIrpStackLocation
#define IoSkipCurrentIrpStackLocation(Irp)
Definition:
ntifs_ex.h:421
IoCompleteRequest
#define IoCompleteRequest
Definition:
irp.c:1240
PoStartNextPowerIrp
VOID NTAPI PoStartNextPowerIrp(IN PIRP Irp)
Definition:
power.c:758
STATUS_SUCCESS
#define STATUS_SUCCESS
Definition:
shellext.h:65
_IO_STACK_LOCATION
Definition:
Bus_PDO_EvalMethod.c:93
_IO_STACK_LOCATION::MinorFunction
UCHAR MinorFunction
Definition:
iotypes.h:3112
_SCSI_PORT_COMMON_EXTENSION
Definition:
scsiport.h:137
_SCSI_PORT_COMMON_EXTENSION::IsFDO
BOOLEAN IsFDO
Definition:
scsiport.h:140
_SCSI_PORT_COMMON_EXTENSION::LowerDevice
PDEVICE_OBJECT LowerDevice
Definition:
scsiport.h:139
status
Definition:
ps.c:97
DeviceObject
_In_ PDEVICE_OBJECT DeviceObject
Definition:
wdfdevice.h:2055
IO_NO_INCREMENT
#define IO_NO_INCREMENT
Definition:
iotypes.h:598
IRP_MN_SET_POWER
#define IRP_MN_SET_POWER
IRP_MN_QUERY_POWER
#define IRP_MN_QUERY_POWER
drivers
storage
port
scsiport
power.c
Generated on Sun Jan 19 2025 06:25:46 for ReactOS by
1.9.6