Skip to contentSkip to conversation

CVE-2026-98498: net/mlx5: Fix rev_entry reference leak in mlx5_tc_ct_shared_counter_get()

DISCUSSION Greg Kroah-Hartman 1 participant 1 message Oct 18

lore
Share & tools
lore
#0 lore raw

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

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

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

net/mlx5: Fix rev_entry reference leak in mlx5_tc_ct_shared_counter_get()

When the reverse entry is found but its counter is already being released, refcount_inc_not_zero() fails and the reference taken by mlx5_tc_ct_entry_get() is never dropped before falling through to create_counter. Drop it so the reverse entry is not kept alive forever by a shared counter lookup that did not use it.

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

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

	Issue introduced in 5.10 with commit 1edae2335adfa7006853e8b427f0c7c3f46b51dd and fixed in 5.10.271 with commit 598daa5f95883f881a54967da40ce0fdfc1fdaa8
	Issue introduced in 5.10 with commit 1edae2335adfa7006853e8b427f0c7c3f46b51dd and fixed in 5.15.222 with commit 79a3257280a335bbebbcd10d3895e8468bdcd6ae
	Issue introduced in 5.10 with commit 1edae2335adfa7006853e8b427f0c7c3f46b51dd and fixed in 6.1.189 with commit c45c997d0c27359b502587897f775c5a277f0bd4
	Issue introduced in 5.10 with commit 1edae2335adfa7006853e8b427f0c7c3f46b51dd and fixed in 6.6.158 with commit 288721013605b4e0304e10f6a087b77f71cfad11
	Issue introduced in 5.10 with commit 1edae2335adfa7006853e8b427f0c7c3f46b51dd and fixed in 6.12.112 with commit 60eab87d0a798070bf5a856b1d9e5785ce92da53
	Issue introduced in 5.10 with commit 1edae2335adfa7006853e8b427f0c7c3f46b51dd and fixed in 6.18.55 with commit 99d8dc51663747078c031acac32edc6d90c8f1f7
	Issue introduced in 5.10 with commit 1edae2335adfa7006853e8b427f0c7c3f46b51dd and fixed in 7.2.9 with commit 1f13989a0704bd98cab09f9bee63e2c8a98ad4dd
	Issue introduced in 5.10 with commit 1edae2335adfa7006853e8b427f0c7c3f46b51dd and fixed in 7.3-rc5 with commit 0bf6bb567f0edaa771e7dd208ef98da50e6a4485

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

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/mellanox/mlx5/core/en/tc_ct.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/598daa5f95883f881a54967da40ce0fdfc1fdaa8
	https://git.kernel.org/stable/c/79a3257280a335bbebbcd10d3895e8468bdcd6ae
	https://git.kernel.org/stable/c/c45c997d0c27359b502587897f775c5a277f0bd4
	https://git.kernel.org/stable/c/288721013605b4e0304e10f6a087b77f71cfad11
	https://git.kernel.org/stable/c/60eab87d0a798070bf5a856b1d9e5785ce92da53
	https://git.kernel.org/stable/c/99d8dc51663747078c031acac32edc6d90c8f1f7
	https://git.kernel.org/stable/c/1f13989a0704bd98cab09f9bee63e2c8a98ad4dd
	https://git.kernel.org/stable/c/0bf6bb567f0edaa771e7dd208ef98da50e6a4485