media: meson: vdec: size capture planes from the aligned canvas

State
Published
Severity
Not Scored
Published
Nov 30, 2026
Updated
Nov 30, 2026
Reserved
Nov 30, 2026

Read the record on cve.org

Description

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

media: meson: vdec: size capture planes from the aligned canvas

The decoder writes a whole canvas of ALIGN(width, 32) x ALIGN(height, 32) (amvdec_set_canvases()) and reports bytesperline = ALIGN(width, 32), but get_output_size() derives sizeimage from the raw width x height.

When the width is not a multiple of 32 the planes are too small for the advertised stride: for 720x360 NV12M the luma plane is 262144 bytes while 736 * 360 = 264960 are needed (282624 for the canvas the firmware fills). The decoder writes past the buffer, and importing the capture dma-buf into DRM fails: drmModeAddFB2() returns -EINVAL, so e.g. Kodi plays the sound over a black screen. 1280x720 and 1920x1080 are not affected.

Size the planes from the aligned canvas the hardware actually uses.

Tested on an S905X (GXL p212) board with LibreELEC 12 (6.16.0-rc3): 720x360 and 1920x1080 H.264 play through V4L2 m2m + DRM PRIME with no AddFB2 errors.

ProductVersions
Linux Linux3e7f51bd96077acad6acd7b45668f65b44233c4e to before c587de78ffa123d17a93026d78da7e76823cc4e0 Affected3e7f51bd96077acad6acd7b45668f65b44233c4e to before cb46dc57d169509e69a3e218e970785c2b79f7f8 Affected3e7f51bd96077acad6acd7b45668f65b44233c4e to before 6668d9052231ae3daf6c8bfc8f6d379f1f35ffd5 Affected3e7f51bd96077acad6acd7b45668f65b44233c4e to before 0d6bc58d7f319c63f8525efb630de1ce55b7d780 Affected3e7f51bd96077acad6acd7b45668f65b44233c4e to before 10a7475bc6d1cef7d5c1e7f27c8de4a011ebbbed Affected3e7f51bd96077acad6acd7b45668f65b44233c4e to before b186accb1d7d8f9aa7b5183d7eb9ff26ac568ce3 Affected3e7f51bd96077acad6acd7b45668f65b44233c4e to before 2f643182e4feef3a41bec2dd98c1294750392326 Affected3e7f51bd96077acad6acd7b45668f65b44233c4e to before b3a805dd5a83ba8c85e2085d3411eb9975e0aea4 Affected
Linux Linux5.3 Affectedbefore 5.3 Not Affected5.10.275 through 5.10.* Not Affected5.15.226 through 5.15.* Not Affected6.1.193 through 6.1.* Not Affected6.6.163 through 6.6.* Not Affected6.12.117 through 6.12.* Not Affected6.18.63 through 6.18.* Not Affected7.3.4 through 7.3.* Not Affected7.4-rc1 and later Not Affected

Weaknesses

The record names no weakness.

References

Every record here comes from the CVE Program's CVE List. © 1999-2026 The MITRE Corporation. CVE is a registered trademark of The MITRE Corporation. The records are reproduced under the CVE Program terms of use.

© 2026 NVIDIA, the NVIDIA logo, and NVIDIA Inception are trademarks and/or registered trademarks of NVIDIA Corporation in the U.S. and other countries.