CVE-2025-21859: Linux kernel · USB: gadget: f_midi: f_midi_complete to call queue_work
Affects Linux kernelSource GCVE Database
Not known to be exploited · CVSS 5.5 Medium · fixed in 5.4.0-1146.156~18.04.1 : update Linux kernel when convenient.
Data as of 28 Oct 2026, 12:58 UTC
- Patch
- Available – fixed in 5.4.0-1146.156~18.04.1, 5.4.0-1151.158~18.04.1, 5.4.0-1149.158~18.04.1 +83
CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:HExploitation evidence
Disclosed: evidence found.
CVE published 12 Mar 2025
Detectable: no evidence on record.
No public nuclei template indexed
Weaponised: no evidence on record.
No public exploit code indexed in Metasploit or Exploit-DB
Exploited in the wildExploited: no evidence on record.
Not in CISA KEV and no source reports exploitation
Observed by OffSeq MirageSeen by Mirage: no evidence on record.
No attack traffic recorded by OffSeq Mirage sensors
A missing step is not evidence of safety. Sources: cve.org (opens in a new tab), the Metasploit, Exploit-DB and nuclei-templates index as of 26 Oct 2026.
What to do
Upgrade to a fixed release listed under Affected software.
Patches and advisories
- ubuntu.com/security/notices/USN-7510-1 (opens in a new tab)
- ubuntu.com/security/notices/USN-7510-2 (opens in a new tab)
- ubuntu.com/security/notices/USN-7511-1 (opens in a new tab)
- ubuntu.com/security/notices/USN-7511-2 (opens in a new tab)
- ubuntu.com/security/notices/USN-7512-1 (opens in a new tab)
- ubuntu.com/security/notices/USN-7516-1 (opens in a new tab)
- ubuntu.com/security/notices/USN-7516-2 (opens in a new tab)
- ubuntu.com/security/notices/USN-7517-1 (opens in a new tab)
- ubuntu.com/security/notices/USN-7518-1 (opens in a new tab)
- ubuntu.com/security/notices/USN-7521-1 (opens in a new tab)
- ubuntu.com/security/notices/USN-7510-3 (opens in a new tab)
- ubuntu.com/security/notices/USN-7510-4 (opens in a new tab)
Affected software
| Product | Affected | Fixed in |
|---|---|---|
Ubuntu 24.04 LTSlinuxpkg:deb/ubuntu/linux?arch=source&distro=nobleOther threats | Affected
| Fixed in
|
Ubuntu 24.04 LTSlinux-awspkg:deb/ubuntu/linux-aws?arch=source&distro=nobleOther threats | Affected
| Fixed in
|
Ubuntu 24.04 LTSlinux-azurepkg:deb/ubuntu/linux-azure?arch=source&distro=nobleOther threats | Affected
| Fixed in
|
Ubuntu 24.04 LTSlinux-azure-6.11pkg:deb/ubuntu/linux-azure-6.11?arch=source&distro=nobleOther threats | Affected
| Fixed in
|
Ubuntu 24.04 LTSlinux-azure-nvidiapkg:deb/ubuntu/linux-azure-nvidia?arch=source&distro=nobleOther threats | Affected
| Fixed in
|
Ubuntu 24.04 LTSlinux-gcppkg:deb/ubuntu/linux-gcp?arch=source&distro=nobleOther threats | Affected
| Fixed in
|
Check your own hosts for these packages with threat-finder (opens in a new tab), our free open-source scanner.
AI-suggested
A patch is available and included in Linux kernel versions 5.4.0-1146.156 and later, as well as other fixed versions listed in the advisory. Users should update their Linux kernel to one of the fixed versions to remediate this issue. After updating, a system reboot is required to apply the fix. There are no additional mitigations required beyond applying the official kernel updates.
Description
A deadlock vulnerability exists in the Linux kernel's USB MIDI gadget driver (f_midi) due to a re-entrant lock acquisition in the f_midi_transmit function. This issue has been fixed by changing the completion handler to schedule the inner transmit call via a high priority work queue using queue_work(). The vulnerability affects multiple Linux kernel versions prior to 5.4.0-1146.156 and several older 3.x versions. The fix is included in Linux kernel versions 5.4.0-1146.156 and later. The vulnerability has a medium severity with a CVSS score of 5.5 and does not impact confidentiality or integrity but causes availability impact due to deadlock.
References
- ubuntu.com/security/CVE-2025-21859 (opens in a new tab)
- cve.org/CVERecord?id=CVE-2025-21859 (opens in a new tab)
- git.kernel.org/linus/4ab37fcb42832cdd3e9d5e50653285ca84d6686f (opens in a new tab)
- git.kernel.org/stable/c/24a942610ee9bafb2692a456ae850c5b2e409b05 (opens in a new tab)
- git.kernel.org/stable/c/4ab37fcb42832cdd3e9d5e50653285ca84d6686f (opens in a new tab)
- git.kernel.org/stable/c/8aa6b4be1f4efccbfc533e6ec8841d26e4fa8dba (opens in a new tab)
- git.kernel.org/stable/c/deeee3adb2c01eedab32c3b4519337689ad02e8a (opens in a new tab)
- git.kernel.org/stable/c/e9fec6f42c45db2f62dc373fb1a10d2488c04e79 (opens in a new tab)
- ubuntu.com/security/notices/USN-7510-1 (opens in a new tab)
- ubuntu.com/security/notices/USN-7510-2 (opens in a new tab)
- ubuntu.com/security/notices/USN-7511-1 (opens in a new tab)
- ubuntu.com/security/notices/USN-7511-2 (opens in a new tab)
- ubuntu.com/security/notices/USN-7512-1 (opens in a new tab)
- ubuntu.com/security/notices/USN-7516-1 (opens in a new tab)
- ubuntu.com/security/notices/USN-7516-2 (opens in a new tab)
- ubuntu.com/security/notices/USN-7517-1 (opens in a new tab)
- ubuntu.com/security/notices/USN-7518-1 (opens in a new tab)
- ubuntu.com/security/notices/USN-7521-1 (opens in a new tab)
- ubuntu.com/security/notices/USN-7510-3 (opens in a new tab)
- ubuntu.com/security/notices/USN-7510-4 (opens in a new tab)