Bug 1212365 - VL805/806 xHCI USB 3.0 Controller driver not working on opensuse Tumbleweed
Summary: VL805/806 xHCI USB 3.0 Controller driver not working on opensuse Tumbleweed
Status: IN_PROGRESS
Alias: None
Product: openSUSE Tumbleweed
Classification: openSUSE
Component: Kernel (show other bugs)
Version: Current
Hardware: x86-64 openSUSE Tumbleweed
: P5 - None : Major (vote)
Target Milestone: ---
Assignee: openSUSE Kernel Bugs
QA Contact: E-mail List
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2023-06-14 11:57 UTC by Michał Szczepaniak
Modified: 2023-07-20 10:05 UTC (History)
3 users (show)

See Also:
Found By: ---
Services Priority:
Business Priority:
Blocker: ---
Marketing QA Status: ---
IT Deployment: ---
oneukum: needinfo? (m.szczepaniak.000)


Attachments
lspci -v output (26.72 KB, text/plain)
2023-06-14 14:06 UTC, Michał Szczepaniak
Details
lspci -vn (20.06 KB, text/plain)
2023-06-14 14:25 UTC, Michał Szczepaniak
Details
Revert the obvious suspect (2.70 KB, patch)
2023-06-15 10:23 UTC, Oliver Neukum
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Michał Szczepaniak 2023-06-14 11:57:32 UTC
I've got VL805/806 xHCI USB 3.0 Controller, pci id 1106:3483, and it works in the bios but doesn't work in opensuse. According to this website https://linux-hardware.org/?id=pci:1106-3483-1106-3483 it doesn't work ONLY on opensuse Tumbleweed, which I'm using. Shows up in lspci, but no info whatsoever in dmesg when connecting usb devices. In dmesg I'm also getting

[    0.754373] pci 0000:0b:00.0: xHCI HW did not halt within 32000 usec status = 0x1000
[    0.754419] pci 0000:0b:00.0: quirk_usb_early_handoff+0x0/0x7a0 took 31459 usecs
[    2.228048] xhci_hcd 0000:0b:00.0: xHCI Host Controller
[    2.228053] xhci_hcd 0000:0b:00.0: new USB bus registered, assigned bus number 7
[    2.260073] xhci_hcd 0000:0b:00.0: Host halt failed, -110
[    2.260079] xhci_hcd 0000:0b:00.0: can't setup: -110
[    2.260551] xhci_hcd 0000:0b:00.0: USB bus 7 deregistered
[    2.260624] xhci_hcd 0000:0b:00.0: init 0000:0b:00.0 fail, -110
[    2.260639] xhci_hcd: probe of 0000:0b:00.0 failed with error -110

I've done a bit of kernel development so I'm free to help as much as I can to get it resolved :) Hope you can help me
Comment 1 Oliver Neukum 2023-06-14 14:04:14 UTC
The log tells us what is happening but not why. Is this on a Raspberry? The device is known to be quirky and initialization has been canged comparatively recently. Please also provide the output of "lspci -v"
Comment 2 Michał Szczepaniak 2023-06-14 14:06:50 UTC
Created attachment 867574 [details]
lspci -v output

It's not raspberry pi, it's a pciex1 card that I've purchased
Comment 3 Oliver Neukum 2023-06-14 14:23:35 UTC
Please also provide te output of "lspci -vn"
Comment 4 Michał Szczepaniak 2023-06-14 14:25:42 UTC
Created attachment 867575 [details]
lspci -vn
Comment 5 Oliver Neukum 2023-06-15 09:21:01 UTC
As this is a regression, the obvious culprit is
5255660b208aebfdb71d574f3952cf48392f4306 ("xhci: add quirk for host controllers that don't update endpoint DCS")
Comment 6 Oliver Neukum 2023-06-15 10:23:09 UTC
Created attachment 867594 [details]
Revert the obvious suspect
Comment 7 Michał Szczepaniak 2023-06-15 10:24:34 UTC
I could create branch on obs and apply the patch to test it or do you want me to do it some other way?
Comment 8 Oliver Neukum 2023-06-15 10:26:37 UTC
(In reply to Michał Szczepaniak from comment #7)
> I could create branch on obs and apply the patch to test it or do you want
> me to do it some other way?

Yes, it is fine to test this with a kernel generated in obs.
Comment 9 Michał Szczepaniak 2023-06-15 14:28:41 UTC
Obvious suspect is the correct one :) It works now. Now we need to detain the suspect!
Comment 10 Oliver Neukum 2023-06-19 12:35:03 UTC
OK, this needs to go upstream. Please provide the output of "lspci -vvvn" for meto include in the upstream changelog.
Comment 11 Michał Szczepaniak 2023-06-19 12:39:46 UTC
without pasting entire thing i think this is what you need

0b:00.0 0c03: 1106:3483 (rev 01) (prog-if 30 [XHCI])
        Subsystem: 1106:3483
        Control: I/O+ Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- Stepping- SERR- FastB2B- DisINTx+
        Status: Cap+ 66MHz- UDF- FastB2B- ParErr- DEVSEL=fast >TAbort- <TAbort- <MAbort- >SERR- <PERR- INTx-
        Latency: 0, Cache Line Size: 64 bytes
        Interrupt: pin A routed to IRQ 66
        Region 0: Memory at fb400000 (64-bit, non-prefetchable) [size=4K]
        Capabilities: [80] Power Management version 3
                Flags: PMEClk- DSI- D1- D2- AuxCurrent=375mA PME(D0+,D1+,D2+,D3hot+,D3cold+)
                Status: D0 NoSoftRst- PME-Enable- DSel=0 DScale=0 PME-
        Capabilities: [90] MSI: Enable+ Count=1/4 Maskable- 64bit+
                Address: 00000000fee007b8  Data: 0000
        Capabilities: [c4] Express (v2) Endpoint, MSI 00
                DevCap: MaxPayload 256 bytes, PhantFunc 0, Latency L0s <64ns, L1 <1us
                        ExtTag- AttnBtn- AttnInd- PwrInd- RBE+ FLReset- SlotPowerLimit 89W
                DevCtl: CorrErr- NonFatalErr- FatalErr- UnsupReq-
                        RlxdOrd- ExtTag- PhantFunc- AuxPwr- NoSnoop+
                        MaxPayload 128 bytes, MaxReadReq 512 bytes
                DevSta: CorrErr- NonFatalErr- FatalErr- UnsupReq- AuxPwr+ TransPend-
                LnkCap: Port #0, Speed 5GT/s, Width x1, ASPM L0s L1, Exit Latency L0s <2us, L1 <16us
                        ClockPM+ Surprise- LLActRep- BwNot- ASPMOptComp-
                LnkCtl: ASPM Disabled; RCB 64 bytes, Disabled- CommClk+
                        ExtSynch- ClockPM- AutWidDis- BWInt- AutBWInt-
                LnkSta: Speed 5GT/s, Width x1
                        TrErr- Train- SlotClk+ DLActive- BWMgmt- ABWMgmt-
                DevCap2: Completion Timeout: Range B, TimeoutDis+ NROPrPrP- LTR-
                         10BitTagComp- 10BitTagReq- OBFF Not Supported, ExtFmt- EETLPPrefix-
                         EmergencyPowerReduction Not Supported, EmergencyPowerReductionInit-
                         FRS- TPHComp- ExtTPHComp-
                         AtomicOpsCap: 32bit- 64bit- 128bitCAS-
                DevCtl2: Completion Timeout: 50us to 50ms, TimeoutDis- LTR- 10BitTagReq- OBFF Disabled,
                         AtomicOpsCtl: ReqEn-
                LnkCtl2: Target Link Speed: 5GT/s, EnterCompliance- SpeedDis-
                         Transmit Margin: Normal Operating Range, EnterModifiedCompliance- ComplianceSOS-
                         Compliance Preset/De-emphasis: -6dB de-emphasis, 0dB preshoot
                LnkSta2: Current De-emphasis Level: -6dB, EqualizationComplete- EqualizationPhase1-
                         EqualizationPhase2- EqualizationPhase3- LinkEqualizationRequest-
                         Retimer- 2Retimers- CrosslinkRes: unsupported
        Capabilities: [100 v1] Advanced Error Reporting
                UESta:  DLP- SDES- TLP- FCP- CmpltTO- CmpltAbrt- UnxCmplt- RxOF- MalfTLP- ECRC- UnsupReq- ACSViol-
                UEMsk:  DLP- SDES- TLP- FCP- CmpltTO- CmpltAbrt- UnxCmplt- RxOF- MalfTLP- ECRC- UnsupReq- ACSViol-
                UESvrt: DLP+ SDES+ TLP- FCP+ CmpltTO- CmpltAbrt- UnxCmplt- RxOF+ MalfTLP+ ECRC- UnsupReq- ACSViol-
                CESta:  RxErr- BadTLP- BadDLLP- Rollover- Timeout- AdvNonFatalErr-
                CEMsk:  RxErr- BadTLP- BadDLLP- Rollover- Timeout- AdvNonFatalErr+
                AERCap: First Error Pointer: 00, ECRCGenCap- ECRCGenEn- ECRCChkCap- ECRCChkEn-
                        MultHdrRecCap- MultHdrRecEn- TLPPfxPres- HdrLogCap-
                HeaderLog: 00000000 00000000 00000000 00000000
        Kernel driver in use: xhci_hcd
        Kernel modules: xhci_pci
Comment 12 Oliver Neukum 2023-07-13 13:02:03 UTC
We got something from upstream:


Odd. There are many third party VLI cards in the field and this is the
first I've heard of an incompatibility.
Can you please report the output of
lspci -s 0b:00.0 -xxx
and pastebin a dmesg trace with xhci debug printks (and the quirk) turned on?
Comment 13 Michał Szczepaniak 2023-07-13 13:03:22 UTC
I'm on it but if you would like to help me with enabling the printk's i would be thankful

0b:00.0 USB controller: VIA Technologies, Inc. VL805/806 xHCI USB 3.0 Controller (rev 01)
00: 06 11 83 34 07 04 10 00 01 30 03 0c 10 00 00 00
10: 04 00 40 fb 00 00 00 00 00 00 00 00 00 00 00 00
20: 00 00 00 00 00 00 00 00 00 00 00 00 06 11 83 34
30: 00 00 00 00 80 00 00 00 00 00 00 00 ff 01 00 00
Comment 14 Oliver Neukum 2023-07-13 13:57:49 UTC
You can enable dynamic debugging on the kernel command line. In this case

dyndbg="module xhci_hcd +fpm"

(on the unfixed kernel) should do the job.
Comment 15 Michał Szczepaniak 2023-07-20 10:05:29 UTC
I was about to get the debug log but… I'm currently at 6.4.3 and it seems to be working just fine. 6.3.8 was the one with the fix, so maybe something changed between 6.3 and 6.4. And indeed I booted 6.3.9 (without fix) and it indeed doesn't work.