CRITICAL
block Biovec Corruption
CVE-2026-46115
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
KernelScan AI5.5MEDIUM
01Description
In the Linux kernel, the following vulnerability has been resolved: block: add pgmap check to biovec_phys_mergeable biovec_phys_mergeable() is used by the request merge, DMA mapping, and integrity merge paths to decide if two physically contiguous bvec segments can be coalesced into one. It currently has no check for whether the segments belong to different dev_pagemaps. When zone device memory is registered in multiple chunks, each chunk gets its own dev_pagemap. A single bio can legitimately contain bvecs from different pgmaps -- iov_iter_extract_bvecs() breaks at pgmap boundaries but the outer loop in bio_iov_iter_get_pages() continues filling the same bio. If such bvecs are physically contiguous, biovec_phys_mergeable() will coalesce them, making it impossible to recover the correct pgmap for the merged segment via page_pgmap(). Add a zone_device_pages_have_same_pgmap() check to prevent merging bvec segments that span different pgmaps.
02KernelScan AI Analysis
Risk summary
Systems using zone device memory (like persistent memory or GPU memory) with multiple memory chunks are at risk of data corruption during I/O operations. The block layer incorrectly merges physically contiguous segments from different device page maps, making it impossible to determine the correct page map for merged segments and potentially corrupting data during DMA operations.
Vulnerability analysis
The vulnerability occurs in biovec_phys_mergeable() which decides whether two physically contiguous bio vector segments can be coalesced. The function lacks validation to ensure segments belong to the same dev_pagemap when dealing with zone device memory. When zone device memory is registered in multiple chunks, each gets its own dev_pagemap, but physically contiguous segments from different pgmaps can be incorrectly merged. This breaks the ability to recover the correct pgmap via page_pgmap(), potentially leading to incorrect DMA mapping and data corruption. The fix adds a zone_device_pages_have_same_pgmap() check to prevent merging segments that span different pgmaps.
03Fix Versions
| Branch | Fixed in | Patch commit |
|---|---|---|
| 6.12 | 6.12.88 | a7f3aa8c9df3 |
| 6.18 | 6.18.30 | f17d52107532 |
| 6.6 | 6.6.140 | 3d2ecbd444b0 |
| 7.0 | 7.0.7 | f632dab4b841 |
| mainline | 7.1-rc1 | 13920e4b7b78 |