drivers: usb: host: Fix deadlock in oxu_bus_suspend()
Published Feb 26, 2025
5.5
MEDIUMCVSS 3.1
EPSS 0.21%
Description
There is a deadlock in oxu_bus_suspend(), which is shown below:
(Thread 1) | (Thread 2) | timer_action() oxu_bus_suspend() | mod_timer() spin_lock_irq() //(1) | (wait a time) ... | oxu_watchdog() del_timer_sync() | spin_lock_irq() //(2) (wait timer to stop) | ...
We hold oxu->lock in position (1) of thread 1, and use del_timer_sync() to wait timer to stop, but timer handler also need oxu->lock in position (2) of thread 2. As a result, oxu_bus_suspend() will block forever.
This patch extracts del_timer_sync() from the protection of spin_lock_irq(), which could let timer handler to obtain the needed lock.
Affected products
-
- Version StatusaffectedConstraints
- Version StatusaffectedConstraints
- Version StatusaffectedConstraints
- Version StatusaffectedConstraints
- Version StatusaffectedConstraints
- Version StatusaffectedConstraints
- Version StatusaffectedConstraints
- Version StatusaffectedConstraints
- Version StatusaffectedConstraints
- Version
-
- Version 2.6.29StatusaffectedConstraints-
- Version 0StatusunaffectedConstraints<2.6.29
- Version 4.14.283StatusunaffectedConstraints<=4.14.*
- Version 4.19.247StatusunaffectedConstraints<=4.19.*
- Version 4.9.318StatusunaffectedConstraints<=4.9.*
- Version 5.10.122StatusunaffectedConstraints<=5.10.*
- Version 5.15.47StatusunaffectedConstraints<=5.15.*
- Version 5.17.15StatusunaffectedConstraints<=5.17.*
- Version 5.18.4StatusunaffectedConstraints<=5.18.*
- Version 5.19StatusunaffectedConstraints<=*
- Version 5.4.198StatusunaffectedConstraints<=5.4.*
- Version
Default status is the baseline for the product, each version can override it (e.g. patched versions marked unaffected).
| Vendor | Product | Default status | Versions | ||||||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Linux | Linux | unaffected |
| ||||||||||||||||||||||||||||||||||||
| Linux | Linux | affected |
|
- < 4.9.318
- ≥ 4.10 · < 4.14.283
- ≥ 4.15 · < 4.19.247
- ≥ 4.20 · < 5.4.198
- ≥ 5.5 · < 5.10.122
- ≥ 5.11 · < 5.15.47
- ≥ 5.16 · < 5.17.15
- ≥ 5.18 · < 5.18.4
No data.
Red Hat Enterprise Linux 10
kernel
Not affected
Red Hat Enterprise Linux 6
kernel
Not affected
Red Hat Enterprise Linux 7
kernel
Not affected
Red Hat Enterprise Linux 7
kernel-rt
Not affected
Red Hat Enterprise Linux 8
kernel
Not affected
Red Hat Enterprise Linux 8
kernel-rt
Not affected
Red Hat Enterprise Linux 9
kernel
Not affected
Red Hat Enterprise Linux 9
kernel-rt
Not affected
| Product | Package | State | Advisory |
|---|---|---|---|
| Red Hat Enterprise Linux 10 | kernel | Not affected | n/a |
| Red Hat Enterprise Linux 6 | kernel | Not affected | n/a |
| Red Hat Enterprise Linux 7 | kernel | Not affected | n/a |
| Red Hat Enterprise Linux 7 | kernel-rt | Not affected | n/a |
| Red Hat Enterprise Linux 8 | kernel | Not affected | n/a |
| Red Hat Enterprise Linux 8 | kernel-rt | Not affected | n/a |
| Red Hat Enterprise Linux 9 | kernel | Not affected | n/a |
| Red Hat Enterprise Linux 9 | kernel-rt | Not affected | n/a |
No package ranges for this CVE.
Remediation
No remediation recorded yet.
References (14)
- https://access.redhat.com/security/cve/CVE-2022-49313 Vendor Advisory
- https://bugzilla.redhat.com/show_bug.cgi?id=2347760 Issue Tracking
- https://git.kernel.org/stable/c/2dcec0bc142be2096af71a5703d63237127db204 Patch
- https://git.kernel.org/stable/c/4187b291a76664a3c03d3f0d9bfadc8322881868 Patch
- https://git.kernel.org/stable/c/4d378f2ae58138d4c55684e1d274e7dd94aa6524 Patch
- https://git.kernel.org/stable/c/9b58d255f27b0ed6a2e43208960864d67579db58 Patch
- https://git.kernel.org/stable/c/a3d380188bde8900c3f604e82b56572896499124 Patch
- https://git.kernel.org/stable/c/b97aae8b43b718314012e8170b7e03dbfd2e7677 Patch
- https://git.kernel.org/stable/c/d888753872190abd18f68a7d77b9c7c367f0a7ab Patch
- https://git.kernel.org/stable/c/f8242044c91cafbba9e320b0fb31abf2429a3221 Patch
- https://git.kernel.org/stable/c/ffe9440d698274c6462d2e304562c6ddfc8c84df Patch
- https://lore.kernel.org/linux-cve-announce/2025022636-CVE-2022-49313-06e5@gregkh/T
- https://nvd.nist.gov/vuln/detail/CVE-2022-49313
- https://www.cve.org/CVERecord?id=CVE-2022-49313
Change history (0)
No recorded changes yet.