# CVE-2026-43012: net/mlx5: Fix switchdev mode rollback in case of failure

> Archived entry. Full-text search covers entries since 2026-11-10; exact IDs work for all years.

- **Severity:** MEDIUM 5.5
- **CVSS:** 5.5 (v3.1, NVD) `CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H`
- **CVSS metrics:** Attack vector: Local; Attack complexity: Low; Privileges required: Low; User interaction: None; Scope: Unchanged; Confidentiality impact: None; Integrity impact: None; Availability impact: High
- **Exploited in the wild:** Not in CISA KEV
- **Public exploit / PoC:** None known
- **Remote exploitation:** Not remotely exploitable (local or adjacent access needed)
- **EPSS:** 0.16% (percentile 3, 2026-11-26)
- **Published:** 2026-05-01T14:15:18.256Z
- **Modified:** 2026-11-11T23:10:00.263Z

## Who should check

- Anyone running Linux \>= de85624c623dbb5fdb3ae7b08b66894a072c0cc0, \< 2ebb13f3e8be0b61f72425b34cce60c8b6ad1891; \>= 2a4f56fbcc473d8faeb29b73082df39efbe5893c, \< e27153b2bd6e6699b544ac4dfa35d167bed5e642; \>= 2a4f56fbcc473d8faeb29b73082df39efbe5893c, \< 4363698838b7ec6e8d85b179495889aa7e522f91; \>= 2a4f56fbcc473d8faeb29b73082df39efbe5893c, \< 403186400a1a6166efe7031edc549c15fee4723f; \>= 6.12.9, \< 6.12.81
- Anyone running Linux 6.13

## Description

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

net/mlx5: Fix switchdev mode rollback in case of failure

If for some internal reason switchdev mode fails, we rollback to legacy
mode, before this patch, rollback will unregister the uplink netdev and
leave it unregistered causing the below kernel bug.

To fix this, we need to avoid netdev unregister by setting the proper
rollback flag 'MLX5\_PRIV\_FLAGS\_SWITCH\_LEGACY' to indicate legacy mode.

devlink (431) used greatest stack depth: 11048 bytes left
mlx5\_core 0000:00:03.0: E-Switch: Disable: mode(LEGACY), nvfs(0), \\
	necvfs(0), active vports(0)
mlx5\_core 0000:00:03.0: E-Switch: Supported tc chains and prios offload
mlx5\_core 0000:00:03.0: Loading uplink representor for vport 65535
mlx5\_core 0000:00:03.0: mlx5\_cmd\_out\_err:816:(pid 456): \\
	QUERY\_HCA\_CAP(0x100) op\_mod(0x0) failed, \\
	status bad parameter(0x3), syndrome (0x3a3846), err(-22)
mlx5\_core 0000:00:03.0 enp0s3np0 (unregistered): Unloading uplink \\
	representor for vport 65535
 ------------\[ cut here \]------------
kernel BUG at net/core/dev.c:12070!
Oops: invalid opcode: 0000 \[\#1\] SMP NOPTI
CPU: 2 UID: 0 PID: 456 Comm: devlink Not tainted 6.16.0-rc3+ \\
	\#9 PREEMPT(voluntary)
RIP: 0010:unregister\_netdevice\_many\_notify+0x123/0xae0
...
Call Trace:
\[   90.923094\]  unregister\_netdevice\_queue+0xad/0xf0
\[   90.923323\]  unregister\_netdev+0x1c/0x40
\[   90.923522\]  mlx5e\_vport\_rep\_unload+0x61/0xc6
\[   90.923736\]  esw\_offloads\_enable+0x8e6/0x920
\[   90.923947\]  mlx5\_eswitch\_enable\_locked+0x349/0x430
\[   90.924182\]  ? is\_mp\_supported+0x57/0xb0
\[   90.924376\]  mlx5\_devlink\_eswitch\_mode\_set+0x167/0x350
\[   90.924628\]  devlink\_nl\_eswitch\_set\_doit+0x6f/0xf0
\[   90.924862\]  genl\_family\_rcv\_msg\_doit+0xe8/0x140
\[   90.925088\]  genl\_rcv\_msg+0x18b/0x290
\[   90.925269\]  ? \_\_pfx\_devlink\_nl\_pre\_doit+0x10/0x10
\[   90.925506\]  ? \_\_pfx\_devlink\_nl\_eswitch\_set\_doit+0x10/0x10
\[   90.925766\]  ? \_\_pfx\_devlink\_nl\_post\_doit+0x10/0x10
\[   90.926001\]  ? \_\_pfx\_genl\_rcv\_msg+0x10/0x10
\[   90.926206\]  netlink\_rcv\_skb+0x52/0x100
\[   90.926393\]  genl\_rcv+0x28/0x40
\[   90.926557\]  netlink\_unicast+0x27d/0x3d0
\[   90.926749\]  netlink\_sendmsg+0x1f7/0x430
\[   90.926942\]  \_\_sys\_sendto+0x213/0x220
\[   90.927127\]  ? \_\_sys\_recvmsg+0x6a/0xd0
\[   90.927312\]  \_\_x64\_sys\_sendto+0x24/0x30
\[   90.927504\]  do\_syscall\_64+0x50/0x1c0
\[   90.927687\]  entry\_SYSCALL\_64\_after\_hwframe+0x76/0x7e
\[   90.927929\] RIP: 0033:0x7f7d0363e047

## Affected and fixed versions

- Linux: \>= de85624c623dbb5fdb3ae7b08b66894a072c0cc0, \< 2ebb13f3e8be0b61f72425b34cce60c8b6ad1891; \>= 2a4f56fbcc473d8faeb29b73082df39efbe5893c, \< e27153b2bd6e6699b544ac4dfa35d167bed5e642; \>= 2a4f56fbcc473d8faeb29b73082df39efbe5893c, \< 4363698838b7ec6e8d85b179495889aa7e522f91; \>= 2a4f56fbcc473d8faeb29b73082df39efbe5893c, \< 403186400a1a6166efe7031edc549c15fee4723f; \>= 6.12.9, \< 6.12.81 (cvelist)
- Linux: 6.13 (cvelist)

## Mitigation

- Upgrade Linux to 6.12.81 or later.

## Check your systems with an agent

Paste this into a coding agent:

```text
Check whether anything I run is affected by CVE-2026-43012. Work read-only: do not install, upgrade, delete or change anything.

Details: https://flawdb.com/CVE-2026-43012.md
Affected: Linux >= de85624c623dbb5fdb3ae7b08b66894a072c0cc0, < 2ebb13f3e8be0b61f72425b34cce60c8b6ad1891; >= 2a4f56fbcc473d8faeb29b73082df39efbe5893c, < e27153b2bd6e6699b544ac4dfa35d167bed5e642; >= 2a4f56fbcc473d8faeb29b73082df39efbe5893c, < 4363698838b7ec6e8d85b179495889aa7e522f91; >= 2a4f56fbcc473d8faeb29b7…
Fixed in: Linux 2ebb13f3e8be0b61f72425b34cce60c8b6ad1891, Linux 4363698838b7ec6e8d85b179495889aa7e522f91, Linux 403186400a1a6166efe7031edc549c15fee4723f, Linux 6.12.81

Steps:
1. Search this machine and project for Linux: dependency manifests and lockfiles, installed packages, container images and running services.
2. For each match, note the installed version and whether it is inside the affected range.
3. Report a table: location, installed version, affected (yes / no / unsure), evidence. If affected, say which fixed version or mitigation from the details link applies, but don't apply it.
```

## FAQ

### Is CVE-2026-43012 being exploited?

There is no confirmed exploitation: CVE-2026-43012 is not in the CISA Known Exploited Vulnerabilities catalog. No public exploit code is known. EPSS estimates a 0.16% chance of exploitation in the next 30 days (as of 2026-11-26).

### How serious is CVE-2026-43012?

Medium: CVSS 5.5 (v3.1, scored by NVD). Not remotely exploitable (local or adjacent access needed).

### Which versions are affected by CVE-2026-43012?

Linux \>= de85624c623dbb5fdb3ae7b08b66894a072c0cc0, \< 2ebb13f3e8be0b61f72425b34cce60c8b6ad1891; \>= 2a4f56fbcc473d8faeb29b73082df39efbe5893c, \< e27153b2bd6e6699b544ac4dfa35d167bed5e642; \>= 2a4f56fbcc473d8faeb29b73082df39efbe5893c, \< 4363698838b7ec6e8d85b179495889aa7e522f91; \>= 2a4f56fbcc473d8faeb29b73082df39efbe5893c, \< 403186400a1a6166efe7031edc549c15fee4723f; \>= 6.12.9, \< 6.12.81; Linux 6.13.

### Is there a fix for CVE-2026-43012?

Yes. Fixed in Linux 2ebb13f3e8be0b61f72425b34cce60c8b6ad1891, Linux 4363698838b7ec6e8d85b179495889aa7e522f91, Linux 403186400a1a6166efe7031edc549c15fee4723f, Linux 6.12.81. Upgrade Linux to 6.12.81 or later.

### How do I check if I'm affected by CVE-2026-43012?

Find where you use the affected software (dependency lockfiles, installed packages, container images, servers) and compare the installed version with the affected range above. The agent prompt on this page does this read-only.

## References

- patch: <https://git.kernel.org/stable/c/2ebb13f3e8be0b61f72425b34cce60c8b6ad1891>
- patch: <https://git.kernel.org/stable/c/e27153b2bd6e6699b544ac4dfa35d167bed5e642>
- patch: <https://git.kernel.org/stable/c/4363698838b7ec6e8d85b179495889aa7e522f91>
- patch: <https://git.kernel.org/stable/c/403186400a1a6166efe7031edc549c15fee4723f>

## Attribution

- CVE Program: CVE® is a registered trademark of The MITRE Corporation. CVE records © 1999–2026 The MITRE Corporation. <https://www.cve.org/Legal/TermsOfUse>
- NVD: This product uses data from the NVD API but is not endorsed or certified by the NVD. <https://nvd.nist.gov/vuln/detail/CVE-2026-43012>

HTML: <https://flawdb.com/CVE-2026-43012> · JSON: <https://flawdb.com/api/v1/entries/CVE-2026-43012>
