Same machine: on Linux USB works, on FreeBSD 14.5 it doesn't. (Lenovo B50-80)
So I couldn't even install FreeBSD via USB because of this USB error. The error:
Turning off xhci did not help, USB was not working.
Linux works because its xHCI driver has some quirks that allow for the controller to come out of a reset. I guess it has more workarounds for older Intel controllers and is more aggressive about taking ownership from BIOS.
I tried these fixes to no avail:
So I started getting aggressive with workarounds and edited kernel code to allow for a more patient reset.
I actually did two modifications in xhci controller - increased the reset waiting loop by about 50x and changed it to ignore "controller reset timeout" error returned by the controller.
This actually made worked - on boot the controller was stuck on xhci initialization for a few seconds and then initialized it, and USB started to work properly. On shutdown it also lingers for a few more seconds longer before powering off.
This is System Hardware topic, but I feel this is more important for Installation since it precludes USB installs.
Question - can this be patched in kernel, or does FreeBSD make it so strict on purpose? Can this kernel change be made like an option so that the older Intel controllers work? What should I do?
Shoutout to Grok for helping me get USB to work on FreeBSD on Lenovo B50-80.
So I couldn't even install FreeBSD via USB because of this USB error. The error:
Code:
xhci0: <Intel Panther Point USB 3.0 controller> mem 0xb2500000-0xb250ffff irq 7 at device 20.0 on pci0
xhci0: 32 bytes context size, 64-bit DMA
xhci0: Controller reset timeout.
xhci0: XHCI halt/start/probe failed err=18
xhci0: Controller reset timeout.
device_attach: xhci0 attach returned 6
Turning off xhci did not help, USB was not working.
Linux works because its xHCI driver has some quirks that allow for the controller to come out of a reset. I guess it has more workarounds for older Intel controllers and is more aggressive about taking ownership from BIOS.
I tried these fixes to no avail:
Code:
hw.pci.enable_msi=0
hw.pci.enable_msix=0
hw.usb.xhci.route=-1
So I started getting aggressive with workarounds and edited kernel code to allow for a more patient reset.
I actually did two modifications in xhci controller - increased the reset waiting loop by about 50x and changed it to ignore "controller reset timeout" error returned by the controller.
This actually made worked - on boot the controller was stuck on xhci initialization for a few seconds and then initialized it, and USB started to work properly. On shutdown it also lingers for a few more seconds longer before powering off.
This is System Hardware topic, but I feel this is more important for Installation since it precludes USB installs.
Question - can this be patched in kernel, or does FreeBSD make it so strict on purpose? Can this kernel change be made like an option so that the older Intel controllers work? What should I do?
Shoutout to Grok for helping me get USB to work on FreeBSD on Lenovo B50-80.