Bug 216470
Summary: | [Regression] xhci_hcd 0000:08:00.2: xHC error in resume, USBSTS 0x401, Reinit | ||
---|---|---|---|
Product: | Drivers | Reporter: | Artem S. Tashkinov (aros) |
Component: | USB | Assignee: | Default virtual assignee for Drivers/USB (drivers_usb) |
Status: | RESOLVED CODE_FIX | ||
Severity: | low | CC: | mario.limonciello, mathias.nyman |
Priority: | P1 | ||
Hardware: | AMD | ||
OS: | Linux | ||
Kernel Version: | 5.19.8 | Subsystem: | |
Regression: | Yes | Bisected commit-id: |
Description
Artem S. Tashkinov
2022-09-10 12:40:36 UTC
CC'ing Mathias Nyman. Google says the error is relatively new: https://www.google.com/search?q=%22xHC+error+in+resume%2C+USBSTS+0x401%22 Looks like this is indeed a regression because there are no results other than those starting at approximately April, 2022. It's a new message as of 5.17-rc6 or later. https://github.com/torvalds/linux/commit/8b328f8002bcf29ef517ee4bf234e09aabec4d2e The behavior however is not new; it's due to this quirk introduced a few years back for your model. https://github.com/torvalds/linux/commit/a7d57abcc8a5bdeb53bbf8e87558e8e0a2c2a29d I don't think we should be doing anything functionally here. The only think that might make sense IMO is downgrading the message to INFO or not showing it instead of WARN when `xhci->broken_suspend` is set. Something like this: diff --git a/drivers/usb/host/xhci.c b/drivers/usb/host/xhci.c index 38649284ff88..a7ef675f00fd 100644 --- a/drivers/usb/host/xhci.c +++ b/drivers/usb/host/xhci.c @@ -1183,7 +1183,8 @@ int xhci_resume(struct xhci_hcd *xhci, bool hibernated) /* re-initialize the HC on Restore Error, or Host Controller Error */ if (temp & (STS_SRE | STS_HCE)) { reinit_xhc = true; - xhci_warn(xhci, "xHC error in resume, USBSTS 0x%x, Reinit\n", temp); + if (!xhci->broken_suspend) + xhci_warn(xhci, "xHC error in resume, USBSTS 0x%x, Reinit\n", temp); } if (reinit_xhc) { (In reply to Mario Limonciello (AMD) from comment #3) > It's a new message as of 5.17-rc6 or later. > > https://github.com/torvalds/linux/commit/ > 8b328f8002bcf29ef517ee4bf234e09aabec4d2e > > The behavior however is not new; it's due to this quirk introduced a few > years back for your model. > > https://github.com/torvalds/linux/commit/ > a7d57abcc8a5bdeb53bbf8e87558e8e0a2c2a29d > > I don't think we should be doing anything functionally here. The only think > that might make sense IMO is downgrading the message to INFO or not showing > it instead of WARN when `xhci->broken_suspend` is set. > > Something like this: > > diff --git a/drivers/usb/host/xhci.c b/drivers/usb/host/xhci.c > index 38649284ff88..a7ef675f00fd 100644 > --- a/drivers/usb/host/xhci.c > +++ b/drivers/usb/host/xhci.c > @@ -1183,7 +1183,8 @@ int xhci_resume(struct xhci_hcd *xhci, bool hibernated) > /* re-initialize the HC on Restore Error, or Host Controller Error */ > if (temp & (STS_SRE | STS_HCE)) { > reinit_xhc = true; > - xhci_warn(xhci, "xHC error in resume, USBSTS 0x%x, > Reinit\n", temp); > + if (!xhci->broken_suspend) > + xhci_warn(xhci, "xHC error in resume, USBSTS 0x%x, > Reinit\n", temp); > } > > if (reinit_xhc) { Both options look good to me; would be great _not_ to get this warning at `dmesg -t --level=alert,crit,err,warn`. Thanks a lot! Here is the fix queued up. https://lore.kernel.org/linux-usb/02ef1ae2-9dae-6f02-9951-1230939f06e2@linux.intel.com/T/#t |