CVE-2026-143209: net/mlx5e: Fix E-Switch races in uplink unbind

Published Dec 3, 2026
·
Updated

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

net/mlx5e: Fix E-Switch races in uplink unbind

Unbinding the uplink Ethernet auxiliary driver in switchdev mode with offloaded IPsec policies deadlocks on the esw->modelock semaphore: mlx5eswitchsafeauxdevsremove() mlx5eswhold() downreadtrylock(&esw->modelock) () mlx5corerepsauxdevsremove() ... mlx5evportuplinkrepunload() unregisternetdev() xfrmdevunregister() xfrmdevpolicyflush() xfrmpolicykill() xfrmdevpolicydelete() mlx5exfrmdelpolicy() mlx5eaccelipsecfsdelpol() rxftputpolicy() rxput() mlx5eswitchunblockmode() downwrite(&esw->modelock) (BOOM)

Another deadlock with IPsec states: mlx5eswitchsafeauxdevsremove() mlx5eswhold() downreadtrylock(&esw->modelock) () mlx5corerepsauxdevsremove() ... mlx5evportuplinkrepunload() unregisternetdev() xfrmdevunregister() xfrmdevstateflush() xfrmdevstatefree() mlx5exfrmfreestate() mlx5eaccelipsecfsdelrule() rxftput() rxput() rxdestroy() mlx5eswitchunblockencap() downwrite(&esw->modelock) (BOOM)

To fix these, first refactor initiators of eswitch operations so they no longer step on each other's toes.

The active/inactive toggle and setting the inline/encap mode now use the new mlx5eswlockwait(), which waits for an operation in progress to finish. They all hold devllock, so the only operation they can find in progress is an uplink unbind, which doesn't need devllock. Setting the esw mode keeps using mlx5eswtrylock(), which also rejects the change while eswitch users exist and bails out with -EBUSY.

mlx5eswitchsafeauxdevsremove() now also waits for an operation in progress with the same mlx5eswlockwait() before initiating one, dropping modelock and then removing representors. The deadlocks are avoided.

Finishing an operation in progress now requires mlx5eswunlock() to wake up any waiters instead of plain upwrite(&modelock).

As a side effect, the timeout in mlx5eswitchsafeauxdevsremove() is gone, which fixes another scary corner case, of representor devs not being removed on timeout but leaked instead. The timeout hid the SD deadlock fixed in the previous patch. Now that that's gone, no reason for the timeout to stay.

This was found by internal testing and reproduced on HW. It was independently found by Sashiko during analysis of another patch in this series.

Affected Software

4 affected componentsFixes available
Linux Linux kernel
linux/kernel>=6.19.0<7.3.7
7.3.7
debian/linux*
debian/linux<=7.3.6-1

Remediation

Recommended actions to resolve this vulnerability, in priority order.

  1. Upgrade

    Upgrade linux/Kernel to a version that resolves this vulnerability.

    Fixed in 7.3.7

Event History

Dec 3, 2026
CVE Published
via MITRE·09:20 AM
Data Sourced
via MITRE·09:20 AM
Description
Data Sourced
via OSV·09:20 AM
DescriptionAffected Software
Data Sourced
via NVD·10:17 AM
Description

Frequently Asked Questions

1

Which systems should be prioritized for remediation?

Prioritize Linux systems using the mlx5e Ethernet driver in switchdev mode where the uplink Ethernet auxiliary driver may be unbound while IPsec policies or IPsec states are offloaded.

2

What operational condition triggers the failure?

The deadlock occurs during uplink auxiliary-driver removal or unbinding. Cleanup of offloaded IPsec policies or states can attempt to take the E-Switch mode lock for writing while the removal path holds it for reading.

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203