CVE-2026-98804: net: page_pool: fix use-after-free in page_pool_recycle_ring_bulk()
From: Greg Kroah-Hartman <[email protected]>
Description
===========
In the Linux kernel, the following vulnerability has been resolved:
net: page_pool: fix use-after-free in page_pool_recycle_ring_bulk()
With CONFIG_PAGE_POOL_STATS=y, page_pool_recycle_ring_bulk() updates the recycle stats after dropping the producer lock. If it just recycled the last inflight netmems of a pool being destroyed, page_pool_release() can pass its producer-lock barrier and free the pool before recycle_stat_add() runs.
Commit fcc680a647ba7 ("page_pool: allow mixing PPs within one bulk") moved this stat update after the unlock. Commit 271683bb2cf32 ("page_pool: Fix use-after-free in page_pool_recycle_in_ring") later added the barrier, but only fixed page_pool_recycle_in_ring(). Move the update back under the lock.
The Linux kernel CVE team has assigned CVE-2026-98804 to this issue.
Affected and fixed versions
===========================
Issue introduced in 6.14 with commit fcc680a647ba77370480fe753664cc10d572b240 and fixed in 6.18.56 with commit f78d45d5f1ac4141a03f033141368671da4293e4 Issue introduced in 6.14 with commit fcc680a647ba77370480fe753664cc10d572b240 and fixed in 7.2.10 with commit 0b105f4eb78e5ee39e5a74c47c9efd69b6ac849c Issue introduced in 6.14 with commit fcc680a647ba77370480fe753664cc10d572b240 and fixed in 7.3-rc6 with commit bdea4980182e3badac74f04df6c07492b91c569e
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-98804
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:
net/core/page_pool.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/f78d45d5f1ac4141a03f033141368671da4293e4 https://git.kernel.org/stable/c/0b105f4eb78e5ee39e5a74c47c9efd69b6ac849c https://git.kernel.org/stable/c/bdea4980182e3badac74f04df6c07492b91c569e