CVE-2022-50721
Calling Convention Bug in Linux dmaengine Causes Kernel Panic
Publication date: 2025-12-24
Last updated on: 2025-12-24
Assigner: kernel.org
Description
Description
CVSS Scores
EPSS Scores
| Probability: | |
| Percentile: |
Meta Information
Affected Vendors & Products
| Vendor | Product | Version / Range |
|---|---|---|
| linux | linux_kernel | * |
Helpful Resources
Exploitability
| CWE ID | Description |
|---|---|
| CWE-UNKNOWN |
Attack-Flow Graph
AI Powered Q&A
Can you explain this vulnerability to me?
This vulnerability is in the Linux kernel's dmaengine, specifically in the qcom-adm driver. The issue is that qcom-adm does not follow the correct calling convention for the function prep_slave_sg. Instead of returning NULL on error and logging the error, it returns an error pointer. This causes other drivers, like nandc, which only check if the pointer is not NULL, to mistakenly believe the function succeeded. This leads to a kernel panic later in the code. The fix is to have qcom-adm return NULL with an error log as per the correct convention.
How can this vulnerability impact me? :
This vulnerability can cause the Linux kernel to panic (crash) due to improper error handling in the qcom-adm driver. If a driver like nandc relies on the return value of prep_slave_sg and receives an error pointer instead of NULL, it may proceed incorrectly, leading to system instability or crashes.
What immediate steps should I take to mitigate this vulnerability?
Apply the patch that fixes the calling convention in the qcom-adm dmaengine driver to ensure that prep_slave_sg returns NULL on error instead of an error pointer. This prevents kernel panic caused by the nandc driver misinterpreting the return value. Until patched, avoid using affected drivers or kernel versions if possible.