Help! After installing Windows 8.1, my device fails with error code 19


Authored by Eliyas Yakub [MSFT]

One of the common issues reported in Microsoft answer forum for devices and drivers is: after upgrading to Windows 8.1 or installing software package from a third-party Web site, some devices fail with error code 19 (shown in Device Manager). The error code description is “Windows cannot start this hardware device because its configuration information (in the registry) is incomplete or damaged. To fix this problem you should uninstall and then reinstall the hardware device.”

This error might be caused by incomplete installation/migration of class filter drivers. In this blog, I will suggest a fix for the issue and describe filter drivers.

If you are only interested in fixing the issue, read How to fix code 19 caused by class filters. To apply the fix, you should be familiar with registry editor (regedit.exe) and Device Manager (devmgmt.msc).

I do recommend that you read What are filter drivers, device and class filters… This portion of the post contains technical information about filter drivers and will help you understand the fix.

How to fix code 19 caused by class filter drivers

The fix suggested in this section references terms like device and class filter drivers. If you want to know more about those drivers, read What are filter drivers, device and class filters…

  1. Did you notice this error code after installing certain software? If so, uninstall that software and reboot the system. If the issue is not fixed, go to the next step.
  2. In Device Manager, uninstall the driver. Right-click the device node showing the error and select Uninstall. From the Action menu, select Scan for hardware changes. This will let the system reinstall the drivers for the device. If the error code 19 issue is caused by a device filter driver, then reinstalling the driver might resolve the issue. If the issue is not fixed, go to the next step.
  3. Determine whether a class filter driver is causing the issue.

a. In Device Manager, right-click the device node showing the error and select Properties. On the Details tab, get the class name of the device as shown in this image for the HID-compliant mouse device:

b. Open registry editor (regedit.exe). Find the class key in the registry by walking the list of GUIDs under HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Class. For each GUID see if the class name matches the one you noted in the previous step.

c. Check whether the registry key has any UpperFilters or LowerFilters entries. In the preceding image, the value “mouclass” value indicates the name of service. There might be more than one service listed as filters as shown in this image.

d. For each value listed in UpperFilters, determine whether a matching service key exists in the HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services registry key. In this image, the mouclass service exists and you can see service details on the right side.

e. If the service exists, determine whether the driver file exists in the path specified by the ImagePath entry.

f. If the service is not found in the registry or the driver file is not found, then the device fails with code 19 error. In this case, there is no matching service for the “testfilter” UpperFilter value.

After you have identified the class filter that’s causing the issue, there are two ways you can resolve the issue.

  • Edit the UpperFilters or LowerFilters registry entry and remove the service that’s broken and reboot the system. In this example, I removed the “testfilter” value from UpperFilter and rebooted the system. This will fix the code 19 issue but this is not the ideal solution because you may lose functionality of that filter driver. If removing the filter doesn’t compromise the user experience, then this might be the best option.
  • A software package might have incorrectly installed the filter drivers. To get the name of the provider of the software package, search the internet for the service name or the driver filename, you retrieved in the previous steps. From the provider, you might be able to identify the software package that you installed recently before or after the upgrading to Windows 8.1. With that information, uninstall the software or find the latest update from the IHV/OEM Web site and reinstall it.

What are filter drivers, device and class filters…

Filter drivers are optional drivers that are loaded by the system, along with a set of other drivers (function and bus) required to service a particular hardware. All drivers are loaded in a stack formation and filter drivers are inserted in that stack to modify the data flow to or from the device. The purpose of class filter is to enhance device experience. For example, legacy touchpads have filter drivers that enhance the touchpad experience by supporting gestures.

Categorizing by functionality, there are mainly two types of filter drivers: device and class filters. A device filter applies to a specific instance of the device. In contrast, a class filter is used for all devices that belong to a specific class. For example, the system might load a device filter for a specific device maker (say Microsoft keyboard) or it can load a filter driver for all types of keyboards, irrespective of the maker.

We can also categorize filter drivers based on where there are loaded in the stack of drivers: UpperFilter or LowerFilter.

The location is specified in the device INF and is with respect to the function driver. An UpperFilter is loaded above the function driver and a LowerFilter is always below the function driver. Let’s enhance the image by applying UpperFilter LowerFilter, device, and class drivers:

So to service a single device, the stack of drivers might include several upper or lower filters that are class or device filters.

Important registry keys for filter drivers

Registry settings for device filter drivers are in the device hardware registry key, per device. These entries are under the HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Enum\USB\<device hardware id>:

In the preceding image, LcUvcUpper.sys is an upper device filter used by Microsoft Lifecam device. This filter is loaded above the in-box function driver usbvideo.sys.

The class filter drivers are specified under the HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Classregistry key.

In the preceding image, kbdclass is a Microsoft-provided in-box class filter driver for all keyboard devices. Irrespective of the maker of your keyboard, this filter is always loaded above the function driver (kbdhid.sys) for the device.

Most code 19 issues are due to third-party class filters. For Microsoft-defined classes, class filters are provided by Microsoft. It’s not a good practice for third parties to install class filter because their filter driver could be loaded on drivers from other vendors, creating reliability issues. However, there are third parties that install class filters to enable new scenarios and workaround device issues. The major issue is that they don’t install the filters in a way that system can migrate the drivers cleanly on upgrade.

Instead of using INF file, some create registry settings programmatically, and store the driver file in a private folder instead of copying it to the system32\drivers folder. When filters are installed in a non-standard way, the system fails to migrate the various pieces required for a device stack to work correctly.

Feedback

If you are able to get your issue resolved, please post a comment describing what the issue was – whether service or file was missing – and a description of the product name and filename, so that we can work with the provider to address the problem.

Comments (16)

  1. USB Blog says:

    Here is another customer who ran into code 19 issue. He was able to resolve by removing moufilter.sys.

    answers.microsoft.com/…/50ac7378-d7b7-40ad-a8a1-fa76d74b0955

  2. AmyInNH says:

    Upgrade from 8 to 8.1 trashed my registry.  Why is Microsoft not fixing their registry software such that it prevents poor engineering, such as Norton's, from mangling the registry?  The only notable improvement MS has made in years is preventing the blue screen of death.

    Called MS regarding the code 19 issue and their response was to immediately get me off the phone once the word "driver" was mentioned – not our problem they said.

  3. Michael says:

    I had a problem with laptop. There were 2 official drivers for touch pad. I've installed ELANTECH first, and then found it's enough powerful (I wanted to disable magic gestures). Then I've installed Synaptics driver. And removed ELANTECH.

    2 week tried to fix it (windows restore point not helps). Finally found your post.

    In registry there were 3 filters. Keyboard and touch pad stopped working after reboot.

    Removed one entry which was not in Drivers/ – it helped.

    Great thanks!

  4. Kevin says:

    The issue was created by iTunes  followed the two steps and my cd now works perfectly.

  5. Chris says:

    Not knowing much about computers, I tried to follow the instructions as closely as possible, which is difficult in Windows 8.1.  in the end, I just deleted the upperfilter in the CDROM key thingy and the CD ROM now works.  

  6. Sandro says:

    I can only say thank you. I was having the exact issue with a my VM. Strangely enough, just after a basic reboot, the vmware mouse Upperfilters was showing vmkbd while the services was renamed vmkbd2.

    I have no idea how this happened, but I lost the mouse and I was struggling to find how to fix it.

    I did change the Upperfilters to vmkdb2 and mouclass, restart and it's back working.

    Again thank you, I will post this on my blog, just in case someone else will face it:D

  7. Lee says:

    After a Windows update my keyboard was not functioning.  I had to log into Windows with the on-screen keyboard and found the Code 19 error on the keyboard driver.

    Although I found the instructions a bit hard to follow, I was able to make a change to the registry to get the keyboard functioning.  Initially the UpperFilter was listed as SynTP kbdclass.  I initially tried just deleting the UpperFilter but that did not work. I noticed the driver was only listed as kbdclass so I entered that for the UpperFilter and success.

    Thanks for the blog.

  8. Eirik Olufsen says:

    Thank you alot for this post.

    I did like you said and changed the upper path value from where it said a name that didn't appear in the system class list. from xxxx kbdclass to just kbdclass, and it worked.

    Searched for changes in the device manager. And my device was installed correctly.

  9. okutani@outlook.com says:

    Hi, I have a similar problem on my laptop (Sony VAIO SVT13124CXS), and it says

    This device cannot start. (Code 10)

    STATUS_DEVICE_DATA_ERROR

    on PS/2 mouse property on Device Manager. The touchpad and keyboard had stopped working after the regular windows update (I don't remember what updates exactly they were but I've already been using 8.1 for several months). Some of the upper keys like F4 and F5 responds.  For now, I've been using external USB mouse and keyboard for the last few weeks just to get by. Speakers stop working each time I attempt to delete/update drivers, but it always comes back once I turn the system off.

    I've even reset the whole system to the factory condition, but the problem still persists. Can someone help me?

  10. Martin says:

    Same as Kevin (above) I removed iTunes and immediately my laptop (Lenovo Yoga3) detected my new DVD Drive whereas before I had the Code 19 error and the drive was not detected but seen in Device Manager with the Code 19 error.

    Not sure what happens if I re-install iTunes!!

  11. Kate says:

    I had this problem with my DVD drive. It was working in Nov 2014, but when I next tried it Dec 2014, it failed with a Code 19 error. I looked to see what software had been installed during that time. One of the software updates was iTunes. I saw in a forum somewhere that a user had done "repair" to iTunes via the control panel to fix the problem. So I did this, then restarted computer. And it worked!! The DVD drive and ITunes are both working normally.

  12. Carlos Cohen says:

    Excelente solución, muchas gracias.

  13. Mike says:

    Installing the "wrong" touchpad driver from the Acer site somehow blocked my keyboard and touchpad! I was able to resolve it by working through these steps but I'm a software developer with 25+ years experience … its kind of depressing that in 2014 with Windows 8.1, we are still hacking the registry and looking for driver files …

    Anyway thanks for the advice – a laptop without a working keyboard is basically a brick. Luckily the touch-screen keyboard was still working so I could log on and a USB mouse worked.

  14. Mike Honey - Manga Solutions says:

    I recently struck this issue after installing the "wrong" touchpad driver.  It disabled my touchpad, built-in keyboard and USB keyboard! I was able to find this page (using a USB mouse and touch-screen keyboard) and followed the steps to resolve the issue.

    I am a software developer with 25+ years experience and I found this a challenging task – what chance does the average Windows user have? If you can write these steps up as a methodical process, why is this solution not automated or protection built into Windows so it can't happen in the first place?

    It's a bit depressing to find ourselves in 2015 with self-driving cars, machine learning, hololense etc – yet we are STILL hacking the registry and looking for driver files …

  15. Noel says:

    Thank you, I have solved the same problem by your instructions