ReactOS  0.4.14-dev-323-g6fe6a88
helper.c File Reference
#include "stream.h"
Include dependency graph for helper.c:

Go to the source code of this file.

Functions

NTSTATUS NTAPI CompletionRoutine (IN PDEVICE_OBJECT DeviceObject, IN PIRP Irp, IN PVOID Context)
 
NTSTATUS NTAPI ForwardIrpSynchronous (IN PDEVICE_OBJECT DeviceObject, IN PIRP Irp)
 

Function Documentation

◆ CompletionRoutine()

NTSTATUS NTAPI CompletionRoutine ( IN PDEVICE_OBJECT  DeviceObject,
IN PIRP  Irp,
IN PVOID  Context 
)

Definition at line 14 of file helper.c.

18 {
19  if (Irp->PendingReturned != FALSE)
20  {
22  }
24 }
#define STATUS_MORE_PROCESSING_REQUIRED
Definition: shellext.h:68
_In_ PIRP Irp
Definition: csq.h:116
LONG NTAPI KeSetEvent(IN PKEVENT Event, IN KPRIORITY Increment, IN BOOLEAN Wait)
Definition: eventobj.c:159
#define IO_NO_INCREMENT
Definition: iotypes.h:566

Referenced by ForwardIrpSynchronous().

◆ ForwardIrpSynchronous()

NTSTATUS NTAPI ForwardIrpSynchronous ( IN PDEVICE_OBJECT  DeviceObject,
IN PIRP  Irp 
)

Definition at line 29 of file helper.c.

32 {
33  KEVENT Event;
34  PSTREAM_DEVICE_EXTENSION DeviceExt;
36 
38 
39  /* initialize the notification event */
41 
43 
45 
46  /* now call the driver */
48  /* did the request complete yet */
49  if (Status == STATUS_PENDING)
50  {
51  /* not yet, lets wait a bit */
53  Status = Irp->IoStatus.Status;
54  }
55  return Status;
56 }
#define TRUE
Definition: types.h:120
_In_ PIRP Irp
Definition: csq.h:116
LONG NTSTATUS
Definition: precomp.h:26
NTSTATUS NTAPI KeWaitForSingleObject(IN PVOID Object, IN KWAIT_REASON WaitReason, IN KPROCESSOR_MODE WaitMode, IN BOOLEAN Alertable, IN PLARGE_INTEGER Timeout OPTIONAL)
Definition: wait.c:416
#define IoSetCompletionRoutine(_Irp, _CompletionRoutine, _Context, _InvokeOnSuccess, _InvokeOnError, _InvokeOnCancel)
Definition: irp.cpp:515
FORCEINLINE VOID IoCopyCurrentIrpStackLocationToNext(_Inout_ PIRP Irp)
Definition: iofuncs.h:2820
_In_ PVOID _In_ ULONG Event
Definition: iotypes.h:435
PVOID DeviceExtension
Definition: env_spec_w32.h:418
smooth NULL
Definition: ftsmooth.c:416
#define STATUS_PENDING
Definition: ntstatus.h:82
struct STREAM_DEVICE_EXTENSION * PSTREAM_DEVICE_EXTENSION
NTSTATUS NTAPI CompletionRoutine(IN PDEVICE_OBJECT DeviceObject, IN PIRP Irp, IN PVOID Context)
Definition: helper.c:14
Status
Definition: gdiplustypes.h:24
IN PDEVICE_OBJECT DeviceObject
Definition: fatprocs.h:1560
#define KeInitializeEvent(pEvt, foo, foo2)
Definition: env_spec_w32.h:477
NTSTATUS NTAPI IoCallDriver(IN PDEVICE_OBJECT DeviceObject, IN PIRP Irp)
Definition: irp.c:1218
PDEVICE_OBJECT LowerDeviceObject
Definition: stream.h:27

Referenced by StreamClassStartDevice().