CVE-2026-143196: net/mlx5: HWS, fix flow meter release on FTE update

Published Dec 3, 2026
·
Updated

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

net/mlx5: HWS, fix flow meter release on FTE update

HWS has no duplicate match. When a flower filter is replaced in place, its new rule waits as the pending duplicate of the old FTE. Once the old rule goes, switchtopendingactdests() copies the pending actions over the FTE before updatefte() releases the actions of the old rule. An HWS rule reads the base id of its meter action through a pointer to the exeaso of the FTE. That release takes the meter action of the new rule instead.

When the two meters sit in different ASO objects, the old meter action leaks. It keeps its ASO object referenced. The firmware then fails to destroy that object and to free the PD of the meters, and its STC is still in the pool when the context closes. The new meter action is destroyed one release early, while a rule still points to it, and the last release underflows its refcount:

mlx5core 0000:b1:00.1: mlx5cmdouterr:822:(pid 2641): DESTROYGENERALOBJECT(0xa03) opmod(0x24) failed, status bad resource(0x5), syndrome (0xeeda5c), err(-22) refcountt: underflow; use-after-free. WARNING: lib/refcount.c:96 at refcountdecnotone+0x3f/0x60, CPU#43: tc/2641 Call Trace: <TASK> mlx5fsputhwsaction.part.0+0x1a/0xa0 [mlx5core] mlx5fsdestroyfsactions+0xa8/0x110 [mlx5core] mlx5cmdhwsdeletefte+0x49/0x90 [mlx5core] delhwfte+0x209/0x320 [mlx5core] mlx5delflowrules+0x10b/0x260 [mlx5core] mlx5eswitchdelrule+0x5c/0x1b0 [mlx5core] mlx5eswitchdeloffloadedrule+0x10/0x20 [mlx5core] mlx5etcruleunoffload+0x4b/0x100 [mlx5core] mlx5etcunoffloadfdbrules+0x35/0x80 [mlx5core] mlx5etcdelfdbflow+0x2ca/0x310 [mlx5core] mlx5etcdelflow+0x5d/0x2d0 [mlx5core] mlx5eflowput+0x3a/0x80 [mlx5core] mlx5edeleteflower+0x291/0x460 [mlx5core] mlx5esetuptcblockcb+0xc4/0x110 [mlx5core] tcsetupcbdestroy+0xcc/0x1b0 flhwdestroyfilter+0xa1/0xe0 [clsflower] fldelete+0x2d0/0x3d0 [clsflower] fldestroy+0xbd/0x160 [clsflower] tcfprotodestroy+0x3b/0x110 tcfprotoput+0x3d/0x70 tcdeltfilter+0x362/0x8f0 rtnetlinkrcvmsg+0x384/0x460 netlinkrcvskb+0x61/0x120 rtnetlinkrcv+0x15/0x30 netlinkunicast+0x2a1/0x3d0 netlinksendmsg+0x237/0x490 syssendmsg+0x33b/0x360 syssendmsg+0x99/0xf0 syssendmsg+0x93/0x100 x64syssendmsg+0x1d/0x30 x64syscall+0x821/0x23d0 dosyscall64+0xba/0x550 entrySYSCALL64afterhwframe+0x76/0x7e </TASK> mlx5core 0000:b1:00.1: mlx5cmdouterr:822:(pid 2642): DEALLOCPD(0x801) opmod(0x0) failed, status bad resource state(0x9), syndrome (0xef0c8a), err(-22) mlx5core 0000:b1:00.1: mlx5hwspooldestroy:386:(pid 2642): Attempting to destroy non-empty pool

Keep the base id in the rule action, as the sampler id is.

Discovered while stress testing a 5G UPF kernel code. Without this fix, the reproduction below gives the trace above on a ConnectX-7 with firmware 28.48.1000. It only uses tc and devlink, with no kernel change. 129 meters cannot fit in one ASO object. DEV is the uplink representor and PCI its devlink handle:

r() { echo "filter $1 dev $DEV ingress prio 1 handle $2 protocol ip flower skipsw dstip 10.0.0.$2 action police index $3 rate 1mbit burst 32k conform-exceed drop/pipe action drop"; } devlink dev param set $PCI name flowsteeringmode value hmfs cmode runtime devlink dev eswitch set $PCI mode switchdev tc qdisc add dev $DEV ingress for i in $(seq 129); do r add $i $i; done | tc -b - r replace 1 1000 | tc -b - tc filter del dev $DEV ingress prio 1 devlink dev eswitch set $PCI mode legacy

With this fix, the reproduction runs clean on the same ConnectX-7. It was not tested against kernel selftests.

Affected Software

3 affected componentsFixes available
Linux Linux kernel
linux/kernel>=6.15.0<6.18.66
6.18.66
linux/kernel>=6.19.0<7.3.7
7.3.7

Remediation

Recommended actions to resolve this vulnerability, in priority order.

  1. Upgrade

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

    Fixed in 6.18.66
  2. 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

What conditions are required to trigger this issue?

The issue occurs when an HWS flower filter is replaced in place and the old and new rules use meter actions located in different ASO objects. During the FTE update, the old rule's release can act on the new rule's meter action instead.

2

Which systems are realistically exposed?

Systems using the Linux kernel mlx5 HWS path with flower filters and flow-meter actions are exposed to this specific condition. The provided information does not establish whether a default configuration enables or uses these features.

3

How can I tell whether the problem has occurred?

Relevant signs include mlx5 firmware failures while destroying general objects, messages reporting a bad resource status during DESTROY_GENERAL_OBJECT operations, refcount underflow warnings, and use-after-free warnings. The failure can also leave ASO objects and meter PD resources referenced and leave an STC in the pool during context closure.

4

What remediation information is available?

The vulnerability is described as resolved, and the supplied references identify three stable kernel commits containing the fix. No affected or fixed kernel version ranges are provided.

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