how do i remove toaster class key?

Wang, James H 21 Reputation points
2022-10-27T22:09:49.09+00:00

I install the toaster sample wdfsimple driver (https://github.com/microsoft/windows-driver-samples/tree/main/general/toaster/toastDrv)
(https://learn.microsoft.com/en-us/samples/microsoft/windows-driver-samples/toaster-sample-driver/),
then I removed it with pnputil (devcon was failing).

it leaves the class key:
Computer\HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Class{b85b7c50-6a01-11d2-b841-00c04fad5171}

This prevents re-install of the driver, per INF:

;Abstract:
; INF file for installing toaster device drivers. This is an
; extremely simple form of INF. This one uses one of the system
; defined icon for its class instead of one the provided by the
; toaster class installer DLL. To test this INF, make sure
; the toaster class is not previously installed on the system.
; If it is installed, you must remove the existing Toaster class key
; (HKLM\System\CurrentControlSet\Control\Class{B85B7C50-6A01-11d2-B841-00C04FAD5171})

; from the registry. Otherwise the setup ignores the entire
; [ClassInstall32] section if it finds the toaster class guid
; in the registy.

Regedit only let me the delete the key, even though I apparently have permission to do so.
The driver does not appear to be present and I have rebooted a couple times, as well.

Any clue?

Windows Hardware Performance
Windows Hardware Performance
Windows: A family of Microsoft operating systems that run across personal computers, tablets, laptops, phones, internet of things devices, self-contained mixed reality headsets, large collaboration screens, and other devices.Hardware Performance: Delivering / providing hardware or hardware systems or adjusting / adapting hardware or hardware systems.
1,566 questions
{count} votes

Accepted answer
  1. Doron Holan 1,801 Reputation points
    2022-11-01T18:28:46.373+00:00

    The presence of the class key does NOT prevent re-install of the driver on a device instance. The device specific sections will be evaluated and applied during install. All it prevents is the application of the ClassInstall32 section to the machine's state after the first time the class has been installed.

    0 comments No comments

2 additional answers

Sort by: Most helpful
  1. Wang, James H 21 Reputation points
    2022-11-04T06:08:10.877+00:00

    well, all i can tell you is the driver was not re-installed and no device instances created without removing key.
    my solution was to remove the key.