comedi: Flush partial mappings in error case
Linux
Affected versions
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
Linux
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
≥ ed9eccbe8970f6eedc1b978c157caf1251a896d4 · < c6963a06ce5c61d3238751ada04ee1569663a828| No fix yet |
| Linux Linux |
|
|
In the Linux kernel, the following vulnerability has been resolved:
comedi: Flush partial mappings in error case
If some remap_pfn_range() calls succeeded before one failed, we still have buffer pages mapped into the userspace page tables when we drop the buffer reference with comedi_buf_map_put(bm). The userspace mappings are only cleaned up later in the mmap error path.
Fix it by explicitly flushing all mappings in our VMA on the error path.
See commit 79a61cc3fc04 ("mm: avoid leaving partial pfn mappings around in error case").
From the CVE record · Linux
The Linux kernel’s comedi code can leave buffer pages mapped into userspace page tables if a remap operation fails after earlier mappings succeeded. This occurs on a local mmap error path; the input does not specify an exploit outcome or authentication requirements.
Engineers running Linux kernels with comedi should check their deployments; affected versions are not specified.