CVE-2025-71298

drm/tests: shmem: Hold reservation lock around madvise

Published May 8, 2026 CVSS 3.1 · 5.5 Medium EPSS < 1% KEV · Not listed
Description
In the Linux kernel, the following vulnerability has been resolved:

drm/tests: shmem: Hold reservation lock around madvise

Acquire and release the GEM object's reservation lock around calls
to the object's madvide operation. The tests use
drm_gem_shmem_madvise_locked(), which led to errors such as show below.

[ 58.339389] WARNING: CPU: 1 PID: 1352 at drivers/gpu/drm/drm_gem_shmem_helper.c:499 drm_gem_shmem_madvise_locked+0xde/0x140

Only export the new helper drm_gem_shmem_madvise() for Kunit tests.
This is not an interface for regular drivers.

Analysis

AI-generated

Technical impact

The Linux kernel’s DRM shmem tests contain a helper, drm_gem_shmem_madvise_locked, that releases the GEM object’s reservation lock while a madvise operation is in progress. This releases the lock too early, creating a race condition that manifests as kernel warning messages and could corrupt kernel state or cause a crash. The flaw is isolated to this test helper and is not part of the public DRM driver API.

Affected Systems

Any build of the Linux kernel that includes the unpatched drm_gem_shmem_madvise_locked helper is affected. Development and test environments that compile the original helper are impacted; production configurations that omit these test helpers are unlikely to suffer the issue.

Risk and Exploitability

The EPSS score is < 1% and the vulnerability is not listed in CISA KEV, indicating a very low exploitation probability. Because the flaw exists only in a test helper invoked by the Kunit test framework, the inferred attack vector requires executing that test helper in an environment where it is enabled. A successful exploitation could trigger kernel warnings, state corruption, or a crash, consistent with the moderate CVSS score of 5.5.

Remediation

No solution or workaround provided in the CVE record.

OpenCVE Recommended Actions

  • Apply the kernel patch that surrounds madvise calls with the reservation lock, replacing the problematic drm_gem_shmem_madvise_locked implementation with the updated drm_gem_shmem_madvise helper.
  • Disable or remove any build configurations that enable the old shmem test helper from the kernel when deploying in a production environment.
  • Keep the Linux kernel updated to versions that contain this fix.

Generated by OpenCVE AI on May 14, 2026 at 23:57 UTC.

Tracking

Sign in to view the affected projects.

Advisories

No advisories available
History
Type Values Removed Values Added
Metrics ssvc

{'options': {'Automatable': 'no', 'Exploitation': 'none', 'Technical Impact': 'partial'}, 'version': '2.0.3'}

Type Values Removed Values Added
Weaknesses CWE-362
Type Values Removed Values Added
Weaknesses NVD-CWE-noinfo
Type Values Removed Values Added
References
Metrics threat_severity

None

cvssV3_1

{'score': 5.5, 'vector': 'CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H'}

threat_severity

Moderate

Type Values Removed Values Added
Weaknesses CWE-362
Type Values Removed Values Added
Description In the Linux kernel, the following vulnerability has been resolved: drm/tests: shmem: Hold reservation lock around madvise Acquire and release the GEM object's reservation lock around calls to the object's madvide operation. The tests use drm_gem_shmem_madvise_locked(), which led to errors such as show below. [ 58.339389] WARNING: CPU: 1 PID: 1352 at drivers/gpu/drm/drm_gem_shmem_helper.c:499 drm_gem_shmem_madvise_locked+0xde/0x140 Only export the new helper drm_gem_shmem_madvise() for Kunit tests. This is not an interface for regular drivers.
Title drm/tests: shmem: Hold reservation lock around madvise
First Time appeared Linux
Linux linux Kernel
CPEs cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*
Vendors & Products Linux
Linux linux Kernel
References
Weaknesses

Sources

Status
PUBLISHED
Assigner
Linux
Published
Updated
Nov 5, 2026, 9:23 PM
Reserved
May 6, 2026, 11:31 AM
Status
Analyzed
Published
May 8, 2026, 2:16 PM
Modified
Nov 5, 2026, 10:17 PM
Severity
Moderate
Public date
May 8, 2026, 12:00 AM