- Export the list of drivers in the table form to a text file using the command:
dism /online /get-drivers /format:table > c:\drivers.txt
Now you can delete all unnecessary drivers with the help of command
pnputil.exe /d oemNN.inf (NN — is a number of drivers file package from drivers.txt, as example oem02.inf). In case the driver is in use, you will see an error while trying delete it.
Add Force to force uninstall it.
pnputil.exe /d oemNN.inf /f