Received: from smtp.kernel.org (aws-us-west-2-korg-mail-alma10-1.taild15c8.ts.net [100.103.45.18]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 222144C14EC for ; Sun, 18 Oct 2026 15:24:22 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=100.103.45.18 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1792337066; cv=none; b=XIrquxnHvaAEUXh1iFFn+E4Vq27jGQ35/PfSRGbmiOCJWc5ArN2qtackQvm5dTsI4eKQgRzkGff0G0eRYle9nK25UVK33nVe5N58h+kPQcoTTGx8x5fXbGh9jGucvntFxF8Gfvd5mgdOIxAQD19Lk+0W8nvM5u2Uc9MYuTNNyhE= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1792337066; c=relaxed/simple; bh=Q1+FAayaVVocnawiN6jYIgBtThKASnrcd3n2yoiZ2QY=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=EquilWSVr58WWBhvnWSJIgSlwDeBUZ66aywkPL/aMIoElO81uQYMEzNoTTGCYlhmlke2ewYLB/F7AuCvswXjTUAhiODvV3CRZG9MUcyK8kySI65oVdXwFHMGYjSlPRg4qE4Kp/pVl/vC4KvyZpBkWGv3GTcQDYrId9CVzq21klI= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=NEYlWRaG; arc=none smtp.client-ip=100.103.45.18 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b="NEYlWRaG" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 4EC4B1F000C4; Sun, 18 Oct 2026 15:24:21 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linuxfoundation.org; s=korg; t=1792337062; bh=GEVSNwHzPD06wF/vxEZkZkLpgaBpeNcOpBH8WqZqWZY=; h=From:To:Cc:Subject:Date:Reply-To; b=NEYlWRaGEvsfEO2UOHZNDg43nw12YAbNqAYOSU5oqka3JJ+34abzt87IZixOKJ9DH TMCreE5SfrcJgll1jhk5dj4dKBmqbtpxIQi9/Jnxqccly/5KARcr6ymskaM9/zZF0Z Im+3skQxotIRnDpH0hu3WED1g+USMpCM7MhF12U8= From: Greg Kroah-Hartman To: linux-cve-announce@vger.kernel.org Cc: Greg Kroah-Hartman Subject: CVE-2026-98508: drm/virtio: fix NULL pointer dereference on fence allocation failure Date: Sun, 18 Oct 2026 17:16:12 +0200 Message-ID: <2026101819-CVE-2026-98508-b43c@gregkh> X-Mailer: git-send-email 2.56.0 Reply-To: , Precedence: bulk X-Mailing-List: linux-cve-announce@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=7486; i=gregkh@linuxfoundation.org; h=from:subject:message-id; bh=2BCkKW4V7bKxCq+GO4zIo8RzZpUn7K+ecw8mYQRFiro=; b=owGbwMvMwCRo6H6F97bub03G02pJDFlXHnWYsco+VWZ8ZxcwldN4vT2P8pZ9totqbO4Z9V80t N16ot60I5aFQZCJQVZMkeXLNp6j+ysOKXoZ2p6GmcPKBDKEgYtTACZiz8uwYMLrEzOeR/xqSHku mJkkb6pxqco4imHBkrj61jfiFpcSJkS5vdqrOi9JYvIfAA== X-Developer-Key: i=gregkh@linuxfoundation.org; a=openpgp; fpr=F4B60CC5BF78C2214A313DCB3147D40DDB2DFB29 Content-Transfer-Encoding: 8bit From: Greg Kroah-Hartman Description =========== In the Linux kernel, the following vulnerability has been resolved: drm/virtio: fix NULL pointer dereference on fence allocation failure virtio_gpu_fence_alloc() can fail due to memory pressure and return NULL, but its caller like virtio_gpu_init_submit() never checks it. Later, virtio_gpu_init_submit() passes the NULL fence to virtio_gpu_fence_event_create(), which unconditionally dereferences it. Found when fuzzing the virtio driver with Syzkaller: Oops: general protection fault, probably for non-canonical address 0xdffffc0000000012: 0000 [#1] SMP KASAN NOPTI KASAN: null-ptr-deref in range [0x0000000000000090-0x0000000000000097] CPU: 1 UID: 0 PID: 9991 Comm: syz.0.121 Not tainted 7.2.0 #4 PREEMPT(full) Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS rel-1.17.0-0-gb52ca86e094d-prebuilt.qemu.org 04/01/2014 RIP: 0010:virtio_gpu_fence_event_create drivers/gpu/drm/virtio/virtgpu_submit.c:295 [inline] RIP: 0010:virtio_gpu_init_submit drivers/gpu/drm/virtio/virtgpu_submit.c:398 [inline] RIP: 0010:virtio_gpu_execbuffer_ioctl+0xc78/0x1aa0 drivers/gpu/drm/virtio/virtgpu_submit.c:505 Code: 85 ed 0f 85 21 09 00 00 e8 05 5a c9 fb 48 8b 44 24 10 48 8d b8 90 00 00 00 48 b8 00 00 00 00 00 fc ff df 48 89 fa 48 c1 ea 03 <80> 3c 02 00 0f 85 9a 0d 00 00 48 8b 44 24 10 4c 89 b0 90 00 00 00 RSP: 0018:ffffc900039dfad0 EFLAGS: 00010216 RAX: dffffc0000000000 RBX: ffffc900039dfdd8 RCX: ffffffff85f6fd3d RDX: 0000000000000012 RSI: ffffffff85f6fd4b RDI: 0000000000000090 RBP: 0000000000000000 R0virtio_gpu_virgl_process_cmd: ctrl 0x102, error 0x1203 R10: 0000000000000000 R11: 0000000000000000 R12: ffff8880132c4000 R13: 0000000000000000 R14: ffff888073b6c700 R15: 000000000000003b FS: 00007fab480b96c0(0000) GS:ffff8880eb6e9000(0000) knlGS:0000000000000000 CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 CR2: 00007effbf5e55a8 CR3: 0000000048d19000 CR4: 0000000000350ef0 Call Trace: drm_ioctl_kernel+0x1f4/0x3e0 drivers/gpu/drm/drm_ioctl.c:817 drm_ioctl+0x5f4/0xc70 drivers/gpu/drm/drm_ioctl.c:914 vfs_ioctl fs/ioctl.c:51 [inline] __do_sys_ioctl fs/ioctl.c:597 [inline] __se_sys_ioctl fs/ioctl.c:583 [inline] __x64_sys_ioctl+0x18e/0x210 fs/ioctl.c:583 do_syscall_x64 arch/x86/entry/syscall_64.c:63 [inline] do_syscall_64+0x116/0x800 arch/x86/entry/syscall_64.c:94 entry_SYSCALL_64_after_hwframe+0x77/0x7f RIP: 0033:0x7fab471a82bd Code: ff c3 66 2e 0f 1f 84 00 00 00 00 00 90 f3 0f 1e fa 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 c7 c1 b0 ff ff ff f7 d8 64 89 01 48 RSP: 002b:00007fab480b9018 EFLAGS: 00000246 ORIG_RAX: 0000000000000010 RAX: ffffffffffffffda RBX: 00007fab47435fa0 RCX: 00007fab471a82bd RDX: 00002000000000c0 RSI: 00000000c0406442 RDI: 0000000000000003 RBP: 00007fab480b9080 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000001 R13: 00007fab47436038 R14: 00007fab47435fa0 R15: 00007ffe85ab0740 Modules linked in: ---[ end trace 0000000000000000 ]--- RIP: 0010:virtio_gpu_fence_event_create drivers/gpu/drm/virtio/virtgpu_submit.c:295 [inline] RIP: 0010:virtio_gpu_init_submit drivers/gpu/drm/virtio/virtgpu_submit.c:398 [inline] RIP: 0010:virtio_gpu_execbuffer_ioctl+0xc78/0x1aa0 drivers/gpu/drm/virtio/virtgpu_submit.c:505 Code: 85 ed 0f 85 21 09 00 00 e8 05 5a c9 fb 48 8b 44 24 10 48 8d b8 90 00 00 00 48 b8 00 00 00 00 00 fc ff df 48 89 fa 48 c1 ea 03 <80> 3c 02 00 0f 85 9a 0d 00 00 48 8b 44 24 10 4c 89 b0 90 00 00 00 RSP: 0018:ffffc900039dfad0 EFLAGS: 00010216 RAX: dffffc0000000000 RBX: ffffc900039dfdd8 RCX: ffffffff85f6fd3d RDX: 0000000000000012 RSI: ffffffff85f6fd4b RDI: 0000000000000090 RBP: 0000000000000000 R08: 0000000000000005 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000000 R12: ffff8880132c4000 R13: 0000000000000000 R14: ffff888073b6c700 R15: 000000000000003b FS: 00007fab480b96c0(0000) GS:ffff888098ae9000(0000) knlGS:0000000000000000 CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 CR2: 00007f24c3759000 CR3: 0000000048d19000 CR4: 0000000000350ef0 ---------------- Code disassembly (best guess): 0: 85 ed test %ebp,%ebp 2: 0f 85 21 09 00 00 jne 0x929 8: e8 05 5a c9 fb call 0xfbc95a12 d: 48 8b 44 24 10 mov 0x10(%rsp),%rax 12: 48 8d b8 90 00 00 00 lea 0x90(%rax),%rdi 19: 48 b8 00 00 00 00 00 movabs $0xdffffc0000000000,%rax 20: fc ff df 23: 48 89 fa mov %rdi,%rdx 26: 48 c1 ea 03 shr $0x3,%rdx * 2a: 80 3c 02 00 cmpb $0x0,(%rdx,%rax,1) <-- trapping instruction 2e: 0f 85 9a 0d 00 00 jne 0xdce 34: 48 8b 44 24 10 mov 0x10(%rsp),%rax 39: 4c 89 b0 90 00 00 00 mov %r14,0x90(%rax) Fix by checking virtio_gpu_fence_alloc() in virtio_gpu_init_submit() and returning -ENOMEM before any later code can dereference the NULL fence. The Linux kernel CVE team has assigned CVE-2026-98508 to this issue. Affected and fixed versions =========================== Issue introduced in 6.6 with commit 70d1ace56db6c79d39dbe9c0d5244452b67e2fde and fixed in 6.6.158 with commit 9571ab7493561afb4624d69572a7ebb67d76d10f Issue introduced in 6.6 with commit 70d1ace56db6c79d39dbe9c0d5244452b67e2fde and fixed in 6.12.112 with commit a8b83ed4a4b1d04c756f53e375e86d3881f66e72 Issue introduced in 6.6 with commit 70d1ace56db6c79d39dbe9c0d5244452b67e2fde and fixed in 6.18.55 with commit f2f1683955b95c9b958069da3050f7e8e129ff88 Issue introduced in 6.6 with commit 70d1ace56db6c79d39dbe9c0d5244452b67e2fde and fixed in 7.2.9 with commit ecced0076b700b5896e52af10d0776be8be36b0d Issue introduced in 6.6 with commit 70d1ace56db6c79d39dbe9c0d5244452b67e2fde and fixed in 7.3-rc5 with commit 846b3c64fe3e77d9db20a7e3e62dbbb637c773e1 Issue introduced in 6.1.54 with commit 98d3e7c5f757577394f036e0301db9e570342566 Issue introduced in 6.5.4 with commit 4037dcd70c3335600a2a95ec6229d70859bd37a1 Please see https://www.kernel.org for a full list of currently supported kernel versions by the kernel community. Unaffected versions might change over time as fixes are backported to older supported kernel versions. The official CVE entry at https://cve.org/CVERecord/?id=CVE-2026-98508 will be updated if fixes are backported, please check that for the most up to date information about this issue. Affected files ============== The file(s) affected by this issue are: drivers/gpu/drm/virtio/virtgpu_submit.c Mitigation ========== The Linux kernel CVE team recommends that you update to the latest stable kernel version for this, and many other bugfixes. Individual changes are never tested alone, but rather are part of a larger kernel release. Cherry-picking individual commits is not recommended or supported by the Linux kernel community at all. If however, updating to the latest release is impossible, the individual changes to resolve this issue can be found at these commits: https://git.kernel.org/stable/c/9571ab7493561afb4624d69572a7ebb67d76d10f https://git.kernel.org/stable/c/a8b83ed4a4b1d04c756f53e375e86d3881f66e72 https://git.kernel.org/stable/c/f2f1683955b95c9b958069da3050f7e8e129ff88 https://git.kernel.org/stable/c/ecced0076b700b5896e52af10d0776be8be36b0d https://git.kernel.org/stable/c/846b3c64fe3e77d9db20a7e3e62dbbb637c773e1