CVE-2026-23389: ice: Fix memory leak in ice_set_ringparam()
From: Greg Kroah-Hartman <[email protected]>
Description
===========
In the Linux kernel, the following vulnerability has been resolved:
ice: Fix memory leak in ice_set_ringparam()
In ice_set_ringparam, tx_rings and xdp_rings are allocated before rx_rings. If the allocation of rx_rings fails, the code jumps to the done label leaking both tx_rings and xdp_rings. Furthermore, if the setup of an individual Rx ring fails during the loop, the code jumps to the free_tx label which releases tx_rings but leaks xdp_rings.
Fix this by introducing a free_xdp label and updating the error paths to ensure both xdp_rings and tx_rings are properly freed if rx_rings allocation or setup fails.
Compile tested only. Issue found using a prototype static analysis tool and code review.
The Linux kernel CVE team has assigned CVE-2026-23389 to this issue.
Affected and fixed versions
===========================
Issue introduced in 4.17 with commit fcea6f3da546b93050f3534aadea7bd96c1d7349 and fixed in 6.19.7 with commit 44ba32a892b72de3faa04b8cfb1f2f1418fdd580 Issue introduced in 4.17 with commit fcea6f3da546b93050f3534aadea7bd96c1d7349 and fixed in 7.0-rc3 with commit fe868b499d16f55bbeea89992edb98043c9de416
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-23389
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/net/ethernet/intel/ice/ice_ethtool.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/44ba32a892b72de3faa04b8cfb1f2f1418fdd580 https://git.kernel.org/stable/c/fe868b499d16f55bbeea89992edb98043c9de416