CVE-2022-49398
Linux Kernel vulnerability analysis and mitigation

Overview

CVE-2022-49398 is a vulnerability in the Linux kernel's USB DWC3 gadget driver that was discovered and resolved in 2022. The issue involves improper handling of list traversal when using the list_for_each_entry_safe() macro in conjunction with gadget giveback operations (Kernel Git).

Technical details

The vulnerability stems from the list_for_each_entry_safe() macro's behavior, which saves the current item (n) and the next item (n+1) for safe list traversal. When traversing the list and removing items using gadget giveback, the DWC3 lock is briefly released, allowing other routines to execute. This creates a race condition where the cancelled_list can be modified by parallel operations, specifically during the interaction between dwc3_gadget_ep_cleanup_cancelled_requests() and the pullup disable routine (Kernel Git).

Impact

When the vulnerability is triggered, it can lead to a kernel panic when list debugging is enabled. This occurs because the cleanup routine removes item n while the pullup disable removes item n+1, resulting in the cleanup routine attempting to reference an already removed/handled request after retaking the DWC3 lock (Kernel Git).

Mitigation and workarounds

The issue has been fixed by replacing the list_for_each_entry_safe() macro usage with a while loop that checks for empty lists and handles endpoint disabled conditions appropriately. The fix ensures proper cleanup of requests and prevents the race condition that could lead to kernel panics (Kernel Git).

Additional resources


SourceThis report was generated using AI

Related Linux Kernel vulnerabilities:

CVE ID

Severity

Score

Technologies

Component name

CISA KEV exploit

Has fix

Published date

CVE-2025-68764N/AN/A
  • Linux KernelLinux Kernel
  • kernel-64k-debug-modules
NoYesJan 05, 2026
CVE-2025-68762N/AN/A
  • Linux KernelLinux Kernel
  • kernel-debug
NoYesJan 05, 2026
CVE-2025-68758N/AN/A
  • Linux KernelLinux Kernel
  • linux-riscv
NoYesJan 05, 2026
CVE-2025-68756N/AN/A
  • Linux KernelLinux Kernel
  • linux-fips
NoYesJan 05, 2026
CVE-2025-68753N/AN/A
  • Linux KernelLinux Kernel
  • python3-perf
NoYesJan 05, 2026

Free Vulnerability Assessment

Benchmark your Cloud Security Posture

Evaluate your cloud security practices across 9 security domains to benchmark your risk level and identify gaps in your defenses.

Request assessment

Get a personalized demo

Ready to see Wiz in action?

"Best User Experience I have ever seen, provides full visibility to cloud workloads."
David EstlickCISO
"Wiz provides a single pane of glass to see what is going on in our cloud environments."
Adam FletcherChief Security Officer
"We know that if Wiz identifies something as critical, it actually is."
Greg PoniatowskiHead of Threat and Vulnerability Management