Author: ben_p
Subject: Uninstallation of filter driver service without a
Posted: 17 April 2013 at 3:31pm
Hello,
Edited by ben_p - 5 hours 10 minutes ago at 3:50pm
Subject: Uninstallation of filter driver service without a
Posted: 17 April 2013 at 3:31pm
Hello,
There's a problem with a driver we are experiencing. Basically, there's a PnP device and our custom filter driver for it. When we are uninstalling the filter driver service, we are having issues stopping the service. Here's the detailed breakdown of the problem:
1. Disable the PnP device using SetupDiGetClassDevs or devcon.
2. Try to stop our custom filter service using ControlService(..., SERVICE_CONTROL_STOP,...).
The service does not stop straight away but goes to the NOT_STOPPABLE state. After this any command related to this service results in error 1052 returned by GetLastError ("The requested control is not valid for this service."). We assume that the handle of the PnP device is still open and it prevents us from killing the service.
Questions:
Is there any way force the killing of the driver service or is there any way to simulate the PC restart behaviour for the filter driver service and PnP device (as it works fine after a restart).
Currently we are disabling only the device with a specific GUID. Do we need to disable the entire USB stack?
Thanks!
Edited by ben_p - 5 hours 10 minutes ago at 3:50pm