CVE-2026-64280: fpga: dfl-afu: validate DMA mapping length in afu_dma_map_region()

Greg Kroah-Hartman <[email protected]> Sat, 25 Jul 2026 10:48:17 +0200
Newsgroups org.kernel.vger.linux-cve-announce
Message-ID <2026072502-CVE-2026-64280-0e16@gregkh>
From: Greg Kroah-Hartman <[email protected]>

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

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

fpga: dfl-afu: validate DMA mapping length in afu_dma_map_region()

afu_ioctl_dma_map() accepts a 64-bit length from userspace via
DFL_FPGA_PORT_DMA_MAP ioctl without an upper bound check. The value
is passed to afu_dma_pin_pages() where npages is derived as
length >> PAGE_SHIFT and passed to pin_user_pages_fast() which takes
int nr_pages, causing implicit truncation if length is very large.

Validate map.length at the ioctl entry point before calling
afu_dma_map_region(), rejecting values whose page count exceeds
INT_MAX.

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


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

	Issue introduced in 4.19 with commit fa8dda1edef9ebc3af467c644c5533ac97171e12 and fixed in 6.18.39 with commit 59070040fd12e0b78d7b4d341d9f9a183237c5ff
	Issue introduced in 4.19 with commit fa8dda1edef9ebc3af467c644c5533ac97171e12 and fixed in 7.1.4 with commit fb2c0eab51ae5b02d2bae7d67c2cfbec39b57231
	Issue introduced in 4.19 with commit fa8dda1edef9ebc3af467c644c5533ac97171e12 and fixed in 7.2-rc1 with commit fc3b071a7c8dc0f5d56defddf6e6fd5aaa3e1e27

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-64280
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/fpga/dfl-afu-main.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/59070040fd12e0b78d7b4d341d9f9a183237c5ff
	https://git.kernel.org/stable/c/fb2c0eab51ae5b02d2bae7d67c2cfbec39b57231
	https://git.kernel.org/stable/c/fc3b071a7c8dc0f5d56defddf6e6fd5aaa3e1e27