ReactOS  0.4.15-dev-3163-gf17c2c0
fxobject.hpp
Go to the documentation of this file.
1 /*++
2 
3 Copyright (c) Microsoft Corporation
4 
5 Module Name:
6 
7  FxObject.hpp
8 
9 Abstract:
10 
11  This is the C++ header for the FxObject
12 
13 Author:
14 
15 
16 
17 
18 Revision History:
19 
20 
21  Made mode agnostic
22 
23  IMPORTANT: Common code must call Initialize method of
24  FxObject before using it
25 
26  Cannot put CreateAndInitialize method on this class as it
27  cannot be instantiated
28 
29 
30 --*/
31 
32 #ifndef _FXOBJECT_H_
33 #define _FXOBJECT_H_
34 
35 extern "C" {
36 
37 #if defined(EVENT_TRACING)
38 #include "FxObject.hpp.tmh"
39 #endif
40 
41 }
42 
43 //
44 // Macros to pass line and file information to AddRef and Release calls.
45 //
46 // NOTE: ADDREF and RELEASE can be used by any class derived from FxObject or
47 // IFxMemory while the OFFSET only works with an FxObject derivation
48 //
49 #define ADDREF(_tag) AddRef(_tag, __LINE__, __FILE__)
50 #define RELEASE(_tag) Release(_tag, __LINE__, __FILE__)
51 
52 #define ADDREF_OFFSET(_tag, offset) AddRefOverride(offset, _tag, __LINE__, __FILE__)
53 #define RELEASE_OFFSET(_tag, offset) ReleaseOverride(offset, _tag, __LINE__, __FILE__)
54 
55 //
56 // This assumes that the bottom 3 bits of an FxObject are clear, ie that the
57 // FxObject is 8 byte aligned. The conversion from and to a handle value
58 // will set / clear these bits as appropriate.
59 //
62  FxHandleFlagMask = 0x7, // bottom 3 bits are free
63 };
64 
65 //
66 // We cannot define FxHandleValueMask as an enumerant in FxHandleFlags because
67 // an enum is limited to sizeof(ULONG), which doesn't work for us on a 64 bit OS
68 //
70 
71 //
72 // The type itself is aligned, but the pointer is not b/c those interested in the
73 // offset do not need it to be aligned.
74 //
75 // The offset is aligned on an 8 byte boundary so that we have the lower 3 bits
76 // of the low byte to use for a bit field
77 //
78 typedef DECLSPEC_ALIGN(8) USHORT WDFOBJECT_OFFSET_ALIGNED;
79 
81 
83  //
84  // We intentionally do not declare a constructor for this structure.
85  // Instead, code should use an inline initializer list. This reduces the
86  // number of cycles on hot paths by removing a funciton call.
87  //
88  // FxQueryInterfaceParams(
89  // PVOID* Object,
90  // WDFTYPE Type
91  // ) :
92  // Type(Type), Object(Object), Offset(0) {if (Object != NULL) *Object = NULL; }}
93 
94  //
95  // Object to query for
96  //
98 
99  //
100  // Type for the object to query for
101  //
103 
104  //
105  // Offset of handle within its owning object. If zero, the Object was the
106  // handle. If not zero, ((PUCHAR) Object)-Offset will yield the owning
107  // Object.
108  //
110 };
111 
112 //
113 // type of object being allocated. An internal object does *NOT*
114 // 1) have its size rounded up to an alignment value
115 // 2) extra size and context header appended to the allocation
116 //
122 };
123 
124 // Ensures that a BOOL type is generated from a flag mask
125 #define FLAG_TO_BOOL(_Flags, _FlagMask) (!!((_Flags) & (_FlagMask)))
126 
130 };
131 
132 //
133 // Defines for FxObject::m_ObjectFlags
134 //
135 // NOTE: if you modify (add, remove, reassign a value) this enum in any way
136 // you must also change FxObject::m_ObjectFlagsByName.* to match your changes!!
137 //
139  FXOBJECT_FLAGS_PASSIVE_CALLBACKS = 0x00000001, // Object must have all callbacks at passive level
140  // implies passive destroy
141  FXOBJECT_FLAGS_NODELETEDDI = 0x00000002, // The WdfObjectDelete DDI is invalid
142  FXOBJECT_FLAGS_DELETECALLED = 0x00000004, // DeleteObject method called
143  FXOBJECT_FLAGS_COMMITTED = 0x00000008, // Commit called
144  FXOBJECT_FLAGS_PASSIVE_DISPOSE = 0x00000010, // Object must be Dispose()'d at passive level
145  FXOBJECT_FLAGS_FORCE_DISPOSE_THREAD = 0x00000020, // Object is always disposed in the dispose thread
146  // UNUSED = 0x00000040,
147  FXOBJECT_FLAGS_HAS_DEBUG = 0x00000080, // has FxObjectDebugExtension before object pointer
148  FXOBJECT_FLAGS_EARLY_DISPOSED_EXT = 0x00000100, // Early disposed externally to the state machine
149  FXOBJECT_FLAGS_TRACE_STATE = 0x00000200, // log state changes to the IFR
152 };
153 
154 //
155 // FxObject state represents whether an object is
156 // tearing down, and what phase its in.
157 //
173 };
174 
183 };
184 
185 // begin_wpp config
186 // CUSTOM_TYPE(FxObjectState, ItemEnum(FxObjectState));
187 // CUSTOM_TYPE(FxObjectDroppedEvent, ItemEnum(FxObjectDroppedEvent));
188 // end_wpp
189 
190 #define DECLARE_INTERNAL_NEW_OPERATOR() \
191  PVOID \
192  __inline \
193  operator new( \
194  __in size_t Size, \
195  __in PFX_DRIVER_GLOBALS FxDriverGlobals \
196  ) \
197  { \
198  return FxObjectHandleAlloc(FxDriverGlobals, \
199  NonPagedPool, \
200  Size, \
201  0, \
202  WDF_NO_OBJECT_ATTRIBUTES,\
203  0, \
204  FxObjectTypeInternal); \
205  }
206 
209 
211 
213 
215 
216  //
217  // Signature lives after all the fields to avoid byte padding if it is
218  // first on 64 bit systems.
219  //
221 
223 };
224 
228 };
229 
230 class UfxObject;
231 
232 class FxObject {
233 
234  friend UfxObject; //UMDF object wrapper
235 
237  friend VOID GetTriageInfo(VOID);
238 
239 private:
240 
241 #if FX_CORE_MODE==FX_CORE_USER_MODE
242 #ifndef INLINE_WRAPPER_ALLOCATION
244 #endif
245 #endif
246 
248 
249  //
250  // This is the already computed value of
251  // WDF_ALIGN_SIZE_UP(sizeof(derived object), MEMORY_ALLOCATION_ALIGNMENT) +
252  // WDF_ALIGN_SIZE_UP(extraContext, MEMORY_ALLOCATION_ALIGNMENT)
253  //
255 
256  // Reference count is operated on with interlocked operations
258 
260 
261  // Flags are protected by m_SpinLock, bits defined by the enum FXOBJECT_FLAGS
262  union {
264 
265  // Each field in this struct correspond to ascending enumerant values
266  // in FXOBJECT_FLAGS.
267  //
268  // NOTE: you should never touch these fields in any code, they are here
269  // strictly for use by the debugger extension so that it doesn't
270  // have to result FXOBJECT_FLAGS enumerant name strings into values.
271  //
272  struct {
284  };
285 
286  //
287  // m_ObjectState is protected by m_SpinLock. Contains values in the
288  // FxObjectState enum.
289  //
291 
292  // List of Child Objects
294 
295  // SpinLock protects m_ObjectState, m_ObjectFlags, m_ChildListHead, and m_ParentObject
297 
298  //
299  // Parent object when this object is a child.
300  //
301  // This is protected by the child objects m_SpinLock
302  //
304 
305  //
306  // Link for when this object is a child
307  //
308  // This is accessed by the parent of this object, and
309  // protected by the parents spinlock.
310  //
312 
313  //
314  //
315  //
317 
318 protected:
319  union {
320  //
321  // This field is set when the object is being contructed or before
322  // Commit() and from then on is read only.
323  //
324  // FxDeviceBase* is used by the core object state machine. Derived
325  // objects might need the fuller FxDevice* (and they can safely get at
326  // it since they know they are a part of the derived FxDevice*).
327  //
330  };
331 
332 private:
334  VOID
335  )
336  {
337  // Always make the caller supply a type and size
338  }
339 
340  // Do not specify argument names
342  VOID,
343  VerifyConstruct,
344  _In_ BOOLEAN
345  );
346 
347  VOID
348  __inline
351  )
352  {
353  m_Refcnt = 1;
355  m_ObjectFlags = 0;
357 
361 
362  m_DeviceBase = NULL;
363 
364  VerifyConstruct(m_Globals, Embedded);
365  }
366 
367  VOID
368  __inline
370  __in FxObjectState NewState
371  )
372  {
376  "Object %p, WDFOBJECT %p transitioning from %!FxObjectState! to "
377  "%!FxObjectState!", this, GetObjectHandleUnchecked(),
378  m_ObjectState, NewState);
379  if (IsDebug()) {
380  FxObjectDebugExtension* pExtension;
381 
382  pExtension = GetDebugExtension();
383  pExtension->StateHistory[
384  InterlockedIncrement(&pExtension->StateHistoryIndex)] =
385  (BYTE) NewState;
386  }
387  }
388 
389  m_ObjectState = (USHORT) NewState;
390  }
391 
392 protected:
393  FxObject(
394  __in WDFTYPE Type,
395  __in USHORT Size,
396  __in PFX_DRIVER_GLOBALS FxDriverGlobals,
398  );
399 
402  VOID
403  )
404  {
405  return CONTAINING_RECORD(this, FxObjectDebugExtension, AllocationStart);
406  }
407 
408  BOOLEAN
410  VOID
411  )
412  {
414  }
415 
416  static
417  PVOID
420  )
421  {
422  if (Object->IsDebug()) {
423  return _GetDebugBase(Object);
424  }
425  else {
426  return (PVOID) Object;
427  }
428  }
429 
430  VOID
433  );
434 
435  virtual
436  VOID
438  VOID
439  )
440  {
441  delete this;
442  }
443 
444  PVOID
445  __inline
447  VOID
448  )
449  {
450  //
451  // We don't support offset handles in the base FxObject implementation.
452  // Offsets are specialized to internal objects of an FxObject
453  //
454  if (m_ObjectSize > 0) {
455  return _ToHandle(this);
456  }
457  else {
458  return NULL;
459  }
460  }
461 
462  VOID
463  __inline
465  VOID
466  )
467  {
469  FxObject *pChild;
470 
471  while (!IsListEmpty(&m_ChildListHead)) {
473 
475 
476  //
477  // Mark entry as unlinked
478  //
480 
481  //
482  // Inform child object of destruction. Object may be gone after return.
483  //
484  pChild->ParentDeleteEvent();
485  }
486  }
487 
488 public:
489 
490 #ifdef INLINE_WRAPPER_ALLOCATION
491 
492 #if FX_CORE_MODE==FX_CORE_USER_MODE
493  static
494  USHORT
495  GetWrapperSize(
496  );
497 
498  virtual
499  PVOID
501  ) = 0;
502 
503 #else
504  static
505  USHORT
506  __inline
507  GetWrapperSize(
508  )
509  {
510  return 0;
511  }
512 
513 #endif
514 
515 #else
516 
517 #if FX_CORE_MODE==FX_CORE_USER_MODE
519 
520  void SetCOMWrapper(__drv_aliasesMem PVOID Wrapper){ m_COMWrapper = Wrapper; }
521 #endif
522 
523 #endif
524 
525  FxObject(
526  __in WDFTYPE Type,
527  __in USHORT Size,
528  __in PFX_DRIVER_GLOBALS FxDriverGlobals
529  );
530 
531  virtual
532  ~FxObject(
533  VOID
534  );
535 
536  PVOID
537  __inline
538  operator new(
539  __in size_t Size,
540  __in PFX_DRIVER_GLOBALS FxDriverGlobals,
542  )
543  {
545 
546  return FxObjectHandleAlloc(FxDriverGlobals,
547  NonPagedPool,
548  Size,
549  0,
551  0,
552  Type);
553  }
554 
555  PVOID
556  __inline
557  operator new(
558  __in size_t Size,
559  __in PFX_DRIVER_GLOBALS FxDriverGlobals,
561  __in USHORT ExtraSize = 0
562  )
563  {
564  return FxObjectHandleAlloc(FxDriverGlobals,
565  NonPagedPool,
566  Size,
567  0,
568  Attributes,
569  ExtraSize,
571  }
572 
573  VOID
574  operator delete(
576  );
577 
578  static
579  FxObject*
582  )
583  {
585  }
586 
587  //
588  // m_ObjectSize contains the size of the object + extra size. m_ObjectSize
589  // was already rounded up to the correct alignment when it was contructed.
590  //
591  #define GET_CONTEXT_HEADER() WDF_PTR_ADD_OFFSET_TYPE(this, m_ObjectSize, FxContextHeader*)
592 
593  VOID
595  VOID
596  )
597  {
598  m_ObjectSize = 0;
599  }
600 
601  PVOID
602  __inline
604  VOID
605  )
606  {
607  ASSERT(GetRefCnt() > 0);
608  return GetObjectHandleUnchecked();
609  }
610 
611  static
612  FxObject*
615  __inout PWDFOBJECT_OFFSET ObjectOffset
616  )
617  {
619 
620  handle = (ULONG_PTR) Handle;
621 
622  //
623  // store the flags and then clear them off so we have a valid value
624  //
627 
628  //
629  // It is assumed the caller has already set the offset to zero
630  //
631  // *ObjectOffset = 0;
632 
633  //
634  // We always apply the mask
635  //
637 
638  if (flags & FxHandleFlagIsOffset) {
639  //
640  // The handle is a pointer to an offset value. Return the offset
641  // to the caller and then compute the object since the pointer
642  // to the offset is part of the object we are returning.
643  //
644  *ObjectOffset = *(PWDFOBJECT_OFFSET) handle;
645 
646  return (FxObject*) (((PUCHAR) handle) - *ObjectOffset);
647  }
648  else {
649  //
650  // No offset, no verification. We pass the FxObject as the handle
651  //
652  return (FxObject*) handle;
653  }
654  }
655 
656  static
657  PVOID
658  __inline
661  )
662  {
663  //
664  // Always XOR the constant. Faster than checking
665  // FxDriverGlobals->FxVerifierHandle.
666  //
667  return (PVOID) (((ULONG_PTR) Object) ^ FxHandleValueMask);
668  }
669 
670  static
671  VOID
672  __inline
676  __in LONG Line,
677  __in PSTR File
678  )
679  {
680  FxObject* pObject;
682 
683  offset = 0;
685 
686  if (offset == 0) {
687  pObject->AddRef(Tag, Line, File);
688  }
689  else {
691  }
692  }
693 
694  static
695  VOID
696  __inline
700  __in LONG Line,
701  __in PSTR File
702  )
703  {
704  FxObject* pObject;
706 
707  offset = 0;
709 
710  if (offset == 0) {
712  }
713  else {
715  }
716  }
717 
718  __inline
721  VOID
722  )
723  {
724  if (m_ObjectSize == 0) {
725  return NULL;
726  }
727  else {
728  return GET_CONTEXT_HEADER();
729  }
730  }
731 
732  __inline
735  VOID
736  )
737  {
738  return m_Globals;
739  }
740 
741  WDFTYPE
743  VOID
744  )
745  {
746  return m_Type;
747  }
748 
749  USHORT
751  VOID
752  )
753  {
754  return m_ObjectSize;
755  }
756 
757  LONG
759  VOID
760  )
761  {
762  return m_Refcnt;
763  }
764 
765  FxTagTracker*
767  VOID
768  )
769  {
770  if (IsDebug()) {
771  return CONTAINING_RECORD(this,
773  AllocationStart)->TagTracker;
774  }
775  else {
776  return NULL;
777  }
778  }
779 
780  CfxDevice*
782  VOID
783  )
784  {
785  return m_Device;
786  }
787 
790  VOID
791  )
792  {
793  return m_DeviceBase;
794  }
795 
796  VOID
798  __in CfxDeviceBase* DeviceBase
799  )
800  {
801  m_DeviceBase = DeviceBase;
802  }
803 
804  static
805  PVOID
808  )
809  {
810  return CONTAINING_RECORD(Object, FxObjectDebugExtension, AllocationStart);
811  }
812 
813  __inline
814  VOID
816  VOID
817  )
818  {
821  }
822  }
823 
824  ULONG
825  __inline
828  __in LONG Line = 0,
830  )
831  {
832  FxTagTracker* pTagTracker;
833  ULONG c;
834 
836 
837  //
838  // Catch the transition from 0 to 1. Since the REF_OBJ starts off at 1,
839  // we should never have to increment to get to this value.
840  //
841  ASSERT(c > 1);
842 
843  pTagTracker = GetTagTracker();
844  if (pTagTracker != NULL) {
845  pTagTracker->UpdateTagHistory(Tag, Line, File, TagAddRef, c);
846  }
847 
848  return c;
849  }
850 
851  virtual
852  ULONG
855  __in LONG Line = 0,
857  )
858  {
859  FxTagTracker* pTagTracker;
860  ULONG c;
861 
862  pTagTracker = GetTagTracker();
863  if (pTagTracker != NULL) {
864  pTagTracker->UpdateTagHistory(Tag, Line, File, TagRelease, m_Refcnt - 1);
865  }
866 
868 
869  if (c == 0) {
870  FinalRelease();
871  }
872 
873  return c;
874  }
875 
876  virtual
877  ULONG
881  __in LONG Line = 0,
883  )
884  {
886 
887  return AddRef(Tag, Line, File);
888  }
889 
890  virtual
891  ULONG
895  __in LONG Line = 0,
897  )
898  {
900 
901  return Release(Tag, Line, File);
902  }
903 
905  virtual
906  NTSTATUS
909  );
910 
911  VOID
913  VOID
914  )
915  {
917  }
918 
919  BOOLEAN
920  __inline
922  VOID
923  )
924  {
926  }
927 
928  VOID
929  __inline
932  )
933  {
934  if (IsTraceState()) {
937  "Object %p, WDFOBJECT %p, state %!FxObjectState! dropping event"
938  " %!FxObjectDroppedEvent!",
940  }
941  }
942 
943  VOID
946  )
947  {
948  //
949  // Object which can have > passive level locks, but needs to be Dispose()'d
950  // at passive level. This means that the object's client cleanup
951  // routines will also be guaranteed to run at passive.
952  //
953  if (State == ObjectLock) {
954  KIRQL oldIrql;
955 
956  m_SpinLock.Acquire(&oldIrql);
958  m_SpinLock.Release(oldIrql);
959  }
960  else {
962  }
963  }
964 
965  //
966  // Sets that the object is a passive level only object who
967  // accesses page-able pool, routines, or has a driver
968  // specified passive constraint on callbacks such as
969  // Cleanup and Destroy.
970  //
971  VOID
974  )
975  {
976  if (State == ObjectLock) {
977  KIRQL oldIrql;
978 
979  m_SpinLock.Acquire(&oldIrql);
981  m_SpinLock.Release(oldIrql);
982  }
983  else {
985  }
986  }
987 
988  VOID
991  )
992  {
993  //
994  // Object must always be disposed in a separate thread
995  // to allow waiting for some outstanding async
996  // operation to complete.
997  //
998  if (State == ObjectLock) {
999  KIRQL oldIrql;
1000 
1001  m_SpinLock.Acquire(&oldIrql);
1003  m_SpinLock.Release(oldIrql);
1004  }
1005  else {
1007  }
1008  }
1009 
1010  BOOLEAN
1013  )
1014  {
1015  BOOLEAN result;
1016  KIRQL oldIrql = PASSIVE_LEVEL;
1017 
1018  if (AcquireLock) {
1019  m_SpinLock.Acquire(&oldIrql);
1020  }
1021 
1023 
1024  if (AcquireLock) {
1025  m_SpinLock.Release(oldIrql);
1026  }
1027 
1028  return result;
1029  }
1030 
1031  BOOLEAN
1034  )
1035  {
1036  BOOLEAN result;
1037  KIRQL oldIrql = PASSIVE_LEVEL;
1038 
1039  if (AcquireLock) {
1040  m_SpinLock.Acquire(&oldIrql);
1041  }
1042 
1044 
1045  if (AcquireLock) {
1046  m_SpinLock.Release(oldIrql);
1047  }
1048 
1049  return result;
1050  }
1051 
1052  BOOLEAN
1055  )
1056  {
1057  BOOLEAN result;
1058  KIRQL oldIrql = PASSIVE_LEVEL;
1059 
1060  if (AcquireLock) {
1061  m_SpinLock.Acquire(&oldIrql);
1062  }
1063 
1065 
1066  if (AcquireLock) {
1067  m_SpinLock.Release(oldIrql);
1068  }
1069 
1070  return result;
1071  }
1072 
1073  VOID
1075  VOID
1076  )
1077  {
1078  //
1079  // Since no client code is accessing the handle yet, we don't need to
1080  // acquire the object state lock to set the flag since this will be
1081  // the only thread touching m_ObjectFlags.
1082  //
1084  }
1085 
1086  BOOLEAN
1088  VOID
1089  )
1090  {
1091  //
1092  // No need to acquire the lock because it is assumed the caller is
1093  // calling on an object whose ref count has gone to zero so there are
1094  // no other callers to contend with who might set this flag or modify
1095  // m_ObjectFlags.
1096  //
1098  }
1099 
1100  VOID
1103  )
1104  {
1105  if (State == ObjectLock) {
1106  KIRQL irql;
1107 
1108  m_SpinLock.Acquire(&irql);
1110  m_SpinLock.Release(irql);
1111  }
1112  else {
1114  }
1115  }
1116 
1117  VOID
1120  )
1121  {
1122  if (State == ObjectLock) {
1123  KIRQL irql;
1124 
1125  m_SpinLock.Acquire(&irql);
1127  m_SpinLock.Release(irql);
1128  }
1129  else {
1131  }
1132  }
1133 
1134  BOOLEAN
1136  VOID
1137  )
1138  {
1139  // No need for lock since its only set in constructor/init
1141  }
1142 
1143  //
1144  // Commit the WDF object before returning handle to the caller.
1145  //
1147  NTSTATUS
1148  Commit(
1150  __out_opt WDFOBJECT* ObjectHandle,
1152  __in BOOLEAN AssignDriverAsDefaultParent = TRUE
1153  );
1154 
1155  VOID
1157  VOID
1158  );
1159 
1160  VOID
1162  VOID
1163  );
1164 
1165  BOOLEAN
1166  EarlyDispose(
1167  VOID
1168  );
1169 
1170  //
1171  // Request that an object be deleted.
1172  //
1173  // This can be the result of a WDF API or a WDM event.
1174  //
1175  virtual
1176  VOID
1177  DeleteObject(
1178  VOID
1179  );
1180 
1181  //
1182  // Invoked by FxObject *once* when the object is either
1183  // being deleted, or rundown due to its parent object
1184  // being deleted.
1185  //
1186  // An object can override this to perform per object
1187  // cleanup if required.
1188  //
1189  // TRUE means that the cleanup callbacks should be called when the function
1190  // returns. FALSE indicates that the caller will take care of calling the
1191  // cleanup callbacks on behalf of the state machine.
1192  //
1193  virtual
1194  BOOLEAN
1195  Dispose(
1196  VOID
1197  );
1198 
1199  //
1200  // Request to make ParentObject the parent for this object.
1201  //
1203  NTSTATUS
1205  __in FxObject* ParentObject
1206  );
1207 
1209  NTSTATUS
1210  AddContext(
1212  __in PVOID* Context,
1214  );
1215 
1216  //
1217  // Request that this Object be removed from the child association
1218  // list for its parent
1219  //
1221  NTSTATUS
1223  VOID
1224  );
1225 
1226  //
1227  // Adds a reference to the parent object pointer if != NULL
1228  //
1230  FxObject*
1232  __in PVOID Tag
1233  );
1234 
1235  //
1236  // This is public to allow debug code to assert that
1237  // an object has been properly disposed either through
1238  // calling DeleteObject, or being disposed by its parent.
1239  //
1240  BOOLEAN
1242  VOID
1243  )
1244  {
1245  KIRQL oldIrql;
1246  BOOLEAN disposed;
1247 
1248  if (m_Globals->FxVerifierOn &&
1250  m_SpinLock.Acquire(&oldIrql);
1251 
1253  disposed = FALSE;
1254  }
1255  else {
1256  //
1257  // Parent is disposing us, or we are being disposed
1258  //
1259  disposed = TRUE;
1260  }
1261 
1262  m_SpinLock.Release(oldIrql);
1263 
1264  return disposed;
1265  }
1266  else {
1267  return TRUE;
1268  }
1269  }
1270 
1271  static
1274  __in PFX_DRIVER_GLOBALS FxDriverGlobals,
1276  )
1277  {
1279  PVOID pObjectBase;
1280 
1281  pObjectBase = _GetBase(Object);
1282 
1283  pHeader = CONTAINING_RECORD(pObjectBase, FX_POOL_HEADER, AllocationStart);
1284 
1285  //
1286  // If PoolTracker is on then do....
1287  //
1288  if (FxDriverGlobals->IsPoolTrackingOn()) {
1289  //
1290  // Decommission this NonPaged Allocation tracker
1291  //
1293  }
1294 
1295  return pHeader;
1296  }
1297 
1299  static
1300  NTSTATUS
1302  __in FxObject* Object,
1304  __in BOOLEAN AutomaticLocking,
1306  __out FxCallbackLock** CallbackLock,
1307  __out_opt FxObject** CallbackLockObject
1308  );
1309 
1310  //
1311  // Implementation for WdfObjectQuery
1312  //
1314  static
1315  NTSTATUS
1316  _ObjectQuery(
1317  _In_ FxObject* Object,
1318  _In_ CONST GUID* Guid,
1321  PVOID QueryBuffer
1322  );
1323 
1324 protected:
1325  VOID
1327  VOID
1328  );
1329 
1330 private:
1331  VOID
1332  FinalRelease(
1333  VOID
1334  );
1335 
1336  //
1337  // This is used by verifier to ensure that DeleteObject
1338  // is only called once.
1339  //
1340  // It must be accessed under the m_SpinLock.
1341  //
1342  // It returns TRUE if this is the first call.
1343  //
1344  BOOLEAN
1346  VOID
1347  )
1348  {
1349  BOOLEAN retval;
1350 
1352 
1354 
1355  return retval;
1356  }
1357 
1358  BOOLEAN
1360  VOID
1361  )
1362  {
1364  }
1365 
1366  BOOLEAN
1368  VOID
1369  )
1370  {
1372  }
1373 
1374  BOOLEAN
1376  VOID
1377  )
1378  {
1380  }
1381 
1382  BOOLEAN
1384  __out_opt PKIRQL PreviousIrql = NULL
1385  )
1386  {
1388  return TRUE;
1389  }
1390  else if (IsPassiveDisposeLocked()) {
1391  //
1392  // Only call KeGetCurrentIrql() if absolutely necessary. It is an
1393  // expensive call and we want to minimize the cycles required when
1394  // destroying an object that requires passive rundown
1395  //
1396 
1397  //
1398  // Cases:
1399  // 1) Caller does not know the current IRQL, so we must query for it
1400  //
1401  // 2) Caller knew prev IRQL, so we used the caller's value
1402  //
1403  if (PreviousIrql == NULL) { // case 1
1405  return TRUE;
1406  }
1407  }
1408  else if (*PreviousIrql != PASSIVE_LEVEL) { // case 2
1409  return TRUE;
1410  }
1411  }
1412 
1413  return FALSE;
1414  }
1415 
1416  VOID
1418  VOID
1419  );
1420 
1421  BOOLEAN
1423  VOID
1424  );
1425 
1426  _Releases_lock_(this->m_SpinLock.m_Lock)
1428  BOOLEAN
1429  PerformEarlyDisposeWorkerAndUnlock(
1432  );
1433 
1434  _Releases_lock_(this->m_SpinLock.m_Lock)
1436  BOOLEAN
1437  PerformDisposingDisposeChildrenLocked(
1440  );
1441 
1442  _Releases_lock_(this->m_SpinLock.m_Lock)
1444  BOOLEAN
1445  DeleteWorkerAndUnlock(
1448  );
1449 
1450  VOID
1452  __in FxObjectState NewDeferedState
1453  );
1454 
1455  VOID
1457  VOID
1458  );
1459 
1460  _Releases_lock_(this->m_SpinLock.m_Lock)
1462  BOOLEAN
1463  DisposeChildrenWorker(
1464  __in FxObjectState NewDeferedState,
1467  );
1468 
1469  _When_(Unlock, _Releases_lock_(this->m_SpinLock.m_Lock))
1471  VOID
1472  DeletedAndDisposedWorkerLocked(
1475  );
1476 
1478  NTSTATUS
1480  VOID
1481  );
1482 
1484  NTSTATUS
1486  __in FxObject* ChildObject
1487  );
1488 
1490  NTSTATUS
1492  __in FxObject* ChildObject
1493  );
1494 
1495  VOID
1497  VOID
1498  );
1499 
1500  VOID
1502  VOID
1503  );
1504 };
1505 
1506 #endif // _FXOBJECT_H_
USHORT GetObjectSize(VOID)
Definition: fxobject.hpp:750
VOID _In_ BOOLEAN Embedded
Definition: fxobject.cpp:164
VOID MarkTraceState(VOID)
Definition: fxobject.hpp:912
__drv_restoresIRQL KIRQL __in BOOLEAN Unlock
Definition: fxobject.hpp:1474
CfxDevice * m_Device
Definition: fxobject.hpp:329
ObjectType
Definition: metafile.c:80
virtual VOID DeleteObject(VOID)
FxObject * pObject
FxObjectDebugExtensionValues
Definition: fxobject.hpp:225
VOID AllocateTagTracker(__in WDFTYPE Type)
Definition: fxobject.cpp:273
VOID __inline SetObjectStateLocked(__in FxObjectState NewState)
Definition: fxobject.hpp:369
USHORT PassiveCallbacks
Definition: fxobject.hpp:273
#define FLAG_TO_BOOL(_Flags, _FlagMask)
Definition: fxobject.hpp:125
USHORT NoDeleteDDI
Definition: fxobject.hpp:274
virtual ULONG Release(__in_opt PVOID Tag=NULL, __in LONG Line=0, __in_opt PSTR File=NULL)
Definition: fxobject.hpp:853
_Must_inspect_result_ NTSTATUS AddChildObjectInternal(__in FxObject *ChildObject)
Definition: fxobject.cpp:703
VOID FinalRelease(VOID)
Definition: fxobject.cpp:207
BOOLEAN FxVerifierOn
Definition: fxglobals.h:420
BOOLEAN __inline IsTraceState(VOID)
Definition: fxobject.hpp:921
FxTagTracker * GetTagTracker(VOID)
Definition: fxobject.hpp:766
_Must_inspect_result_ NTSTATUS RemoveParentAssignment(VOID)
virtual VOID SelfDestruct(VOID)
Definition: fxobject.hpp:437
PVOID m_COMWrapper
Definition: fxobject.hpp:243
_In_ WDFIOTARGET _In_ PWDF_REQUEST_COMPLETION_PARAMS Params
Definition: wdfrequest.h:306
_Must_inspect_result_ NTSTATUS Commit(__in_opt PWDF_OBJECT_ATTRIBUTES Attributes, __out_opt WDFOBJECT *ObjectHandle, __in_opt FxObject *Parent=NULL, __in BOOLEAN AssignDriverAsDefaultParent=TRUE)
Definition: fxobject.cpp:904
GLuint64EXT * result
Definition: glext.h:11304
VOID ProcessDestroy(VOID)
static _Must_inspect_result_ NTSTATUS _GetEffectiveLock(__in FxObject *Object, __in_opt IFxHasCallbacks *Callbacks, __in BOOLEAN AutomaticLocking, __in BOOLEAN PassiveCallbacks, __out FxCallbackLock **CallbackLock, __out_opt FxObject **CallbackLockObject)
Definition: fxobject.cpp:1044
Definition: ntbasedef.h:628
static FxObject * _FromDisposeEntry(__in PSINGLE_LIST_ENTRY Entry)
Definition: fxobject.hpp:580
static PVOID _GetBase(__in FxObject *Object)
Definition: fxobject.hpp:418
USHORT ForceDisposeThread
Definition: fxobject.hpp:278
#define __in_opt
Definition: dbghelp.h:38
#define TRUE
Definition: types.h:120
#define UNREFERENCED_PARAMETER(P)
Definition: ntbasedef.h:317
FxObject * m_ParentObject
Definition: fxobject.hpp:303
#define __drv_restoresIRQL
Definition: driverspecs.h:321
MdLock m_Lock
Definition: mxlock.h:40
unsigned char * PUCHAR
Definition: retypes.h:3
VOID MarkForceDisposeThread(__in FxObjectLockState State=ObjectLock)
Definition: fxobject.hpp:989
LIST_ENTRY m_ChildEntry
Definition: fxobject.hpp:311
_Must_inspect_result_ NTSTATUS AddContext(__in FxContextHeader *Header, __in PVOID *Context, __in PWDF_OBJECT_ATTRIBUTES Attributes)
Definition: fxobject.cpp:605
LONG NTSTATUS
Definition: precomp.h:26
VOID MarkPassiveDispose(__in FxObjectLockState State=ObjectLock)
Definition: fxobject.hpp:944
PVOID GetCOMWrapper()
Definition: fxobject.hpp:518
IN PVOID IN PVOID IN USHORT IN USHORT Size
Definition: pci.h:361
VOID ParentDeleteEvent(VOID)
VOID DeferredDisposeWorkItem(VOID)
KIRQL irql
Definition: wave.h:1
VOID SetDeviceBase(__in CfxDeviceBase *DeviceBase)
Definition: fxobject.hpp:797
ACPI_PHYSICAL_ADDRESS ACPI_SIZE BOOLEAN Warn BOOLEAN Physical UINT32 ACPI_TABLE_HEADER *OutTableHeader ACPI_TABLE_HEADER **OutTable ACPI_HANDLE UINT32 ACPI_WALK_CALLBACK ACPI_WALK_CALLBACK void void **ReturnValue UINT32 ACPI_BUFFER *RetPathPtr ACPI_OBJECT_HANDLER void *Data ACPI_OBJECT_HANDLER void **Data ACPI_STRING ACPI_OBJECT_LIST ACPI_BUFFER *ReturnObjectBuffer ACPI_DEVICE_INFO **ReturnBuffer ACPI_HANDLE Parent
Definition: acpixf.h:728
#define DECLSPEC_SELECTANY
Definition: guiddef.h:40
typedef DECLSPEC_ALIGN(8) USHORT WDFOBJECT_OFFSET_ALIGNED
Definition: ketypes.h:953
MxLock m_SpinLock
Definition: fxobject.hpp:296
#define TRACE_LEVEL_INFORMATION
Definition: storswtr.h:29
_Must_inspect_result_ _In_ WDFOBJECT _In_ CONST GUID _In_ ULONG QueryBufferLength
Definition: wdfobject.h:760
_Must_inspect_result_ FORCEINLINE BOOLEAN IsListEmpty(_In_ const LIST_ENTRY *ListHead)
Definition: rtlfuncs.h:57
BOOLEAN IsPassiveDispose(__in BOOLEAN AcquireLock=TRUE)
Definition: fxobject.hpp:1032
VOID __inline FxPoolRemoveNonPagedAllocateTracker(__in PFX_POOL_TRACKER Tracker)
WDFTYPE GetType(VOID)
Definition: fxobject.hpp:742
VOID __inline Construct(__in BOOLEAN Embedded)
Definition: fxobject.hpp:349
VOID DeleteEarlyDisposedObject(VOID)
FXOBJECT_FLAGS
Definition: fxobject.hpp:138
static PFX_POOL_HEADER _CleanupPointer(__in PFX_DRIVER_GLOBALS FxDriverGlobals, __in FxObject *Object)
Definition: fxobject.hpp:1273
USHORT Committed
Definition: fxobject.hpp:276
_Must_inspect_result_ NTSTATUS RemoveParentAssociation(VOID)
PSINGLE_LIST_ENTRY ple
uint32_t ULONG_PTR
Definition: typedefs.h:65
LONG m_Refcnt
Definition: fxobject.hpp:257
BOOLEAN PerformEarlyDispose(VOID)
BOOLEAN MarkDeleteCalledLocked(VOID)
Definition: fxobject.hpp:1345
BOOLEAN EarlyDispose(VOID)
UCHAR KIRQL
Definition: env_spec_w32.h:591
FxObjectType
Definition: fxobject.hpp:117
struct FxObject::@4525::@4529 m_ObjectFlagsByName
USHORT * PWDFOBJECT_OFFSET
Definition: fxobject.hpp:80
#define __out_opt
Definition: dbghelp.h:65
namespace GUID const ADDRINFOEXW ADDRINFOEXW struct timeval OVERLAPPED LPLOOKUPSERVICE_COMPLETION_ROUTINE HANDLE * handle
Definition: sock.c:82
#define FALSE
Definition: types.h:117
unsigned int UINT32
#define TRACE_LEVEL_VERBOSE
Definition: storswtr.h:30
BOOLEAN IsPassiveDisposeLocked(VOID)
Definition: fxobject.hpp:1367
Definition: Header.h:8
BOOLEAN FxVerifierHandle
Definition: fxglobals.h:441
long LONG
Definition: pedump.c:60
enum FxObjectType UINT32 enum FxWmiInstanceAction UINT32 enum FxDriverObjectUmFlags USHORT enum FxWakeInterruptEvents UINT32 PVOID FxObjectHandleAlloc(__in PFX_DRIVER_GLOBALS FxDriverGlobals, __in POOL_TYPE PoolType, __in size_t Size, __in ULONG Tag, __in_opt PWDF_OBJECT_ATTRIBUTES Attributes, __in USHORT ExtraSize, __in FxObjectType ObjectType)
Definition: handleapi.cpp:163
VOID MarkDisposeOverride(__in FxObjectLockState State=ObjectLock)
Definition: fxobject.hpp:1101
#define __drv_aliasesMem
Definition: btrfs_drv.h:205
PVOID __inline GetObjectHandle(VOID)
Definition: fxobject.hpp:603
FxContextHeader * pHeader
Definition: handleapi.cpp:604
#define __out
Definition: dbghelp.h:62
#define TRACINGOBJECT
Definition: dbgtrace.h:59
unsigned char BOOLEAN
DECLSPEC_ALIGN(MEMORY_ALLOCATION_ALIGNMENT) ULONG AllocationStart[1]
#define _In_
Definition: ms_sal.h:308
FORCEINLINE PLIST_ENTRY RemoveHeadList(_Inout_ PLIST_ENTRY ListHead)
Definition: rtlfuncs.h:128
#define GET_CONTEXT_HEADER()
Definition: fxobject.hpp:591
SINGLE_LIST_ENTRY m_DisposeSingleEntry
Definition: fxobject.hpp:316
USHORT WDFOBJECT_OFFSET
Definition: fxobject.hpp:80
DECLSPEC_SELECTANY const ULONG_PTR FxHandleValueMask
PFLT_MESSAGE_WAITER_QUEUE CONTAINING_RECORD(Csq, DEVICE_EXTENSION, IrpQueue)) -> WaiterQ.mLock) _IRQL_raises_(DISPATCH_LEVEL) VOID NTAPI FltpAcquireMessageWaiterLock(_In_ PIO_CSQ Csq, _Out_ PKIRQL Irql)
Definition: Messaging.c:560
friend UfxObject
Definition: fxobject.hpp:234
VOID MarkPassiveCallbacks(__in FxObjectLockState State=ObjectLock)
Definition: fxobject.hpp:972
_Must_inspect_result_ _In_opt_ PWDF_OBJECT_ATTRIBUTES _In_ _Strict_type_match_ POOL_TYPE _In_opt_ ULONG _In_ _Out_ WDFMEMORY * Memory
Definition: wdfmemory.h:169
VOID MarkCommitted(VOID)
Definition: fxobject.hpp:1074
__in __drv_restoresIRQL KIRQL OldIrql
Definition: fxobject.hpp:1465
FxObject(VOID)
Definition: fxobject.hpp:333
#define ASSERT(a)
Definition: mode.c:44
const struct winhelp_callbacks Callbacks
Definition: callback.c:161
BOOLEAN IsDisposed(VOID)
Definition: fxobject.hpp:1241
static PVOID _GetDebugBase(__in FxObject *Object)
Definition: fxobject.hpp:806
_Must_inspect_result_ _In_ WDFOBJECT _In_ CONST GUID * Guid
Definition: wdfobject.h:760
GLintptr offset
Definition: glext.h:5920
BOOLEAN IsPassiveCallbacks(__in BOOLEAN AcquireLock=TRUE)
Definition: fxobject.hpp:1011
friend FxDisposeList
Definition: fxobject.hpp:236
virtual ULONG AddRefOverride(__in WDFOBJECT_OFFSET Offset, __in_opt PVOID Tag=NULL, __in LONG Line=0, __in_opt PSTR File=NULL)
Definition: fxobject.hpp:878
static _Must_inspect_result_ NTSTATUS _ObjectQuery(_In_ FxObject *Object, _In_ CONST GUID *Guid, _In_ ULONG QueryBufferLength, _Out_writes_bytes_(QueryBufferLength) PVOID QueryBuffer)
Definition: fxobjectkm.cpp:39
BOOLEAN IsNoDeleteDDI(VOID)
Definition: fxobject.hpp:1135
const GLubyte * c
Definition: glext.h:8905
Type
Definition: Type.h:6
#define __drv_when(cond, annotes)
Definition: driverspecs.h:334
BOOLEAN IsCommitted(VOID)
Definition: fxobject.hpp:1087
static __inline KIRQL MxGetCurrentIrql()
Definition: mxgeneralkm.h:86
__in BOOLEAN CanDefer
Definition: fxobject.hpp:1432
USHORT PassiveDispose
Definition: fxobject.hpp:277
USHORT m_ObjectState
Definition: fxobject.hpp:290
GLbitfield flags
Definition: glext.h:7161
VOID UpdateTagHistory(__in PVOID Tag, __in LONG Line, __in_opt PSTR File, __in FxTagRefType RefType, __in ULONG RefCount)
static VOID __inline _ReferenceActual(__in WDFOBJECT Object, __in_opt PVOID Tag, __in LONG Line, __in PSTR File)
Definition: fxobject.hpp:673
__drv_requiresIRQL(DISPATCH_LEVEL)) VOID DeletedAndDisposedWorkerLocked(__in __drv_when(Unlock
Definition: ncftp.h:79
FxObjectDebugExtension * GetDebugExtension(VOID)
Definition: fxobject.hpp:401
struct _SINGLE_LIST_ENTRY * Next
Definition: ntbasedef.h:629
BOOLEAN IsForceDisposeThreadLocked(VOID)
Definition: fxobject.hpp:1375
PVOID __inline GetObjectHandleUnchecked(VOID)
Definition: fxobject.hpp:446
#define InterlockedDecrement
Definition: armddk.h:52
CfxDeviceBase * m_DeviceBase
Definition: fxobject.hpp:328
FxObjectState
Definition: fxobject.hpp:158
pPkgPnp m_DeviceInterfaceLock AcquireLock(pFxDriverGlobals)
VOID ClearEvtCallbacks(VOID)
Definition: fxobject.cpp:360
KIRQL * PKIRQL
Definition: env_spec_w32.h:592
VOID MarkNoDeleteDDI(__in FxObjectLockState State=ObjectLock)
Definition: fxobject.hpp:1118
#define __inout
Definition: dbghelp.h:50
VOID QueueDeferredDisposeLocked(__in FxObjectState NewDeferedState)
Definition: typedefs.h:119
_Must_inspect_result_ NTSTATUS AssignParentObject(__in FxObject *ParentObject)
Definition: fxobject.cpp:529
VOID CallCleanupCallbacks(VOID)
Definition: fxobject.cpp:328
VOID SetNoContextHeader(VOID)
Definition: fxobject.hpp:594
#define PASSIVE_LEVEL
Definition: env_spec_w32.h:693
#define _Must_inspect_result_
Definition: ms_sal.h:558
USHORT EarlyDisposedExt
Definition: fxobject.hpp:281
_Must_inspect_result_ _In_ WDFDEVICE _In_ BOOLEAN _In_opt_ PVOID Tag
Definition: wdfdevice.h:4061
friend VOID GetTriageInfo(VOID)
unsigned char BYTE
Definition: xxhash.c:193
_Must_inspect_result_ _In_ WDFCOLLECTION _In_ WDFOBJECT Object
USHORT m_ObjectSize
Definition: fxobject.hpp:254
CfxDevice * GetDevice(VOID)
Definition: fxobject.hpp:781
Definition: mxlock.h:101
VOID __inline DestroyChildren(VOID)
Definition: fxobject.hpp:464
__inline FxContextHeader * GetContextHeader(VOID)
Definition: fxobject.hpp:720
#define DISPATCH_LEVEL
Definition: env_spec_w32.h:696
_In_ ULONG _In_ ULONG Offset
Definition: ntddpcm.h:101
virtual ULONG ReleaseOverride(__in WDFOBJECT_OFFSET Offset, __in_opt PVOID Tag=NULL, __in LONG Line=0, __in_opt PSTR File=NULL)
Definition: fxobject.hpp:892
LONG GetRefCnt(VOID)
Definition: fxobject.hpp:758
USHORT m_ObjectFlags
Definition: fxobject.hpp:263
static VOID __inline _DereferenceActual(__in WDFOBJECT Object, __in_opt PVOID Tag, __in LONG Line, __in PSTR File)
Definition: fxobject.hpp:697
__inline PFX_DRIVER_GLOBALS GetDriverGlobals(VOID)
Definition: fxobject.hpp:734
#define InterlockedIncrement
Definition: armddk.h:53
WDFTYPE m_Type
Definition: fxobject.hpp:247
unsigned short USHORT
Definition: pedump.c:61
USHORT HasDebug
Definition: fxobject.hpp:280
__inline VOID CallCleanup(VOID)
Definition: fxobject.hpp:815
#define InitializeListHead(ListHead)
Definition: env_spec_w32.h:944
USHORT WDFTYPE
Definition: fxtypes.h:29
signed char * PSTR
Definition: retypes.h:7
DoTraceLevelMessage(pFxDriverGlobals, TRACE_LEVEL_VERBOSE, TRACINGPNP, "Enter, WDFDEVICE %p", Device)
#define FIELD_OFFSET(t, f)
Definition: typedefs.h:255
PFX_DRIVER_GLOBALS m_Globals
Definition: fxobject.hpp:259
#define NULL
Definition: types.h:112
static FxObject * _GetObjectFromHandle(__in WDFOBJECT Handle, __inout PWDFOBJECT_OFFSET ObjectOffset)
Definition: fxobject.hpp:613
#define WDF_NO_OBJECT_ATTRIBUTES
Definition: wdftypes.h:105
_When_(Unlock, _Releases_lock_(this->m_SpinLock.m_Lock)) __drv_when(Unlock
ULONG __inline AddRef(__in_opt PVOID Tag=NULL, __in LONG Line=0, __in_opt PSTR File=NULL)
Definition: fxobject.hpp:826
static PVOID __inline _ToHandle(__in FxObject *Object)
Definition: fxobject.hpp:659
FX_DECLARE_VF_FUNCTION_P1(VOID, VerifyConstruct, _In_ BOOLEAN)
VOID DeleteFromFailedCreate(VOID)
Definition: fxobject.cpp:391
_In_ HANDLE Handle
Definition: extypes.h:390
FxHandleFlags
Definition: fxobject.hpp:60
#define c
Definition: ke_i.h:80
void SetCOMWrapper(__drv_aliasesMem PVOID Wrapper)
Definition: fxobject.hpp:520
FxTagTracker * TagTracker
Definition: fxobject.hpp:208
unsigned int ULONG
Definition: retypes.h:1
USHORT DeleteCalled
Definition: fxobject.hpp:275
#define ULONG_PTR
Definition: config.h:101
FxObjectDroppedEvent
Definition: fxobject.hpp:175
_Releases_lock_(this->m_SpinLock.m_Lock) __drv_requiresIRQL(DISPATCH_LEVEL) BOOLEAN PerformEarlyDisposeWorkerAndUnlock(__in __drv_restoresIRQL KIRQL OldIrql
BOOLEAN IsDebug(VOID)
Definition: fxobject.hpp:409
virtual _Must_inspect_result_ NTSTATUS QueryInterface(__in FxQueryInterfaceParams *Params)
Definition: fxobject.cpp:255
Definition: File.h:15
FxVerifierLock * VerifierLock
Definition: fxobject.hpp:210
virtual BOOLEAN Dispose(VOID)
LIST_ENTRY m_ChildListHead
Definition: fxobject.hpp:293
BOOLEAN ShouldDeferDisposeLocked(__out_opt PKIRQL PreviousIrql=NULL)
Definition: fxobject.hpp:1383
#define __in
Definition: dbghelp.h:35
FxObjectLockState
Definition: fxobject.hpp:127
_Must_inspect_result_ FxObject * GetParentObjectReferenced(__in PVOID Tag)
Definition: fxobject.cpp:856
#define _Out_writes_bytes_(size)
Definition: ms_sal.h:350
BOOLEAN IsPassiveCallbacksLocked(VOID)
Definition: fxobject.hpp:1359
BOOLEAN IsForceDisposeThread(__in BOOLEAN AcquireLock=TRUE)
Definition: fxobject.hpp:1053
#define MEMORY_ALLOCATION_ALIGNMENT
Definition: ntbasedef.h:90
FX_POOL_TRACKER * PFX_POOL_TRACKER
Definition: fxpool.h:107
CfxDeviceBase * GetDeviceBase(VOID)
Definition: fxobject.hpp:789
WDFOBJECT_OFFSET Offset
Definition: fxobject.hpp:109
#define CONST
Definition: pedump.c:81
VOID __inline TraceDroppedEvent(__in FxObjectDroppedEvent Event)
Definition: fxobject.hpp:930
base of all file and directory entries
Definition: entries.h:82
virtual ~FxObject(VOID)
Definition: fxobject.cpp:88
USHORT Unused
Definition: fxobject.hpp:279
USHORT TraceState
Definition: fxobject.hpp:282
_Must_inspect_result_ _In_ WDFDMAENABLER _In_ _In_opt_ PWDF_OBJECT_ATTRIBUTES Attributes
_Must_inspect_result_ NTSTATUS RemoveChildObjectInternal(__in FxObject *ChildObject)
Definition: fxobject.cpp:770