In the Linux kernel, the following vulnerability has been resolved:
virtiopmem: add the missing REQOP_WRITE for flush bio
When doing mkfs.xfs on a pmem device, the following warning was
------------[ cut here ]------------ WARNING: CPU: 2 PID: 384 at block/blk-core.c:751 submitbionoacct Modules linked in: CPU: 2 PID: 384 Comm: mkfs.xfs Not tainted 6.4.0-rc7+ #154 Hardware name: QEMU Standard PC (i440FX + PIIX, 1996) RIP: 0010:submitbionoacct+0x340/0x520 ...... Call Trace: <TASK> ? submitbionoacct+0xd5/0x520 submitbio+0x37/0x60 asyncpmemflush+0x79/0xa0 nvdimmflush+0x17/0x40 pmemsubmitbio+0x370/0x390 _submitbio+0xbc/0x190 submitbionoacctnocheck+0x14d/0x370 submitbionoacct+0x1ef/0x520 submitbio+0x55/0x60 submitbiowait+0x5a/0xc0 blkdevissueflush+0x44/0x60
The root cause is that submitbionoacct() needs bioop() is either WRITE or ZONEAPPEND for flush bio and asyncpmemflush() doesn't assign REQOPWRITE when allocating flush bio, so submitbionoacct just fail the flush bio.
Simply fix it by adding the missing REQOPWRITE for flush bio. And we could fix the flush order issue and do flush optimization later.
{
"osv_generated_from": "https://github.com/CVEProject/cvelistV5/tree/main/cves/2023/54xxx/CVE-2023-54089.json",
"cna_assigner": "Linux"
}