Re: [PATCH] usb: xhci: add xhci_halt() for HCE Handling
From: Greg Kroah-Hartman
Date: Wed Jan 28 2026 - 03:59:57 EST
On Wed, Jan 28, 2026 at 04:48:49PM +0800, Dayu Jiang wrote:
> On Tue, Jan 27, 2026 at 12:22:40PM +0100, Greg Kroah-Hartman wrote:
> > > if (status & STS_HCE) {
> > > xhci_warn(xhci, "WARNING: Host Controller Error\n");
> > > + xhci_halt(xhci);
> >
> > What is going to start things back up again? And as you are calling
> > this function, why is the warning message needed anymore? The
> > tracepoint information will give you that message now, right?
> When HCE is triggered, it indicates a critical hardware failure.
> Aligning with the handling of HSE (STS_FATAL) by adding
> xhci_halt() here is more reasonable: without xhci_halt(), the
> USB controller may fall into an unpredictable and unstable state,
> which could exacerbate system issues.
>
> Retaining the warning message is necessary because it is directly
> visible in dmesg, whereas tracepoint information requires explicitly
> enabling xHCI tracepoints. Additionally, if xhci_halt() is called in
> xhci_irq() without the warning log, it would be impossible to
> distinguish whether the halt was triggered by HCE or HSE.
> >
> > And is this just papering over a hardware bug? Should this really be
> > happening for any normal system?
> Yes, this issue has been reproducible on real-world hardware: HCE is
> triggered in UAS Storage Device plug/unplug scenarios on Android
> devices, which enters this error branch and causes an interrupt storm,
> leading to severe system-level faults.
Great, please provide this information in the changelog text when you
resubmit this, thanks!
greg k-h