# CVE-2021-46931: net/mlx5e: Wrap the tx reporter dump callback to extract the sq

> 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.24% (percentile 9, 2026-11-28)
- **CWE:** CWE-787
- **Published:** 2024-02-27T09:43:59.373Z
- **Modified:** 2026-06-17T04:15:53.467Z

## Who should check

- Anyone running Linux \>= 5f29458b77d51c104554575b73184c243930aa87, \< 73665165b64a8f3c5b3534009a69be55bb744f05; \>= 5f29458b77d51c104554575b73184c243930aa87, \< 07f13d58a8ecc3baf9a488588fb38c5cb0db484f; \>= 5f29458b77d51c104554575b73184c243930aa87, \< 918fc3855a6507a200e9cf22c20be852c0982687
- Anyone running Linux 5.7

## Description

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

net/mlx5e: Wrap the tx reporter dump callback to extract the sq

Function mlx5e\_tx\_reporter\_dump\_sq() casts its void \* argument to struct
mlx5e\_txqsq \*, but in TX-timeout-recovery flow the argument is actually
of type struct mlx5e\_tx\_timeout\_ctx \*.

 mlx5\_core 0000:08:00.1 enp8s0f1: TX timeout detected
 mlx5\_core 0000:08:00.1 enp8s0f1: TX timeout on queue: 1, SQ: 0x11ec, CQ: 0x146d, SQ Cons: 0x0 SQ Prod: 0x1, usecs since last trans: 21565000
 BUG: stack guard page was hit at 0000000093f1a2de (stack is 00000000b66ea0dc..000000004d932dae)
 kernel stack overflow (page fault): 0000 \[\#1\] SMP NOPTI
 CPU: 5 PID: 95 Comm: kworker/u20:1 Tainted: G W OE 5.13.0\_mlnx \#1
 Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS rel-1.13.0-0-gf21b5a4aeb02-prebuilt.qemu.org 04/01/2014
 Workqueue: mlx5e mlx5e\_tx\_timeout\_work \[mlx5\_core\]
 RIP: 0010:mlx5e\_tx\_reporter\_dump\_sq+0xd3/0x180
 \[mlx5\_core\]
 Call Trace:
 mlx5e\_tx\_reporter\_dump+0x43/0x1c0 \[mlx5\_core\]
 devlink\_health\_do\_dump.part.91+0x71/0xd0
 devlink\_health\_report+0x157/0x1b0
 mlx5e\_reporter\_tx\_timeout+0xb9/0xf0 \[mlx5\_core\]
 ? mlx5e\_tx\_reporter\_err\_cqe\_recover+0x1d0/0x1d0
 \[mlx5\_core\]
 ? mlx5e\_health\_queue\_dump+0xd0/0xd0 \[mlx5\_core\]
 ? update\_load\_avg+0x19b/0x550
 ? set\_next\_entity+0x72/0x80
 ? pick\_next\_task\_fair+0x227/0x340
 ? finish\_task\_switch+0xa2/0x280
   mlx5e\_tx\_timeout\_work+0x83/0xb0 \[mlx5\_core\]
   process\_one\_work+0x1de/0x3a0
   worker\_thread+0x2d/0x3c0
 ? process\_one\_work+0x3a0/0x3a0
   kthread+0x115/0x130
 ? kthread\_park+0x90/0x90
   ret\_from\_fork+0x1f/0x30
 --\[ end trace 51ccabea504edaff \]---
 RIP: 0010:mlx5e\_tx\_reporter\_dump\_sq+0xd3/0x180
 PKRU: 55555554
 Kernel panic - not syncing: Fatal exception
 Kernel Offset: disabled
 end Kernel panic - not syncing: Fatal exception

To fix this bug add a wrapper for mlx5e\_tx\_reporter\_dump\_sq() which
extracts the sq from struct mlx5e\_tx\_timeout\_ctx and set it as the
TX-timeout-recovery flow dump callback.

## Affected and fixed versions

- Linux: \>= 5f29458b77d51c104554575b73184c243930aa87, \< 73665165b64a8f3c5b3534009a69be55bb744f05; \>= 5f29458b77d51c104554575b73184c243930aa87, \< 07f13d58a8ecc3baf9a488588fb38c5cb0db484f; \>= 5f29458b77d51c104554575b73184c243930aa87, \< 918fc3855a6507a200e9cf22c20be852c0982687 (cvelist)
- Linux: 5.7 (cvelist)

## Mitigation

- Upgrade Linux to 918fc3855a6507a200e9cf22c20be852c0982687 or later.

## Check your systems with an agent

Paste this into a coding agent:

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

Details: https://flawdb.com/CVE-2021-46931.md
Affected: Linux >= 5f29458b77d51c104554575b73184c243930aa87, < 73665165b64a8f3c5b3534009a69be55bb744f05; >= 5f29458b77d51c104554575b73184c243930aa87, < 07f13d58a8ecc3baf9a488588fb38c5cb0db484f; >= 5f29458b77d51c104554575b73184c243930aa87, < 918fc3855a6507a200e9cf22c20be852c0982687; Linux 5.7
Fixed in: Linux 73665165b64a8f3c5b3534009a69be55bb744f05, Linux 07f13d58a8ecc3baf9a488588fb38c5cb0db484f, Linux 918fc3855a6507a200e9cf22c20be852c0982687

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-2021-46931 being exploited?

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

### How serious is CVE-2021-46931?

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

### Which versions are affected by CVE-2021-46931?

Linux \>= 5f29458b77d51c104554575b73184c243930aa87, \< 73665165b64a8f3c5b3534009a69be55bb744f05; \>= 5f29458b77d51c104554575b73184c243930aa87, \< 07f13d58a8ecc3baf9a488588fb38c5cb0db484f; \>= 5f29458b77d51c104554575b73184c243930aa87, \< 918fc3855a6507a200e9cf22c20be852c0982687; Linux 5.7.

### Is there a fix for CVE-2021-46931?

Yes. Fixed in Linux 73665165b64a8f3c5b3534009a69be55bb744f05, Linux 07f13d58a8ecc3baf9a488588fb38c5cb0db484f, Linux 918fc3855a6507a200e9cf22c20be852c0982687. Upgrade Linux to 918fc3855a6507a200e9cf22c20be852c0982687 or later.

### How do I check if I'm affected by CVE-2021-46931?

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/73665165b64a8f3c5b3534009a69be55bb744f05>
- patch: <https://git.kernel.org/stable/c/07f13d58a8ecc3baf9a488588fb38c5cb0db484f>
- patch: <https://git.kernel.org/stable/c/918fc3855a6507a200e9cf22c20be852c0982687>

## 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-2021-46931>

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