CVE-2025-21838: usb: gadget: core: flush gadget workqueue after device removal

Published Mar 7, 2025
·
Updated

In the Linux kernel, the following vulnerability has been resolved:

usb: gadget: core: flush gadget workqueue after device removal

devicedel() can lead to new work being scheduled in gadget->work workqueue. This is observed, for example, with the dwc3 driver with the following call stack: devicedel() gadgetunbinddriver() usbgadgetdisconnectlocked() dwc3gadgetpullup() dwc3gadgetsoftdisconnect() usbgadgetsetstate() schedulework(&gadget->work)

Move flushwork() after devicedel() to ensure the workqueue is cleaned up.

Affected Software

8 affected components
Linux Linux kernel
Linux Linux kernel>=3.12<6.1.130
Linux Linux kernel>=6.2<6.6.80
Linux Linux kernel>=6.7<6.12.16
Linux Linux kernel>=6.13<6.13.4
Linux Linux kernel=6.14-rc1
Linux Linux kernel=6.14-rc2
Microsoft cbl2 kernel 5.15.186.1-1

Event History

Mar 7, 2025
CVE Published
via MITRE·09:09 AM
Data Sourced
via MITRE·09:09 AM
Description
Data Sourced
via NVD·09:15 AM
RemedyDescriptionSeverityAffected Software
Oct 31, 2025
Data Sourced
via Microsoft·01:03 AM
DescriptionSeverityWeaknessAffected Software

Frequently Asked Questions

1

What is the severity of CVE-2025-21838?

CVE-2025-21838 has been categorized with a medium severity level due to its potential impact on system stability.

2

How do I fix CVE-2025-21838?

To fix CVE-2025-21838, ensure that you update your Linux kernel to the latest stable release that addresses this vulnerability.

3

What systems are affected by CVE-2025-21838?

CVE-2025-21838 affects the Linux kernel, specifically impacting systems that utilize the USB gadget functionality.

4

What can happen if CVE-2025-21838 is exploited?

Exploitation of CVE-2025-21838 could lead to unexpected behavior or crashes related to the USB gadgets on affected systems.

5

When was CVE-2025-21838 published?

CVE-2025-21838 was published in 2025 after being identified in the Linux kernel.

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203