{"id":"CVE-2026-99874","summary":"drm/amdkfd: Validate the control stack of a restored queue","details":"In the Linux kernel, the following vulnerability has been resolved:\n\ndrm/amdkfd: Validate the control stack of a restored queue\n\nkfd_criu_restore_queue() takes the control stack size from the\ncheckpoint image without the topology check create-queue does in\nkfd_queue_acquire_buffers(), which restore stopped calling in\ncommit 1cafa8b29e02 (\"drm/amdkfd: Don't acquire buffers\nduring CRIU queue restore.\"). An image size of 0x300000 is accepted and\nsizes the MQD allocation, and 0xFFFFFFFF trips a page allocator warning\nin kmalloc().\n\nrestore_mqd() also keeps the image's cp_hqd_cntl_stack_size,\ncp_hqd_cntl_stack_offset and cp_hqd_wg_state_offset. With offset \u003e size\nor wave state offset \u003c size, get_wave_state() returns wrapped sizes.\n\nTake the per-XCC size from topology, 0 for queues without a control\nstack, and reject larger images. In restore_mqd(), set the size to it\nand bound both offsets as init_mqd() does.\n\n(cherry picked from commit 92249023caee17bfc6f29c71d6aaa5f2298cf507)","modified":"2026-11-30T15:02:31.898270322Z","published":"2026-11-30T13:17:51.900Z","database_specific":{"cna_assigner":"Linux","osv_generated_from":"https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/99xxx/CVE-2026-99874.json"},"references":[{"type":"PACKAGE","url":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git"},{"type":"WEB","url":"https://git.kernel.org/stable/c/250e92ce55aa3c37ab0a7a6b8aad688e7bb8b25e"},{"type":"WEB","url":"https://git.kernel.org/stable/c/90d91a192751cd9a7d9d2286299bc72ec1c28179"},{"type":"WEB","url":"https://git.kernel.org/stable/c/9cfce679d88f6f83d15e99fdba0d5769120f0faf"},{"type":"WEB","url":"https://git.kernel.org/stable/c/a3e9af053b5e881025eb9358946a51ab4c61d22a"},{"type":"ADVISORY","url":"https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/99xxx/CVE-2026-99874.json"},{"type":"ADVISORY","url":"https://nvd.nist.gov/vuln/detail/CVE-2026-99874"}],"affected":[{"ranges":[{"type":"GIT","repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","events":[{"introduced":"626f7b3190b4c07917f0262162cb7fef7272c34d"},{"fixed":"a3e9af053b5e881025eb9358946a51ab4c61d22a"},{"fixed":"250e92ce55aa3c37ab0a7a6b8aad688e7bb8b25e"},{"fixed":"9cfce679d88f6f83d15e99fdba0d5769120f0faf"},{"fixed":"90d91a192751cd9a7d9d2286299bc72ec1c28179"}]}],"database_specific":{"source":"https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2026-99874.json"}},{"package":{"name":"Kernel","ecosystem":"Linux"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"5.18.0"},{"fixed":"6.12.119"}]},{"type":"ECOSYSTEM","events":[{"introduced":"6.13.0"},{"fixed":"6.18.65"}]},{"type":"ECOSYSTEM","events":[{"introduced":"6.19.0"},{"fixed":"7.3.4"}]}],"database_specific":{"source":"https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2026-99874.json"}}],"schema_version":"1.9.2"}