All of lore.kernel.org
 help / color / mirror / Atom feed
* CVE-2026-99147: drm/exec: don't immediately add prelocked obj to array of locked objs
@ 2026-10-28 10:35 Greg Kroah-Hartman
  0 siblings, 0 replies; only message in thread
From: Greg Kroah-Hartman @ 2026-10-28 10:35 UTC (permalink / raw)
  To: linux-cve-announce; +Cc: Greg Kroah-Hartman

From: Greg Kroah-Hartman <gregkh@kernel.org>

Description
===========

In the Linux kernel, the following vulnerability has been resolved:

drm/exec: don't immediately add prelocked obj to array of locked objs

When a contention is detected the drm_exec object grabs a reference to
the contended object, unlocks all other objects and pre-locks the
contended one before anything else.

The problem is that it is possible that this pre-locked object was about
to be destroyed and drm_exec is now holding the last reference to it.

So we never actually see this pre-locked object again to be explicitly
locked and so also never reserve a slot for a dma_fence object on it.

Should the driver now use drm_exec_for_each_locked_object() to add a new
fence to all locked objects we eventually see a warning or even a
BUG_ON() to prevent random memory corruption.

Fix this by keeping the prelocked object out of the array of locked objs
until it was explicitly mentioned by the driver again.

If the prelocked object is never mentioned again by the driver
just unlock and drop the reference at the end of the locking loop.

The Linux kernel CVE team has assigned CVE-2026-99147 to this issue.


Affected and fixed versions
===========================

	Issue introduced in 6.6 with commit 09593216bff15866f95c8ad406cb7fdcec1ee40a and fixed in 6.18.59 with commit 96d9996e5dbcfabed052c0d9377a382c95fed607
	Issue introduced in 6.6 with commit 09593216bff15866f95c8ad406cb7fdcec1ee40a and fixed in 7.2.13 with commit 7a10cd79c4d9a90334fece32fef3a8e5b1a9727b
	Issue introduced in 6.6 with commit 09593216bff15866f95c8ad406cb7fdcec1ee40a and fixed in 7.3 with commit 26401a4999f1596a515b2e704e7066ac09306488

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-99147
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/drm_exec.c
	include/drm/drm_exec.h


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/96d9996e5dbcfabed052c0d9377a382c95fed607
	https://git.kernel.org/stable/c/7a10cd79c4d9a90334fece32fef3a8e5b1a9727b
	https://git.kernel.org/stable/c/26401a4999f1596a515b2e704e7066ac09306488

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2026-10-28 11:38 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-10-28 10:35 CVE-2026-99147: drm/exec: don't immediately add prelocked obj to array of locked objs Greg Kroah-Hartman

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.