ReactOS  0.4.15-dev-2964-ge2a8585
fxiotargetself.hpp
Go to the documentation of this file.
1 /*++
2 
3 Copyright (c) Microsoft Corporation. All rights reserved.
4 
5 Module Name:
6 
7  FxIoTargetSelf.hpp
8 
9 Abstract:
10 
11  Encapsulation of the Self target to which FxRequest are sent to.
12  FxSelfTarget represents the client itself and is used to send IO to
13  itself.
14 
15  Unlike the the local and remote targets, the IO sent to an Self IO
16  target is routed to the sender's own top level queues. A dedicated queue
17  may also be configured as the target for requests dispatched to the Self
18  Io targets.
19 
20 Author:
21 
22 
23 
24 Environment:
25 
26  Both kernel and user mode
27 
28 Revision History:
29 
30 --*/
31 
32 #ifndef _FXIOTARGETSELF_H_
33 #define _FXIOTARGETSELF_H_
34 
35 class FxIoTargetSelf : public FxIoTarget {
36 
37 public:
38 
40  _In_ PFX_DRIVER_GLOBALS FxDriverGlobals,
41  _In_ USHORT ObjectSize
42  );
43 
44  virtual
49  )
50  /*++
51  Routine Description:
52  Returns the target device object of the Device. In case of an Self
53  Io Target it is the device itself.
54 
55  Arguments:
56 
57  Device - Handle to the Device Object
58 
59  Returns:
60 
61  MdDeviceObject for the Device.
62 
63  --*/
64  {
65  return Device->GetDeviceObject();
66  }
67 
68  FxIoQueue*
71  );
72 
73  VOID
75  _In_ FxIoQueue* DispatchQueue
76  )
77  /*++
78  Routine Description:
79  Sets a disapatch queue for the IO send to the Self IO Target.
80  --*/
81  {
83  m_DispatchQueue = DispatchQueue;
84  }
85 
86  virtual
87  VOID
88  Send(
89  _In_ MdIrp Irp
90  );
91 
92 protected:
93  //
94  // Hide destructor since we are reference counted object
95  //
97 
98 private:
99 
100  //
101  // A Queue configured to dispatch IO sent to the Self IO Target.
102  //
104 
105 };
106 
107 #endif //_FXIOTARGETSELF_H_
FxIoQueue * GetDispatchQueue(_In_ UCHAR MajorFunction)
FxIoQueue * m_DispatchQueue
virtual VOID Send(_In_ MdIrp Irp)
_In_ PIRP Irp
Definition: csq.h:116
VOID SetDispatchQueue(_In_ FxIoQueue *DispatchQueue)
#define _In_
Definition: ms_sal.h:308
IWudfIrp * MdIrp
Definition: mxum.h:103
#define ASSERT(a)
Definition: mode.c:44
unsigned char UCHAR
Definition: xmlstorage.h:181
#define _Must_inspect_result_
Definition: ms_sal.h:558
_Must_inspect_result_ _In_ WDFDEVICE Device
Definition: wdfchildlist.h:474
unsigned short USHORT
Definition: pedump.c:61
virtual _Must_inspect_result_ MdDeviceObject GetTargetDeviceObject(_In_ CfxDeviceBase *Device)
_In_ UCHAR MajorFunction
Definition: wdfdevice.h:1697
#define NULL
Definition: types.h:112
FxIoTargetSelf(_In_ PFX_DRIVER_GLOBALS FxDriverGlobals, _In_ USHORT ObjectSize)