UMDF driver update requiring reboot

I’m trying to fix a problem with a driver package. One of the drivers is using UMDF, along with a kernel component. They linked with the UMDF redirector driver WUDFRd.sys; our kernel component is a lower filter to WUDFRd.

The device can be disabled/removed without needing a reboot. But if you try to update the device drivers (either by Device Manager, or by DPinst.dll), it’s unable to override the user mode DLLs which are loaded by the UMDF host process, and thus the file rename is scheduled, and reboot is required.

It appears, that the device update as implemented by Windows, doesn’t disable the devnode before trying to copy the new files. For kernel mode drivers, there is no problem, but for UMDF driver DLLs it’s not going to work.

Is it by design, or I may be doing something wrong?

Could you please try adding the COPYFLG_IN_USE_RENAME flag to your INF? You should not see a reboot required prompt in the scenario you described, once you add that flag.

e.g.
[UMDriverCopy]
MyUmdfDriver.dll,0x00004000 ; COPYFLG_IN_USE_RENAME

The flag is documented here -
http://msdn.microsoft.com/en-us/library/windows/hardware/ff546346(v=vs.85).aspx

Thank you. This seems to do the trick.

I’d appreciate is the documentation for UMDF driver installation was updated to reflect this non-obvious solution, because the issue might be present for all UMDF drivers.

While Microsoft may not care if a QFE or an SP requires reboot, the OEMs are usually unhappy about that. And if you run a chained MSI installation package, it explicitly precludes a reboot.

That’s fair feedback. We’re already looking into addressing this.