Upstream information

CVE-2024-40927 at MITRE

Description

In the Linux kernel, the following vulnerability has been resolved: xhci: Handle TD clearing for multiple streams case When multiple streams are in use, multiple TDs might be in flight when an endpoint is stopped. We need to issue a Set TR Dequeue Pointer for each, to ensure everything is reset properly and the caches cleared. Change the logic so that any N>1 TDs found active for different streams are deferred until after the first one is processed, calling xhci_invalidate_cancelled_tds() again from xhci_handle_cmd_set_deq() to queue another command until we are done with all of them. Also change the error/"should never happen" paths to ensure we at least clear any affected TDs, even if we can't issue a command to clear the hardware cache, and complain loudly with an xhci_warn() if this ever happens. This problem case dates back to commit e9df17eb1408 ("USB: xhci: Correct assumptions about number of rings per endpoint.") early on in the XHCI driver's life, when stream support was first added. It was then identified but not fixed nor made into a warning in commit 674f8438c121 ("xhci: split handling halted endpoints into two steps"), which added a FIXME comment for the problem case (without materially changing the behavior as far as I can tell, though the new logic made the problem more obvious). Then later, in commit 94f339147fc3 ("xhci: Fix failure to give back some cached cancelled URBs."), it was acknowledged again. [Mathias: commit 94f339147fc3 ("xhci: Fix failure to give back some cached cancelled URBs.") was a targeted regression fix to the previously mentioned patch. Users reported issues with usb stuck after unmounting/disconnecting UAS devices. This rolled back the TD clearing of multiple streams to its original state.] Apparently the commit author was aware of the problem (yet still chose to submit it): It was still mentioned as a FIXME, an xhci_dbg() was added to log the problem condition, and the remaining issue was mentioned in the commit description. The choice of making the log type xhci_dbg() for what is, at this point, a completely unhandled and known broken condition is puzzling and unfortunate, as it guarantees that no actual users would see the log in production, thereby making it nigh undebuggable (indeed, even if you turn on DEBUG, the message doesn't really hint at there being a problem at all). It took me *months* of random xHC crashes to finally find a reliable repro and be able to do a deep dive debug session, which could all have been avoided had this unhandled, broken condition been actually reported with a warning, as it should have been as a bug intentionally left in unfixed (never mind that it shouldn't have been left in at all). > Another fix to solve clearing the caches of all stream rings with > cancelled TDs is needed, but not as urgent. 3 years after that statement and 14 years after the original bug was introduced, I think it's finally time to fix it. And maybe next time let's not leave bugs unfixed (that are actually worse than the original bug), and let's actually get people to review kernel commits please. Fixes xHC crashes and IOMMU faults with UAS devices when handling errors/faults. Easiest repro is to use `hdparm` to mark an early sector (e.g. 1024) on a disk as bad, then `cat /dev/sdX > /dev/null` in a loop. At least in the case of JMicron controllers, the read errors end up having to cancel two TDs (for two queued requests to different streams) and the one that didn't get cleared properly ends up faulting the xHC entirely when it tries to access DMA pages that have since been unmapped, referred to by the stale TDs. This normally happens quickly (after two or three loops). After this fix, I left the `cat` in a loop running overnight and experienced no xHC failures, with all read errors recovered properly. Repro'd and tested on an Apple M1 Mac Mini (dwc3 host). On systems without an IOMMU, this bug would instead silently corrupt freed memory, making this a ---truncated---

SUSE information

Overall state of this security issue: Pending

This issue is currently rated as having moderate severity.

CVSS v3 Scores
  SUSE
Base Score 6.6
Vector CVSS:3.1/AV:P/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H
Attack Vector Physical
Attack Complexity Low
Privileges Required Low
User Interaction None
Scope Unchanged
Confidentiality Impact High
Integrity Impact High
Availability Impact High
CVSSv3 Version 3.1
SUSE Bugzilla entry: 1227816 [NEW]

No SUSE Security Announcements cross referenced.


Status of this issue by product and package

Please note that this evaluation state might be work in progress, incomplete or outdated. Also information for service packs in the LTSS phase is only included for issues meeting the LTSS criteria. If in doubt, feel free to contact us for clarification. The updates are grouped by state of their lifecycle. SUSE product lifecycles are documented on the lifecycle page.

Product(s) Source package State
Products under general support and receiving all security fixes.
SUSE Enterprise Storage 7.1 kernel-default Affected
SUSE Enterprise Storage 7.1 kernel-source Affected
SUSE Linux Enterprise Desktop 15 SP5 kernel-default Already fixed
SUSE Linux Enterprise Desktop 15 SP5 kernel-source Already fixed
SUSE Linux Enterprise Desktop 15 SP6 kernel-default Already fixed
SUSE Linux Enterprise Desktop 15 SP6 kernel-source Already fixed
SUSE Linux Enterprise High Performance Computing 12 SP5 kernel-default Affected
SUSE Linux Enterprise High Performance Computing 12 SP5 kernel-source Affected
SUSE Linux Enterprise High Performance Computing 12 SP5 kernel-source-azure Affected
SUSE Linux Enterprise High Performance Computing 15 SP5 kernel-default Already fixed
SUSE Linux Enterprise High Performance Computing 15 SP5 kernel-source Already fixed
SUSE Linux Enterprise High Performance Computing 15 SP5 kernel-source-azure Already fixed
SUSE Linux Enterprise High Performance Computing 15 SP6 kernel-default Already fixed
SUSE Linux Enterprise High Performance Computing 15 SP6 kernel-source Already fixed
SUSE Linux Enterprise High Performance Computing 15 SP6 kernel-source-azure Already fixed
SUSE Linux Enterprise Micro 5.1 kernel-default Affected
SUSE Linux Enterprise Micro 5.1 kernel-rt Affected
SUSE Linux Enterprise Micro 5.1 kernel-source-rt Affected
SUSE Linux Enterprise Micro 5.2 kernel-default Affected
SUSE Linux Enterprise Micro 5.2 kernel-rt Affected
SUSE Linux Enterprise Micro 5.2 kernel-source-rt Affected
SUSE Linux Enterprise Micro 5.3 kernel-default Affected
SUSE Linux Enterprise Micro 5.3 kernel-rt Affected
SUSE Linux Enterprise Micro 5.3 kernel-source-rt Affected
SUSE Linux Enterprise Micro 5.4 kernel-default Affected
SUSE Linux Enterprise Micro 5.4 kernel-rt Affected
SUSE Linux Enterprise Micro 5.4 kernel-source-rt Affected
SUSE Linux Enterprise Micro 5.5 kernel-source-rt Already fixed
SUSE Linux Enterprise Module for Basesystem 15 SP5 kernel-default Already fixed
SUSE Linux Enterprise Module for Basesystem 15 SP5 kernel-source Already fixed
SUSE Linux Enterprise Module for Basesystem 15 SP6 kernel-default Already fixed
SUSE Linux Enterprise Module for Basesystem 15 SP6 kernel-source Already fixed
SUSE Linux Enterprise Module for Development Tools 15 SP5 kernel-default Already fixed
SUSE Linux Enterprise Module for Development Tools 15 SP5 kernel-source Already fixed
SUSE Linux Enterprise Module for Development Tools 15 SP6 kernel-default Already fixed
SUSE Linux Enterprise Module for Development Tools 15 SP6 kernel-source Already fixed
SUSE Linux Enterprise Module for Public Cloud 15 SP5 kernel-source-azure Already fixed
SUSE Linux Enterprise Module for Public Cloud 15 SP6 kernel-source-azure Already fixed
SUSE Linux Enterprise Real Time 12 SP5 kernel-source-rt Affected
SUSE Linux Enterprise Real Time 15 SP5 kernel-source-rt Already fixed
SUSE Linux Enterprise Real Time 15 SP6 kernel-source-rt Already fixed
SUSE Linux Enterprise Server 12 SP5 kernel-default Affected
SUSE Linux Enterprise Server 12 SP5 kernel-source Affected
SUSE Linux Enterprise Server 12 SP5 kernel-source-azure Affected
SUSE Linux Enterprise Server 15 SP5 kernel-default Already fixed
SUSE Linux Enterprise Server 15 SP5 kernel-source Already fixed
SUSE Linux Enterprise Server 15 SP5 kernel-source-azure Already fixed
SUSE Linux Enterprise Server 15 SP6 kernel-default Already fixed
SUSE Linux Enterprise Server 15 SP6 kernel-source Already fixed
SUSE Linux Enterprise Server 15 SP6 kernel-source-azure Already fixed
SUSE Linux Enterprise Server for SAP Applications 12 SP5 kernel-default Affected
SUSE Linux Enterprise Server for SAP Applications 12 SP5 kernel-source Affected
SUSE Linux Enterprise Server for SAP Applications 12 SP5 kernel-source-azure Affected
SUSE Linux Enterprise Server for SAP Applications 15 SP5 kernel-default Already fixed
SUSE Linux Enterprise Server for SAP Applications 15 SP5 kernel-source Already fixed
SUSE Linux Enterprise Server for SAP Applications 15 SP5 kernel-source-azure Already fixed
SUSE Linux Enterprise Server for SAP Applications 15 SP6 kernel-default Already fixed
SUSE Linux Enterprise Server for SAP Applications 15 SP6 kernel-source Already fixed
SUSE Linux Enterprise Server for SAP Applications 15 SP6 kernel-source-azure Already fixed
SUSE Manager Proxy 4.3 kernel-default Affected
SUSE Manager Proxy 4.3 kernel-source Affected
SUSE Manager Retail Branch Server 4.3 kernel-default Affected
SUSE Manager Retail Branch Server 4.3 kernel-source Affected
SUSE Manager Server 4.3 kernel-default Affected
SUSE Manager Server 4.3 kernel-source Affected
SUSE Real Time Module 15 SP5 kernel-source-rt Already fixed
SUSE Real Time Module 15 SP6 kernel-source-rt Already fixed
openSUSE Leap 15.5 kernel-default Already fixed
openSUSE Leap 15.5 kernel-source Already fixed
openSUSE Leap 15.5 kernel-source-azure Already fixed
openSUSE Leap 15.5 kernel-source-rt Already fixed
openSUSE Leap 15.6 kernel-default Already fixed
openSUSE Leap 15.6 kernel-source Already fixed
openSUSE Leap 15.6 kernel-source-azure Already fixed
openSUSE Leap 15.6 kernel-source-rt Already fixed
Products under Long Term Service Pack support and receiving important and critical security fixes.
SUSE Linux Enterprise Desktop 15 SP4 kernel-source Affected
SUSE Linux Enterprise High Performance Computing 15 SP2 kernel-source Affected
SUSE Linux Enterprise High Performance Computing 15 SP2-ESPOS kernel-source Affected
SUSE Linux Enterprise High Performance Computing 15 SP2-LTSS kernel-default Affected
SUSE Linux Enterprise High Performance Computing 15 SP2-LTSS kernel-source Affected
SUSE Linux Enterprise High Performance Computing 15 SP3 kernel-source Affected
SUSE Linux Enterprise High Performance Computing 15 SP3-ESPOS kernel-source Affected
SUSE Linux Enterprise High Performance Computing 15 SP3-LTSS kernel-default Affected
SUSE Linux Enterprise High Performance Computing 15 SP3-LTSS kernel-source Affected
SUSE Linux Enterprise High Performance Computing 15 SP4 kernel-source Affected
SUSE Linux Enterprise High Performance Computing 15 SP4-ESPOS kernel-default Affected
SUSE Linux Enterprise High Performance Computing 15 SP4-ESPOS kernel-source Affected
SUSE Linux Enterprise High Performance Computing 15 SP4-LTSS kernel-default Affected
SUSE Linux Enterprise High Performance Computing 15 SP4-LTSS kernel-source Affected
SUSE Linux Enterprise Module for Basesystem 15 SP2 kernel-source Affected
SUSE Linux Enterprise Module for Basesystem 15 SP3 kernel-source Affected
SUSE Linux Enterprise Module for Basesystem 15 SP4 kernel-source Affected
SUSE Linux Enterprise Module for Development Tools 15 SP2 kernel-source Affected
SUSE Linux Enterprise Module for Development Tools 15 SP3 kernel-source Affected
SUSE Linux Enterprise Module for Development Tools 15 SP4 kernel-source Affected
SUSE Linux Enterprise Server 11 SP4 LTSS EXTREME CORE kernel-default Affected
SUSE Linux Enterprise Server 11 SP4 LTSS EXTREME CORE kernel-source Affected
SUSE Linux Enterprise Server 15 SP2 kernel-source Affected
SUSE Linux Enterprise Server 15 SP2-LTSS kernel-default Affected
SUSE Linux Enterprise Server 15 SP2-LTSS kernel-source Affected
SUSE Linux Enterprise Server 15 SP3 kernel-source Affected
SUSE Linux Enterprise Server 15 SP3-LTSS kernel-default Affected
SUSE Linux Enterprise Server 15 SP3-LTSS kernel-source Affected
SUSE Linux Enterprise Server 15 SP4 kernel-source Affected
SUSE Linux Enterprise Server 15 SP4-LTSS kernel-default Affected
SUSE Linux Enterprise Server 15 SP4-LTSS kernel-source Affected
SUSE Linux Enterprise Server for SAP Applications 15 SP2 kernel-default Affected
SUSE Linux Enterprise Server for SAP Applications 15 SP2 kernel-source Affected
SUSE Linux Enterprise Server for SAP Applications 15 SP3 kernel-default Affected
SUSE Linux Enterprise Server for SAP Applications 15 SP3 kernel-source Affected
SUSE Linux Enterprise Server for SAP Applications 15 SP4 kernel-default Affected
SUSE Linux Enterprise Server for SAP Applications 15 SP4 kernel-source Affected
Products past their end of life and not receiving proactive updates anymore.
HPE Helion OpenStack 8 kernel-source Affected
SUSE CaaS Platform 4.0 kernel-source Affected
SUSE Enterprise Storage 6 kernel-source Affected
SUSE Enterprise Storage 7 kernel-source Affected
SUSE Linux Enterprise Desktop 11 SP4 kernel-source Affected
SUSE Linux Enterprise Desktop 12 SP3 kernel-source Affected
SUSE Linux Enterprise Desktop 12 SP4 kernel-source Affected
SUSE Linux Enterprise Desktop 15 kernel-source Affected
SUSE Linux Enterprise Desktop 15 SP1 kernel-source Affected
SUSE Linux Enterprise Desktop 15 SP2 kernel-source Affected
SUSE Linux Enterprise Desktop 15 SP3 kernel-source Affected
SUSE Linux Enterprise High Performance Computing 15 kernel-source Affected
SUSE Linux Enterprise High Performance Computing 15 SP1 kernel-source Affected
SUSE Linux Enterprise High Performance Computing 15 SP1-ESPOS kernel-source Affected
SUSE Linux Enterprise High Performance Computing 15 SP1-LTSS kernel-source Affected
SUSE Linux Enterprise High Performance Computing 15-ESPOS kernel-source Affected
SUSE Linux Enterprise High Performance Computing 15-LTSS kernel-source Affected
SUSE Linux Enterprise Micro 5.0 kernel-default Affected
SUSE Linux Enterprise Module for Basesystem 15 kernel-source Affected
SUSE Linux Enterprise Module for Basesystem 15 SP1 kernel-source Affected
SUSE Linux Enterprise Module for Development Tools 15 kernel-source Affected
SUSE Linux Enterprise Module for Development Tools 15 SP1 kernel-source Affected
SUSE Linux Enterprise Real Time 15 SP2 kernel-source Affected
SUSE Linux Enterprise Real Time 15 SP3 kernel-source Affected
SUSE Linux Enterprise Real Time 15 SP3 kernel-source-rt Affected
SUSE Linux Enterprise Real Time 15 SP4 kernel-source Affected
SUSE Linux Enterprise Real Time 15 SP4 kernel-source-rt Affected
SUSE Linux Enterprise Server 11 SP4 kernel-source Affected
SUSE Linux Enterprise Server 11 SP4 LTSS kernel-default Affected
SUSE Linux Enterprise Server 11 SP4 LTSS kernel-source Affected
SUSE Linux Enterprise Server 11 SP4-LTSS kernel-source Affected
SUSE Linux Enterprise Server 12 SP3 kernel-source Affected
SUSE Linux Enterprise Server 12 SP3-BCL kernel-source Affected
SUSE Linux Enterprise Server 12 SP3-ESPOS kernel-source Affected
SUSE Linux Enterprise Server 12 SP3-LTSS kernel-source Affected
SUSE Linux Enterprise Server 12 SP4 kernel-source Affected
SUSE Linux Enterprise Server 12 SP4-ESPOS kernel-source Affected
SUSE Linux Enterprise Server 12 SP4-LTSS kernel-default Affected
SUSE Linux Enterprise Server 12 SP4-LTSS kernel-source Affected
SUSE Linux Enterprise Server 15 kernel-source Affected
SUSE Linux Enterprise Server 15 SP1 kernel-source Affected
SUSE Linux Enterprise Server 15 SP1-BCL kernel-source Affected
SUSE Linux Enterprise Server 15 SP1-LTSS kernel-default Affected
SUSE Linux Enterprise Server 15 SP1-LTSS kernel-source Affected
SUSE Linux Enterprise Server 15 SP2-BCL kernel-source Affected
SUSE Linux Enterprise Server 15 SP3-BCL kernel-source Affected
SUSE Linux Enterprise Server 15-LTSS kernel-default Affected
SUSE Linux Enterprise Server 15-LTSS kernel-source Affected
SUSE Linux Enterprise Server for SAP Applications 12 SP3 kernel-source Affected
SUSE Linux Enterprise Server for SAP Applications 12 SP4 kernel-default Affected
SUSE Linux Enterprise Server for SAP Applications 12 SP4 kernel-source Affected
SUSE Linux Enterprise Server for SAP Applications 15 kernel-source Affected
SUSE Linux Enterprise Server for SAP Applications 15 SP1 kernel-source Affected
SUSE Manager Proxy 4.0 kernel-source Affected
SUSE Manager Proxy 4.1 kernel-source Affected
SUSE Manager Proxy 4.2 kernel-source Affected
SUSE Manager Retail Branch Server 4.0 kernel-source Affected
SUSE Manager Retail Branch Server 4.1 kernel-source Affected
SUSE Manager Retail Branch Server 4.2 kernel-source Affected
SUSE Manager Server 4.0 kernel-source Affected
SUSE Manager Server 4.1 kernel-source Affected
SUSE Manager Server 4.2 kernel-source Affected
SUSE OpenStack Cloud 8 kernel-source Affected
SUSE OpenStack Cloud 9 kernel-source Affected
SUSE OpenStack Cloud Crowbar 8 kernel-source Affected
SUSE OpenStack Cloud Crowbar 9 kernel-source Affected
SUSE Real Time Module 15 SP3 kernel-source-rt Affected
SUSE Real Time Module 15 SP4 kernel-source-rt Affected
openSUSE Leap 15.3 kernel-source Affected
openSUSE Leap 15.3 kernel-source-rt Affected
openSUSE Leap 15.4 kernel-source Affected
openSUSE Leap 15.4 kernel-source-azure Affected
openSUSE Leap 15.4 kernel-source-rt Affected
Products at an unknown state of their lifecycle.
SUSE CaaS Platform Toolchain 3 kernel-source Affected


SUSE Timeline for this CVE

CVE page created: Fri Jul 12 16:00:38 2024
CVE page last modified: Mon Jul 15 17:51:33 2024