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 CC1DA383983 for ; Tue, 6 Oct 2026 10:27:21 +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=1791282443; cv=none; b=XfIVAik5SCiGD081fFvR6xTOFfuOcAJS/31hIzV17HvAis1zVX8NBToD4YFFlsMb+OyPrE0jsbt0DzCReF6ORI1SaP157K/EE8ihxmK15BfZiAAILgBM80KsKXcvUc5LWcOnAzewOKbwuK7P62dLTYXqaHSp0rxo3BmIu0L6DEM= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1791282443; c=relaxed/simple; bh=0GovxwzBeiw4J0rlh0jKCTx4HFCHVV4i9AYAT6Wr1jQ=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=e3+woRqB05we/M8F9stqqwzoYTO8NZBUD5wBoIv17HcE+Fwkj08FRk5I/o5upLRHjv2sbVbFttIsidha/hXmQD5jwCuyteuwWciDAepyoQ+4oUvgn3LvTMlpJ8mlIxKfeiR4ZMJaDVWz7C/w77mrzhNnKHeRbsdgRCLh5YAogBE= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=fGBfXj4H; 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="fGBfXj4H" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 351D61F000FF; Tue, 6 Oct 2026 10:27:20 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linuxfoundation.org; s=korg; t=1791282441; bh=u4CYhSPtVsusJ1HUJP+AMbe7WBIE3QPYfAaXFOGwkRE=; h=From:To:Cc:Subject:Date:Reply-To; b=fGBfXj4HdLQjyo93zCgZfrIMvLuYlggWRCHpn0rmLedLnNjObEzYtM6py0tX1Qzib g+2W1Mn/Nm8tliBlQOlGCw9uKLpsfkXyrR62WDzDdBmhafo0Zbtw7QtBL+51Qxx1CU 0DVSyYQcuExaHuMF6ds6DdvQIGQ7uXMjiJvwf3uQ= From: Greg Kroah-Hartman To: linux-cve-announce@vger.kernel.org Cc: Greg Kroah-Hartman Subject: CVE-2026-98310: drm/xe/shrinker: Take a runtime PM ref before shrinking non-system memory Date: Tue, 6 Oct 2026 10:46:51 +0200 Message-ID: <2026100611-CVE-2026-98310-8ae4@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=3878; i=gregkh@linuxfoundation.org; h=from:subject:message-id; bh=wTw+c0MkHr+cZXNfCiVPDLDLX8rTwGPTSTk+mEEs+DI=; b=owGbwMvMwCRo6H6F97bub03G02pJDFlHtoqfc55yfq+b8Ou45W8cTslY5KWpKIp3bZs29Qgz+ 3kHdWO1jlgWBkEmBlkxRZYv23iO7q84pOhlaHsaZg4rE8gQBi5OAZiI9WyG+a4OIQ2id0I4zFv/ W+ktOnWeuXG7D8M8rVSPlvBt4XFpMz7LO8ff+RRrrh8OAA== 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/xe/shrinker: Take a runtime PM ref before shrinking non-system memory __xe_shrinker_walk() walks the SYSTEM and TT LRUs without a runtime PM reference. Shrinking a bo outside system memory invalidates its GPU mappings, which needs the device resumed, so while it is runtime suspended the page table zap trips an assert and the TLB invalidation returns -ENODEV: WARNING: drivers/gpu/drm/xe/xe_bo.c:770 at xe_bo_move_notify+0x1fc/0x450 [xe] xe_bo_shrink+0x20f/0x2b0 [xe] __xe_shrinker_walk+0x174/0x410 [xe] xe_shrinker_scan+0x10c/0x1e0 [xe] do_shrink_slab+0x176/0x7e0 drop_caches_sysctl_handler+0x9c/0xf0 Take a reference before walking a memory type other than XE_PL_SYSTEM and stop there if it cannot be acquired. Reuse the shrinker's existing acquire path, which resumes the device directly where reclaim allows that and otherwise queues the PM worker for a later scan. Stop the walk once the scan target is met, so a satisfied scan does not wake the device. System memory is still reclaimed while the device is suspended. Gate this on xe_device_is_l2_flush_optimized(), the same condition under which xe_bo_trigger_rebind() issues the invalidation for a non-fault-mode vm, so reclaim is unaffected elsewhere. The System CCS copy already has its own reference in xe_bo_shrink(). Only a non-fault-mode vm can reach this, since a fault-mode vm requires LR mode and that holds a runtime PM reference for the vm's lifetime. Reproduced with igt@xe_madvise@dontneed-before-exec while the GPU is runtime suspended. v2: simplify needs_rpm check. (Matt) retarget Fixes tag since the issue occurs with the non-fault-mode path added by 4e7ebff69aed. v3: handle this in xe_shrinker.c instead of xe_bo.c (Thomas) v4: stop the walk once the scan target is met. (Sashiko) v5: rebase on the freed page accounting fix. (Sashiko) v6: reuse the shrinker acquire path so runtime pm can be resumed directly instead of always queueing a worker. (Thomas) v7: replace xe_pm_runtime_put() with xe_shrinker_runtime_pm_put(). (Thomas) (cherry picked from commit 628f92b28bf4c371c10207daf6fc4caee0c0db2e) The Linux kernel CVE team has assigned CVE-2026-98310 to this issue. Affected and fixed versions =========================== Issue introduced in 7.1 with commit 4e7ebff69aed345f65f590a17b3119c0cb5eadde and fixed in 7.2.8 with commit b7f4d2588b1342bb190c04b3d7a32560f206c74c Issue introduced in 7.1 with commit 4e7ebff69aed345f65f590a17b3119c0cb5eadde and fixed in 7.3-rc4 with commit 985862be16c7e4da808c51f393d631fb60c0be5c 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-98310 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/xe/xe_shrinker.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/b7f4d2588b1342bb190c04b3d7a32560f206c74c https://git.kernel.org/stable/c/985862be16c7e4da808c51f393d631fb60c0be5c