Laptop keyboard and trackpad not working

Hi everyone.

I'm running FreeBSD 12.2, but my laptop keyboard and trackpad don't work. I can plug in a USB keyboard and mouse and they work fine. I found this in the log file, but couldn't find much to explain the error message or how to fix it.

I'm using a Surface Book.
Intel Core i5-6300U
8GB Ram

Many thanks for any help.

Code:
uhid0: <SINO WEALTH USB KEYBOARD, class 0/0, rev 1.10/1.00, addr 4> on usbus0
uhid1 on uhub1
uhid1: <Microsoft Surface Keyboard, class 0/0, rev 2.10/5.07, addr 5> on usbus0
uhid1: no report descriptor
device_attach: uhid1 attach returned 12
uhid1 on uhub1
uhid1: <Microsoft Surface Keyboard, class 0/0, rev 2.10/5.07, addr 5> on usbus0
uhid1: no report descriptor
device_attach: uhid1 attach returned 12
uhid1 on uhub1
uhid1: <Microsoft Surface Keyboard, class 0/0, rev 2.10/5.07, addr 5> on usbus0
uhid1: no report descriptor
device_attach: uhid1 attach returned 12
axge0 on uhub4
------------------------------------------------------------------------------------------------

EDIT: Found the solution for TTY (doesn't work in Gnome). I'll leave it here for anyone else trying to get into FreeBSD.
The Keyboard and mouse use uhid. The kernel USB drivers need blacklisting for the uhid keyboard.

Find which interface the keyboard is attached to. Mine is on ugen0.4.
# usbconfig
Code:
ugen0.1: <0x8086 XHCI root HUB> at usbus0, cfg=0 md=HOST spd=SUPER (5.0Gbps) pwr=SAVE (0mA)
ugen0.2: <Microsoft USB2.0 Hub> at usbus0, cfg=0 md=HOST spd=HIGH (480Mbps) pwr=SAVE (100mA)
ugen0.3: <VIA Labs, Inc. USB2.0 Hub> at usbus0, cfg=0 md=HOST spd=HIGH (480Mbps) pwr=SAVE (0mA)
ugen0.4: <Microsoft Surface Keyboard> at usbus0, cfg=0 md=HOST spd=FULL (12Mbps) pwr=ON (100mA)
ugen0.5: <SINO WEALTH USB KEYBOARD> at usbus0, cfg=0 md=HOST spd=LOW (1.5Mbps) pwr=ON (100mA)
ugen0.6: <Microsoft USB3.0 Hub> at usbus0, cfg=0 md=HOST spd=SUPER (5.0Gbps) pwr=SAVE (0mA)
ugen0.7: <VIA Labs, Inc. USB3.0 Hub> at usbus0, cfg=0 md=HOST spd=SUPER (5.0Gbps) pwr=SAVE (0mA)
ugen0.8: <ASIX Elec. Corp. AX88179> at usbus0, cfg=0 md=HOST spd=SUPER (5.0Gbps) pwr=ON (124mA)

Get the idVendor and idProduct.
# usbconfig -d ugen.0.4 dump_device_desc
Code:
ugen0.4: <Microsoft Surface Keyboard> at usbus0, cfg=0 md=HOST spd=FULL (12Mbps) pwr=ON (100mA)

  bLength = 0x0012
  bDescriptorType = 0x0001
  bcdUSB = 0x0210
  bDeviceClass = 0x0000  <Probed by interface class>
  bDeviceSubClass = 0x0000
  bDeviceProtocol = 0x0000
  bMaxPacketSize0 = 0x0040
  idVendor = 0x045e
  idProduct = 0x07cd
  bcdDevice = 0x0507
  iManufacturer = 0x0001  <Microsoft>
  iProduct = 0x0002  <Surface Keyboard>
  iSerialNumber = 0x0000  <no string>
  bNumConfigurations = 0x0001

Modify the following line where 0x045e is the idVendor and idProduct is 0x07cd to whatever is in your output.

hw.usb.quirk=0x045e 0x07cd 0xffff UQ_KBD_BOOTPROTO

Add the above line to /boot/loader.conf. Here's mine:

Code:
kern.geom.label.disk_ident.enable="0"
kern.geom.label.gptid.enable="0"
cryptodev_load="YES"
zfs_load="YES"
hw.usb.quirk=0x045e 0x07cd 0xfff UQ_KBD_BOOTPROTO

Install the uhid package.
# pkg install uhidd

Add the following lines to rc.conf. Change the /dev/ugen0.4 to wherever your keyboard is attached based on usbconfig output.
Code:
uhidd_flags="-kmohsu /dev/ugen0.4"
uhidd_enable="YES"
Here's my rc.conf just for reference.
keymap="uk.kbd"
ifconfig_ue0="DHCP"
sshd_enable="YES"
ntpdate_enable="YES"
ntpd_enable="YES"
powerd_enable="YES"
# Set dumpdev to "AUTO" to enable crash dumps, "NO" to disable
dumpdev="AUTO"
zfs_enable="YES"
kld_list="/boot/modules/i915kms.ko"
uhidd_flags="-kmohsu /dev/ugen0.5"
uhidd_enable="YES"
allscreens_flags="-f terminus-b32"

Reboot. Should be working.
---------------------------------------------------------------------------------------
Hi everyone.
I'm running FreeBSD 12.2, but my laptop keyboard and trackpad don't work. I can plug in a USB keyboard and mouse and they work fine. I found this in the log file, but couldn't find much to explain the error message or how to fix it.
I'm using a Surface Book.Intel Core i5-6300U8GB Ram
Many thanks for any help.
Code:
uhid0: <SINO WEALTH USB KEYBOARD, class 0/0, rev 1.10/1.00, addr 4> on usbus0
uhid1 on uhub1
uhid1: <Microsoft Surface Keyboard, class 0/0, rev 2.10/5.07, addr 5> on usbus0
uhid1: no report descriptor
device_attach: uhid1 attach returned 12
uhid1 on uhub1
uhid1: <Microsoft Surface Keyboard, class 0/0, rev 2.10/5.07, addr 5> on usbus0
uhid1: no report descriptor
device_attach: uhid1 attach returned 12
uhid1 on uhub1
uhid1: <Microsoft Surface Keyboard, class 0/0, rev 2.10/5.07, addr 5> on usbus0
uhid1: no report descriptor
device_attach: uhid1 attach returned 12
axge0 on uhub4
 
Last edited:
Now TTY works perfectly but both the keyboard and trackpad are completely unresponsive in Gnome.

Can't see anything wrong in Xorg.0.txt.

USB config gives me only one device - no separate keyboard and trackpad.

Many thanks for any help.

Code:
ugen0.1: <0x8086 XHCI root HUB> at usbus0, cfg=0 md=HOST spd=SUPER (5.0Gbps) pwr=SAVE (0mA)
ugen0.2: <Microsoft USB2.0 Hub> at usbus0, cfg=0 md=HOST spd=HIGH (480Mbps) pwr=SAVE (100mA)
ugen0.3: <VIA Labs, Inc. USB2.0 Hub> at usbus0, cfg=0 md=HOST spd=HIGH (480Mbps) pwr=SAVE (0mA)
ugen0.4: <SINO WEALTH USB KEYBOARD> at usbus0, cfg=0 md=HOST spd=LOW (1.5Mbps) pwr=ON (100mA)
ugen0.5: <Microsoft Surface Keyboard> at usbus0, cfg=0 md=HOST spd=FULL (12Mbps) pwr=ON (100mA)
ugen0.6: <Microsoft USB3.0 Hub> at usbus0, cfg=0 md=HOST spd=SUPER (5.0Gbps) pwr=SAVE (0mA)
ugen0.7: <VIA Labs, Inc. USB3.0 Hub> at usbus0, cfg=0 md=HOST spd=SUPER (5.0Gbps) pwr=SAVE (0mA)
ugen0.8: <ASIX Elec. Corp. AX88179> at usbus0, cfg=0 md=HOST spd=SUPER (5.0Gbps) pwr=ON (124mA)
 

Attachments

  • 40-libinput.conf
    1.4 KB · Views: 160
  • Xorg.0.txt
    29.1 KB · Views: 130
  • rc.conf
    350 bytes · Views: 137
  • loader.conf
    157 bytes · Views: 122
Don't post multiple threads about the same issue. Threads merged.
 
I'm having the same issue on the surface book 3

When I run #usbconfig I don't even get <Microsoft Surface Keyboard>

The only device I get similar to the post above is identified as a wireless controller

output from usbconfig
Code:
ugen1.1: <Intel XHCI root HUB> at usbus1, cfg=0 md=HOST spd=SUPER (5.0Gbps) pwr=SAVE (0mA)
ugen0.1: <Intel XHCI root HUB> at usbus0, cfg=0 md=HOST spd=SUPER (5.0Gbps) pwr=SAVE (0mA)
ugen1.2: <GenesysLogic USB2.1 Hub> at usbus1, cfg=0 md=HOST spd=HIGH (480Mbps) pwr=SAVE (0mA)
ugen1.3: <GenesysLogic USB2.1 Hub> at usbus1, cfg=0 md=HOST spd=HIGH (480Mbps) pwr=SAVE (0mA)
ugen1.6: <vendor 0x8087 product 0x0026> at usbus1, cfg=0 md=HOST spd=FULL (12Mbps) pwr=ON (100mA)
ugen1.7: <GenesysLogic USB3.2 Hub> at usbus1, cfg=0 md=HOST spd=SUPER (5.0Gbps) pwr=SAVE (0mA)
ugen1.8: <GenesysLogic USB3.2 Hub> at usbus1, cfg=0 md=HOST spd=SUPER (5.0Gbps) pwr=SAVE (0mA)
ugen1.4: <CHICONY USB Keyboard> at usbus1, cfg=0 md=HOST spd=LOW (1.5Mbps) pwr=ON (100mA)
ugen1.5: <vendor 0x0000 USB OPTICAL MOUSE> at usbus1, cfg=0 md=HOST spd=LOW (1.5Mbps) pwr=ON (100mA)

output from #usbconfig -d ugen1.6 dump_all_desc

Code:
bLength = 0x0012 
  bDescriptorType = 0x0001 
  bcdUSB = 0x0201 
  bDeviceClass = 0x00e0  <Wireless controller>
  bDeviceSubClass = 0x0001 
  bDeviceProtocol = 0x0001 
  bMaxPacketSize0 = 0x0040 
  idVendor = 0x8087 
  idProduct = 0x0026 
  bcdDevice = 0x0002 
  iManufacturer = 0x0000  <no string>
  iProduct = 0x0000  <no string>
  iSerialNumber = 0x0000  <no string>
  bNumConfigurations = 0x0001
 
Back
Top