Skip to contentSkip to conversation

CVE-2026-93823: drm/amdkfd: Let driver decide buffer size at AMDKFD_IOC_GET_DMABUF_INFO ioctl

DISCUSSION Greg Kroah-Hartman 1 participant 1 message Sep 24

lore
Share & tools
lore
#0 lore raw

From: Greg Kroah-Hartman <[email protected]>

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

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

drm/amdkfd: Let driver decide buffer size at AMDKFD_IOC_GET_DMABUF_INFO ioctl

amdkfd driver needs allocate buffer to return bo metadata to user space. The buffer size is controlled by user currently. It is a potential security issue that hostile value (e.g. 2 GiB) lets any render-group user trigger order-MAX allocation/OOM in kernel context.

This patch first finds bo metadata size. If the size is smaller than user provided value drive can safely allocate buffer in kernel space and copy to user space buffer. If not, driver will let user know, not allocate and copy. User will redo with new buffer in user space.

This patch lets driver decide buffer allocation size to avoid potential hostile size from user space.

(cherry picked from commit f54ce9e8cbd3abe0eda3a285f54dc4f572fe589a)

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

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

	Fixed in 6.12.111 with commit a65ccabde6deb95baf9442bd98299e2248884162
	Fixed in 6.18.53 with commit 2d9fd0f01550aab4a0a1984b4379e50545906248
	Fixed in 7.2 with commit 8242a8d9d7194d5ef8a8b38a5621ca0966a3ec15

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-93823

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/amd/amdgpu/amdgpu_amdkfd.c drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd.h drivers/gpu/drm/amd/amdkfd/kfd_chardev.c

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/a65ccabde6deb95baf9442bd98299e2248884162
	https://git.kernel.org/stable/c/2d9fd0f01550aab4a0a1984b4379e50545906248
	https://git.kernel.org/stable/c/8242a8d9d7194d5ef8a8b38a5621ca0966a3ec15