mm/migrate_device: fix spinlock leak in migrate_vma_insert_huge_pmd_page
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:
mm/migrate_device: fix spinlock leak in migrate_vma_insert_huge_pmd_page
When check_stable_address_space() fails after the PMD spinlock has been acquired via pmd_lock(), the code jumps directly to the abort label, bypassing the spin_unlock() call in unlock_abort. This causes the PMD spinlock to be permanently held, leading to a deadlock.
Change the goto target from abort to unlock_abort to ensure the spinlock is always released on this error path.
From the CVE record · Linux
The Linux kernel can leave a PMD spinlock held when check_stable_address_space() fails during device-memory migration, causing a deadlock. The input does not specify how an attacker could trigger this condition or whether access or user interaction is required.
Engineers running the Linux kernel should check their installations; affected versions are not specified.