DispatchCreate, DispatchClose, and DispatchCreateClose Routines
A driver's DispatchCreate and DispatchClose routines handle IRPs with I/O function codes of IRP_MJ_CREATE and IRP_MJ_CLOSE, respectively. Alternatively, a combined DispatchCreateClose routine can handle IRPs for both of these I/O function codes.
A create request can originate either from a user-mode subsystem's attempt to get a handle to a file object representing a device (possibly on behalf of an application or subsystem-level driver) or in a higher-level driver's call to IoGetDeviceObjectPointer or IoAttachDevice.
A reciprocal close request originates from a user-mode subsystem's close of the file object handle associated with the driver's device object.
Each of these requests is inherently synchronous.