KernelScan.io

HIGH

drm Plane Overflow

CVE-2026-46209

CVSS 7.8 / 10.0 NVD

CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H

KernelScan AI7.8HIGH

01

In the Linux kernel, the following vulnerability has been resolved: drm/gem: Fix inconsistent plane dimension calculation in drm_gem_fb_init_with_funcs() drm_gem_fb_init_with_funcs() computes sub-sampled plane dimensions using plain integer division: unsigned int width = mode_cmd->width / (i ? info->hsub : 1); unsigned int height = mode_cmd->height / (i ? info->vsub : 1); However, the ioctl-level framebuffer_check() in drm_framebuffer.c uses drm_format_info_plane_width/height() which round up dimensions via DIV_ROUND_UP(). This inconsistency corrupts the subsequent GEM object size check for certain pixel format and dimension combinations. For example, with NV12 (vsub=2) and a 1-pixel-tall framebuffer the GEM size validation path sees height=0 instead of height=1. The expression (height - 1) then wraps to UINT_MAX as an unsigned int, causing min_size to overflow and wrap back to a small value. A tiny GEM object therefore passes the size guard, yet when the GPU accesses the chroma plane it will read or write memory beyond the object's bounds. Fix by replacing the open-coded divisions with drm_format_info_plane_width() and drm_format_info_plane_height(), which use DIV_ROUND_UP() and match the calculation already used in framebuffer_check().

02

Engine v0.2.0

Risk summary

Local users with access to DRM device nodes can trigger an out-of-bounds GPU memory access due to inconsistent plane-dimension rounding during framebuffer initialization. This leads to kernel memory corruption and potential information disclosure on systems with active graphics hardware.

Affecteddrivers/gpu/drm/drm_gem_framebuffer_helper.c (DRM graphics)

Vulnerability analysis

The vulnerability is caused by mismatched buffer-size calculations in the DRM framebuffer helper. drm_gem_fb_init_with_funcs() used plain integer division for subsampled plane dimensions, while framebuffer_check() rounded up with DIV_ROUND_UP(). For formats like NV12 with a 1-pixel height, the init path computed height=0, causing (height - 1) to underflow to UINT_MAX. The subsequent min_size calculation wrapped, allowing an undersized GEM object to pass validation. When the GPU later accessed the chroma plane, it performed out-of-bounds reads and writes beyond the allocated buffer. The fix replaces the open-coded divisions with drm_format_info_plane_width/height() so both paths agree.

03

BranchFixed inPatch commit
5.105.10.25811427ad6c9f0
5.155.15.209adfc5ba4ef4d
6.16.1.17522922f7dae74
6.126.12.901da4ab7189f1
6.186.18.321a17ea9861e8
6.66.6.1406b992591e04f
7.07.0.9c5fc49d8470c
mainline7.1-rc23d4c2268bd72