mmc: mmci: Fix use-after-free in busy-timeout work
Linux
Affected versions
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
| No fix yet |
| Linux Linux |
|
Linux
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
| No fix yet |
| Linux Linux |
|
|
In the Linux kernel, the following vulnerability has been resolved:
mmc: mmci: Fix use-after-free in busy-timeout work
ux500_busy_complete() can queue ux500_busy_timeout_work for an R1b command, but mmci_remove() never cancels it. The work can subsequently dereference the devm-allocated mmci_host after it has been released.
Mask the controller interrupts and disable the delayed work during removal. This drains any queued instance and stops an IRQ handler that is still in progress from queueing the work again once it has been disabled.
This issue was found by an in-house static analysis tool.
From the CVE record · Linux
The Linux kernel mmci driver can queue busy-timeout work for an R1b command without canceling it during device removal. If the work runs after the mmci_host is released, it can dereference freed memory. The input does not establish an attacker path, authentication requirement, or user-interaction requirement.
Engineers running Linux kernels that use the mmci driver should check whether their kernel includes the fix; affected versions are not specified.