Cannot unload built-in keyboard on macbook pro(kext unload)

Viewed 1083

Because my keyboard was repeating countlessly several keys without even touching them, i tried to solve the issue by unloading the built-in keyboard and connecting an external keyboard till i find a solution. Therefore, i used kext to unload my keyboard with the following command:

sudo kextunload /System/Library/Extensions/AppleUSBTopCase.kext/Contents/PlugIns/AppleUSBTCKeyboard.kext

However, the terminal returns my this error:

(kernel) Can't remove kext com.apple.driver.AppleUSBTCKeyboard; services failed to terminate - 0xe00002c7.
Failed to unload com.apple.driver.AppleUSBTCKeyboard - (iokit/common) unsupported function.

I googled the error but didn't find much about it. Can someone please help me? :')

1 Answers

It looks like you're running into some new protections in SIP. See csrutil(8) but I think the fix is:

  • Boot to recovery mode by shutting down and then hold ⌘ R.
  • In recovery mode open Terminal by selecting it from utilities in the menu bar
  • Run csrutil disable
  • Reboot and kextunload should work.

Disclaimer: I don't know what you're losing in terms of security by disabling this.

Related