CVE-2026-31656
Vulnerability Summary
Timeline
Description
In the Linux kernel, the following vulnerability has been resolved: drm/i915/gt: fix refcount underflow in intel_engine_park_heartbeat A use-after-free / refcount underflow is possible when the heartbeat worker and intel_engine_park_heartbeat() race to release the same engine->heartbeat.systole request. The heartbeat worker reads engine->heartbeat.systole and calls i915_request_put() on it when the request is complete, but clears the pointer in a separate, non-atomic step. Concurrently, a request retirement on another CPU can drop the engine wakeref to zero, triggering __engine_park() -> intel_engine_park_heartbeat(). If the heartbeat timer is pending at that point, cancel_delayed_work() returns true and intel_engine_park_heartbeat() reads the stale non-NULL systole pointer and calls i915_request_put() on it again, causing a refcount underflow: ``` <4> [487.221889] Workqueue: i915-unordered engine_retire [i915] <4> [487.222640] RIP: 0010:refcount_warn_saturate+0x68/0xb0 ... <4> [487.222707] Call Trace: <4> [487.222711] <TASK> <4> [487.222716] intel_engine_park_heartbeat.part.0+0x6f/0x80 [i915] <4> [487.223115] intel_engine_park_heartbeat+0x25/0x40 [i915] <4> [487.223566] __engine_park+0xb9/0x650 [i915] <4> [487.223973] ____intel_wakeref_put_last+0x2e/0xb0 [i915] <4> [487.224408] __intel_wakeref_put_last+0x72/0x90 [i915] <4> [487.224797] intel_context_exit_engine+0x7c/0x80 [i915] <4> [487.225238] intel_context_exit+0xf1/0x1b0 [i915] <4> [487.225695] i915_request_retire.part.0+0x1b9/0x530 [i915] <4> [487.226178] i915_request_retire+0x1c/0x40 [i915] <4> [487.226625] engine_retire+0x122/0x180 [i915] <4> [487.227037] process_one_work+0x239/0x760 <4> [487.227060] worker_thread+0x200/0x3f0 <4> [487.227068] ? __pfx_worker_thread+0x10/0x10 <4> [487.227075] kthread+0x10d/0x150 <4> [487.227083] ? __pfx_kthread+0x10/0x10 <4> [487.227092] ret_from_fork+0x3d4/0x480 <4> [487.227099] ? __pfx_kthread+0x10/0x10 <4> [487.227107] ret_from_fork_asm+0x1a/0x30 <4> [487.227141] </TASK> ``` Fix this by replacing the non-atomic pointer read + separate clear with xchg() in both racing paths. xchg() is a single indivisible hardware instruction that atomically reads the old pointer and writes NULL. This guarantees only one of the two concurrent callers obtains the non-NULL pointer and performs the put, the other gets NULL and skips it. (cherry picked from commit 13238dc0ee4f9ab8dafa2cca7295736191ae2f42)
CVSS Metrics
- v4.0•HIGH•Score: 7.3CVSS:4.0/AV:L/AC:H/AT:P/PR:L/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N
- v3.1•HIGH•Score: 7.8CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H
EPSS Trends
Current EPSS score: 0.12%• Percentile: 2%
Techniques & Countermeasures
- CWE-191•Integer Underflow (Wrap or Wraparound)
The product subtracts one value from another, such that the result is less than the minimum allowable integer value, which produces a value that is not equal to the correct result.
Affected Systems
- debian•linux
< 5.10.259-1 | < 6.1.170-1 | < 6.12.85-1 | < 6.19.13-1
- debian•linux-6.1
< 6.1.170-1~deb11u1
- ubuntu•linux
< 5.15.0-186.196 | < 6.8.0-136.136 | all
- ubuntu•linux-allwinner-5.19
all
- ubuntu•linux-aws
< 5.15.0-1112.119 | < 6.8.0-1061.64 | all
- ubuntu•linux-aws-5.0
all
- ubuntu•linux-aws-5.11
all
- ubuntu•linux-aws-5.13
all
- ubuntu•linux-aws-5.15
< 5.15.0-1112.119~20.04.1
- ubuntu•linux-aws-5.19
all
- ubuntu•linux-aws-5.3
all
- ubuntu•linux-aws-5.8
all
- ubuntu•linux-aws-6.14
all
- ubuntu•linux-aws-6.17
all
- ubuntu•linux-aws-6.2
all
- ubuntu•linux-aws-6.5
all
- ubuntu•linux-aws-6.8
< 6.8.0-1061.64~22.04.1
- ubuntu•linux-aws-fips
all | < 5.15.0-1112.119+fips1 | < 6.8.0-1061.64+fips1
- ubuntu•linux-azure
all | < 5.15.0-1117.126 | < 6.8.0-1063.71 | all
- ubuntu•linux-azure-5.11
all
- ubuntu•linux-azure-5.13
all
- ubuntu•linux-azure-5.15
< 5.15.0-1117.126~20.04.1
- ubuntu•linux-azure-5.19
all
- ubuntu•linux-azure-5.3
all
- ubuntu•linux-azure-5.8
all
- ubuntu•linux-azure-6.11
all
- ubuntu•linux-azure-6.14
all
- ubuntu•linux-azure-6.17
all
- ubuntu•linux-azure-6.2
all
- ubuntu•linux-azure-6.5
all
- ubuntu•linux-azure-6.8
< 6.8.0-1063.71~22.04.1
- ubuntu•linux-azure-edge
all
- ubuntu•linux-azure-fde
all | < 5.15.0-1117.126 | < 6.8.0-1062.69 | all | all
- ubuntu•linux-azure-fde-5.15
< 5.15.0-1117.126~20.04.2
- ubuntu•linux-azure-fde-5.19
all
- ubuntu•linux-azure-fde-6.14
all
- ubuntu•linux-azure-fde-6.2
all
- ubuntu•linux-azure-fde-6.8
< 6.8.0-1062.69~22.04.1
- ubuntu•linux-azure-fde-7.0
all
- ubuntu•linux-azure-fips
all | < 5.15.0-1117.126+fips1 | < 6.8.0-1063.71+fips2
- ubuntu•linux-azure-nvidia
all
- ubuntu•linux-azure-nvidia-6.14
all
- ubuntu•linux-bluefield
all | < 5.15.0-1096.98 | < 6.8.0-1028.33
- ubuntu•linux-fips
all | < 5.15.0-186.196+fips1 | < 6.8.0-136.136+fips2
- ubuntu•linux-gcp
all | < 5.15.0-1112.122 | < 6.8.0-1064.72 | all
- ubuntu•linux-gcp-5.11
all
- ubuntu•linux-gcp-5.13
all
- ubuntu•linux-gcp-5.15
all | < 5.15.0-1112.122~20.04.1
- ubuntu•linux-gcp-5.19
all
- ubuntu•linux-gcp-5.3
all
Showing first 50 affected entries in server-rendered view.
References (38)
- https://git.kernel.org/stable/c/70d3e622b10092fc483e28e57b4e8c49d9cc7f68
- https://git.kernel.org/stable/c/8ce44d28a84fd5e053a88b04872a89d95c0779d4
- https://git.kernel.org/stable/c/ca3f48c3567dd49efdc55b80029ae74659c682ee
- https://git.kernel.org/stable/c/a00e92bf6583d019a4fb2c2df7007e6c9b269ce7
- https://git.kernel.org/stable/c/2af8b200cae3fdd0e917ecc2753b28bb40c876c1
- https://git.kernel.org/stable/c/455d98ed527fc94eed90406f90ab2391464ca657
- https://git.kernel.org/stable/c/4c71fd099513bfa8acab529b626e1f0097b76061
- https://git.kernel.org/stable/c/82034799c6c14b3104668878c3f3e5786f777126
- https://ubuntu.com/security/CVE-2026-31656
- https://www.cve.org/CVERecord?id=CVE-2026-31656
- https://git.kernel.org/linus/4c71fd099513bfa8acab529b626e1f0097b76061
- https://ubuntu.com/security/notices/USN-8567-1
- https://ubuntu.com/security/notices/USN-8574-1
- https://ubuntu.com/security/notices/USN-8575-1
- https://ubuntu.com/security/notices/USN-8576-1
- https://ubuntu.com/security/notices/USN-8574-2
- https://ubuntu.com/security/notices/USN-8595-1
- https://ubuntu.com/security/notices/USN-8596-1
- https://ubuntu.com/security/notices/USN-8575-2
- https://ubuntu.com/security/notices/USN-8576-2
- https://ubuntu.com/security/notices/USN-8597-1
- https://ubuntu.com/security/notices/USN-8595-2
- https://ubuntu.com/security/notices/USN-8606-1
- https://ubuntu.com/security/notices/USN-8607-1
- https://ubuntu.com/security/notices/USN-8608-1
- https://ubuntu.com/security/notices/USN-8609-1
- https://ubuntu.com/security/notices/USN-8575-3
- https://ubuntu.com/security/notices/USN-8610-1
- https://ubuntu.com/security/notices/USN-8574-3
- https://ubuntu.com/security/notices/USN-8595-3
- https://ubuntu.com/security/notices/USN-8619-1
- https://ubuntu.com/security/notices/USN-8620-1
- https://ubuntu.com/security/notices/USN-8620-2
- https://ubuntu.com/security/notices/USN-8620-3
- https://ubuntu.com/security/notices/USN-8620-4
- https://security-tracker.debian.org/tracker/CVE-2026-31656
- https://ubuntu.com/security/notices/USN-8665-1
- https://ubuntu.com/security/notices/USN-8668-1