Supporting Special Files

Special files include paging files, dump files, and hibernation files. If the target device for your driver is a storage device that the system might use for these files, the driver must do the following:

If your driver calls WdfDeviceSetSpecialFileSupport for a device, and if a special file is open on the device, the framework does not allow the PnP manager to remove or stop the device.

After a driver has called WdfDeviceAddDependentUsageDeviceObject, it can call WdfDeviceRemoveDependentUsageDeviceObject to remove a device's dependency on another device.