Hi
The DDK Docs is sadly lacking with regards to DIFx docs - as is the case with any newly added technology I guess…
The DIFxAPI call ‘DriverPackageUninstall’ deletes the files/info from a pre-install and optionally deletes the files copied to system32\drivers where the device associated with that pre-install has been connected.
It does NOT uninstall the device. It seems to have been pushed as a replacement to the using setupapi on the DefaultInstall and DefaultUninstall sections of your inf file, but it does not achieve the same thing.
If you call DriverPackageUninstall while the device is connected, and then call the scm’s DeleteService method then your device will be (fully) uninstalled.
If you do *excactly* the same as the above, but having removed the device first then the device will not be uninstalled - rather, when you reconnect it, it will find enough muck left in the registry to enable windows to attempt to load start the device (which of course fails because DriverPackageUninstall trashed the sys/inf file)
MS invented DIFx to make life easier, not more difficult! All the above is on 2K3-R2 SP2
Anyone else had issues with DIFx?
Nigel