Fix: WDF_VIOLATION Blue screen error in Windows 10/11

Some Windows 10 users are complaining about a bluescreen error on their computer just after receiving an update for their Windows 10 devices. The error code shown upon the BSOD occasion is “WDF_VIOLATION“. This error is usually caused by a driver named “HpqKbFiltr.sys“, renaming which will solve the issue. Simply follow the fixes on your computer and the problem should be solved easily.

 

Fix-1 Rename HpqKbFiltr.sys in Windows RE-

In order to change the name of “HpqKbFiltr.sys” you need to open Windows RE first, then you can change the name bypassing some cmd commands.

1. After opening the Settings window by pressing the Windows Icon+I.

2. Now, click on “Update and Security“.

 

Update And Security

 



3. Then, you need to click on “Recovery“.

4. After that, under ‘Advanced Startup‘, click on “Restart Now“.

 

Advanced Startup

 

Soon your computer will boot into Windows RE.

5. You need to click on the “Troubleshoot“.

troubleshoot min 1

 

6. Then, select the “Advanced options“.

Troubleshoot advanced options min

 

7. When the Advanced options window opens up, click on the “Command Prompt“.

command prompt min 1
command prompt min 1

8. Simply put your account password and click on “Continue“.

Command Prompt window should be opened in Troubleshooting mode.

9. To rename the system file, in Command Prompt window, copy-paste these commands one-by-one, and then hit Enter.

C:
cd C:\Windows\System32\drivers
ren HpqKbFiltr.sys HpqKbFiltr.sys.bak

 

Cmd Hpq Ren

 

Once you have executed the commands, close Command Prompt window.

Reboot your computer back to normal mode again.

If further the problem appears, go for the next fix.

 

Fix-2 Rename MacHALDriver.sys-

MacHALDriver.sys may be another reason you are facing this issue at your end.

1. Open the Windows Recovery Environment just the same as before.

2. You need to click on the “Troubleshoot“.

 

troubleshoot min 1

 

3. In the Troubleshooting window, you have to click on “Advanced options“.

 

Troubleshoot advanced options min

 

4. Then again click on the “Command Prompt“.

 

command prompt min 1

 

5. You need to put the password and click on “Continue” to proceed further.

Command Prompt window should be opened in Troubleshooting mode.

6. You have to change the name of the “MacHALDriver.sys.bak” file.

7. To do so, execute these series of commands in CMD terminal.

C:
cd C:\Windows\System32\drivers
ren MacHALDriver.sys MacHALDriver.sys.bak

 

Cmd Hal Ren

 

Once you have executed the commands, close Command Prompt window.

Reboot your computer back to normal mode again. Your problem should be solved.

NOTE

You may notice some of the keyboard function keys not working.

 

Fix-3  Remove HpqKbFiltr.sys driver-

If renaming the driver is not working for you, removing the driver may be your only chance.

1.  Open the Windows RE again.

2. Then, click on the “Troubleshoot“.

3. Then, what you need to do is to click on “Advanced options“.



4. In the Advanced options window, you have to click on the “Command Prompt“.

5. Once you have put in your account password and click on “Continue“.

7. In Command Prompt window, copy-paste this command  and then hit Enter to execute it on your computer.

dism /Image:C:\ /Remove-Driver/Driver: c:\Windows\System32\driverstore\FileRepository\hpqkbfiltr.inf_amd64_714aca0508a80e9a\HpqKbFiltr.inf

 

Dism 65

 

NOTE

If you are using a 32bit Windows, copy-paste this command in Command Prompt window and then hit Enter.

dism /Image:C\ /Remove-Driver /Driver: C:\Windows\System32\DriverStore\FileRepository\hpqkbfiltr.inf_x86_f1527018cecbb8c2\HpqKbFiltr.inf

 

32 Bit Removal

 

Once you have executed the command, close the Command Prompt window.

Reboot your computer to normal mode again.

You will not face “WDF_ViolationBluescreen error on your computer.

Your problem should be solved.