Skip to contentSkip to conversation

CVE-2026-43219: net: cpsw_new: Fix potential unregister of netdev that has not been registered yet

DISCUSSION Greg Kroah-Hartman 1 participant 1 message May 6

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: cpsw_new: Fix potential unregister of netdev that has not been registered yet

If an error occurs during register_netdev() for the first MAC in cpsw_register_ports(), even though cpsw->slaves[0].ndev is set to NULL, cpsw->slaves[1].ndev would remain unchanged. This could later cause cpsw_unregister_ports() to attempt unregistering the second MAC. To address this, add a check for ndev->reg_state before calling unregister_netdev(). With this change, setting cpsw->slaves[i].ndev to NULL becomes unnecessary and can be removed accordingly.

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

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

	Issue introduced in 5.5 with commit ed3525eda4c4983fb8509e488de0a351788041ba and fixed in 6.18.16 with commit 29739ec197ed66535bc0b86f14ab66c5f4512138
	Issue introduced in 5.5 with commit ed3525eda4c4983fb8509e488de0a351788041ba and fixed in 6.19.6 with commit 349c4cac6f54a81fc107589771f88136a2b20415
	Issue introduced in 5.5 with commit ed3525eda4c4983fb8509e488de0a351788041ba and fixed in 7.0 with commit 9d724b34fbe13b71865ad0906a4be97571f19cf5

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

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/ti/cpsw_new.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/29739ec197ed66535bc0b86f14ab66c5f4512138
	https://git.kernel.org/stable/c/349c4cac6f54a81fc107589771f88136a2b20415
	https://git.kernel.org/stable/c/9d724b34fbe13b71865ad0906a4be97571f19cf5