CVE-2026-72341
net/mlx5e: Fix publication race for priv->channel_stats[]
Description
In the Linux kernel, the following vulnerability has been resolved: net/mlx5e: Fix publication race for priv->channel_stats[] mlx5e_channel_stats_alloc() publishes a new entry to priv->channel_stats[] and then increments priv->stats_nch as a publication token, but neither store carries any memory barrier: priv->channel_stats[ix] = kvzalloc_node(...); if (!priv->channel_stats[ix]) return -ENOMEM; priv->stats_nch++; Concurrent readers compute the loop bound from priv->stats_nch and then dereference priv->channel_stats[i] using plain accesses, e.g. for (i = 0; i < priv->stats_nch; i++) { struct mlx5e_channel_stats *cs = priv->channel_stats[i]; ... cs->rq.packets ... } On weakly-ordered architectures (ARM, PowerPC, RISC-V) the writes to channel_stats[ix] and stats_nch may become visible to other CPUs out of program order. A reader can observe stats_nch == N while still seeing channel_stats[N-1] == NULL, leading to a NULL pointer dereference in the channel_stats loop. This has been observed in production on BlueField-3 DPUs (arm64), where ovs-vswitchd queries netdev statistics over netlink during NIC bringup, racing mlx5e_open_channel() -> mlx5e_channel_stats_alloc() on another CPU: Unable to handle kernel NULL pointer dereference at virtual address 0x840 Hardware name: BlueField-3 DPU pc : mlx5e_fold_sw_stats64+0x30/0x180 [mlx5_core] Call trace: mlx5e_fold_sw_stats64+0x30/0x180 [mlx5_core] dev_get_stats+0x50/0xc0 ovs_vport_get_stats+0x38/0xac [openvswitch] ovs_vport_cmd_fill_info+0x194/0x290 [openvswitch] ovs_vport_cmd_get+0xbc/0x10c [openvswitch] genl_family_rcv_msg_doit+0xd0/0x160 genl_rcv_msg+0xec/0x1f0 netlink_rcv_skb+0x64/0x130 genl_rcv+0x40/0x60 netlink_unicast+0x2fc/0x370 netlink_sendmsg+0x1dc/0x454 ... __arm64_sys_sendmsg+0x2c/0x40 Add mlx5e_stats_nch_write() and mlx5e_stats_nch_read() helpers in en.h that wrap the smp_store_release()/smp_load_acquire() pair on stats_nch. The release/acquire pair establishes the contract: stats_nch == N => channel_stats[0..N-1] are visible and non-NULL. Publish the stats_nch increment via mlx5e_stats_nch_write() in the writer (mlx5e_channel_stats_alloc()), and read stats_nch via mlx5e_stats_nch_read() in all readers: mlx5e RX/TX queue stats, mlx5e_get_base_stats(), ethtool channels stats, IPoIB stats, the sw_stats fold and the HV VHCA stats agent.
INFO
Published Date :
Aug. 15, 2026, 6:22 a.m.
Last Modified :
Aug. 17, 2026, 6:18 a.m.
Remotely Exploit :
No
Source :
416baaa9-dc9f-4396-8d5f-8c081fb06d67
Solution
- Use smp_store_release for writing stats_nch.
- Use smp_load_acquire for reading stats_nch.
- Update affected statistics reading functions.
- Apply the provided kernel patch.
References to Advisories, Solutions, and Tools
Here, you will find a curated list of external links that provide in-depth
information, practical solutions, and valuable tools related to
CVE-2026-72341.
CWE - Common Weakness Enumeration
While CVE identifies
specific instances of vulnerabilities, CWE categorizes the common flaws or
weaknesses that can lead to vulnerabilities. CVE-2026-72341 is
associated with the following CWEs:
Common Attack Pattern Enumeration and Classification (CAPEC)
Common Attack Pattern Enumeration and Classification
(CAPEC)
stores attack patterns, which are descriptions of the common attributes and
approaches employed by adversaries to exploit the CVE-2026-72341
weaknesses.
We scan GitHub repositories to detect new proof-of-concept exploits. Following list is a collection of public exploits and proof-of-concepts, which have been published on GitHub (sorted by the most recently updated).
Results are limited to the first 15 repositories due to potential performance issues.
The following list is the news that have been mention
CVE-2026-72341 vulnerability anywhere in the article.
The following table lists the changes that have been made to the
CVE-2026-72341 vulnerability over time.
Vulnerability history details can be useful for understanding the evolution of a vulnerability, and for identifying the most recent changes that may impact the vulnerability's severity, exploitability, or other characteristics.
-
CVE Modified by 416baaa9-dc9f-4396-8d5f-8c081fb06d67
Aug. 17, 2026
Action Type Old Value New Value Changed Affected [{'repo': 'https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git', 'vendor': 'Linux', 'product': 'Linux', 'versions': [{'status': 'affected', 'version': 'fa691d0c9c0812b9045f3a9420862e47b3b92518', 'lessThan': '5c7e3755abf663f033de24f917b77685e9543045', 'versionType': 'git'}, {'status': 'affected', 'version': 'fa691d0c9c0812b9045f3a9420862e47b3b92518', 'lessThan': '815515ec68f527ca755cb1e2c1ff9148f6b3ea56', 'versionType': 'git'}, {'status': 'affected', 'version': 'fa691d0c9c0812b9045f3a9420862e47b3b92518', 'lessThan': '5a799714e8ca0bce9ea40694f49914cf1adbbaa9', 'versionType': 'git'}], 'programFiles': ['drivers/net/ethernet/mellanox/mlx5/core/en.h', 'drivers/net/ethernet/mellanox/mlx5/core/en/hv_vhca_stats.c', 'drivers/net/ethernet/mellanox/mlx5/core/en_main.c', 'drivers/net/ethernet/mellanox/mlx5/core/en_stats.c', 'drivers/net/ethernet/mellanox/mlx5/core/ipoib/ipoib.c'], 'defaultStatus': 'unaffected'}, {'repo': 'https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git', 'vendor': 'Linux', 'product': 'Linux', 'versions': [{'status': 'affected', 'version': '5.17'}, {'status': 'unaffected', 'version': '0', 'lessThan': '5.17', 'versionType': 'semver'}, {'status': 'unaffected', 'version': '6.18.40', 'versionType': 'semver', 'lessThanOrEqual': '6.18.*'}, {'status': 'unaffected', 'version': '7.1.5', 'versionType': 'semver', 'lessThanOrEqual': '7.1.*'}, {'status': 'unaffected', 'version': '7.2-rc3', 'versionType': 'original_commit_for_fix', 'lessThanOrEqual': '*'}], 'programFiles': ['drivers/net/ethernet/mellanox/mlx5/core/en.h', 'drivers/net/ethernet/mellanox/mlx5/core/en/hv_vhca_stats.c', 'drivers/net/ethernet/mellanox/mlx5/core/en_main.c', 'drivers/net/ethernet/mellanox/mlx5/core/en_stats.c', 'drivers/net/ethernet/mellanox/mlx5/core/ipoib/ipoib.c'], 'defaultStatus': 'affected'}] [{'repo': 'https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git', 'vendor': 'Linux', 'product': 'Linux', 'versions': [{'status': 'affected', 'version': 'fa691d0c9c0812b9045f3a9420862e47b3b92518', 'lessThan': '5c7e3755abf663f033de24f917b77685e9543045', 'versionType': 'git'}, {'status': 'affected', 'version': 'fa691d0c9c0812b9045f3a9420862e47b3b92518', 'lessThan': '815515ec68f527ca755cb1e2c1ff9148f6b3ea56', 'versionType': 'git'}, {'status': 'affected', 'version': 'fa691d0c9c0812b9045f3a9420862e47b3b92518', 'lessThan': '5a799714e8ca0bce9ea40694f49914cf1adbbaa9', 'versionType': 'git'}], 'programFiles': ['drivers/net/ethernet/mellanox/mlx5/core/en.h', 'drivers/net/ethernet/mellanox/mlx5/core/en/hv_vhca_stats.c', 'drivers/net/ethernet/mellanox/mlx5/core/en_main.c', 'drivers/net/ethernet/mellanox/mlx5/core/en_stats.c', 'drivers/net/ethernet/mellanox/mlx5/core/ipoib/ipoib.c'], 'defaultStatus': 'unaffected'}, {'repo': 'https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git', 'vendor': 'Linux', 'product': 'Linux', 'versions': [{'status': 'affected', 'version': '5.17'}, {'status': 'unaffected', 'version': '0', 'lessThan': '5.17', 'versionType': 'semver'}, {'status': 'unaffected', 'version': '6.18.40', 'versionType': 'semver', 'lessThanOrEqual': '6.18.*'}, {'status': 'unaffected', 'version': '7.1.5', 'versionType': 'semver', 'lessThanOrEqual': '7.1.*'}, {'status': 'unaffected', 'version': '7.2', 'versionType': 'original_commit_for_fix', 'lessThanOrEqual': '*'}], 'programFiles': ['drivers/net/ethernet/mellanox/mlx5/core/en.h', 'drivers/net/ethernet/mellanox/mlx5/core/en/hv_vhca_stats.c', 'drivers/net/ethernet/mellanox/mlx5/core/en_main.c', 'drivers/net/ethernet/mellanox/mlx5/core/en_stats.c', 'drivers/net/ethernet/mellanox/mlx5/core/ipoib/ipoib.c'], 'defaultStatus': 'affected'}] -
New CVE Received by 416baaa9-dc9f-4396-8d5f-8c081fb06d67
Aug. 15, 2026
Action Type Old Value New Value Added Affected [{'repo': 'https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git', 'vendor': 'Linux', 'product': 'Linux', 'versions': [{'status': 'affected', 'version': 'fa691d0c9c0812b9045f3a9420862e47b3b92518', 'lessThan': '5c7e3755abf663f033de24f917b77685e9543045', 'versionType': 'git'}, {'status': 'affected', 'version': 'fa691d0c9c0812b9045f3a9420862e47b3b92518', 'lessThan': '815515ec68f527ca755cb1e2c1ff9148f6b3ea56', 'versionType': 'git'}, {'status': 'affected', 'version': 'fa691d0c9c0812b9045f3a9420862e47b3b92518', 'lessThan': '5a799714e8ca0bce9ea40694f49914cf1adbbaa9', 'versionType': 'git'}], 'programFiles': ['drivers/net/ethernet/mellanox/mlx5/core/en.h', 'drivers/net/ethernet/mellanox/mlx5/core/en/hv_vhca_stats.c', 'drivers/net/ethernet/mellanox/mlx5/core/en_main.c', 'drivers/net/ethernet/mellanox/mlx5/core/en_stats.c', 'drivers/net/ethernet/mellanox/mlx5/core/ipoib/ipoib.c'], 'defaultStatus': 'unaffected'}, {'repo': 'https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git', 'vendor': 'Linux', 'product': 'Linux', 'versions': [{'status': 'affected', 'version': '5.17'}, {'status': 'unaffected', 'version': '0', 'lessThan': '5.17', 'versionType': 'semver'}, {'status': 'unaffected', 'version': '6.18.40', 'versionType': 'semver', 'lessThanOrEqual': '6.18.*'}, {'status': 'unaffected', 'version': '7.1.5', 'versionType': 'semver', 'lessThanOrEqual': '7.1.*'}, {'status': 'unaffected', 'version': '7.2-rc3', 'versionType': 'original_commit_for_fix', 'lessThanOrEqual': '*'}], 'programFiles': ['drivers/net/ethernet/mellanox/mlx5/core/en.h', 'drivers/net/ethernet/mellanox/mlx5/core/en/hv_vhca_stats.c', 'drivers/net/ethernet/mellanox/mlx5/core/en_main.c', 'drivers/net/ethernet/mellanox/mlx5/core/en_stats.c', 'drivers/net/ethernet/mellanox/mlx5/core/ipoib/ipoib.c'], 'defaultStatus': 'affected'}] Added Description In the Linux kernel, the following vulnerability has been resolved: net/mlx5e: Fix publication race for priv->channel_stats[] mlx5e_channel_stats_alloc() publishes a new entry to priv->channel_stats[] and then increments priv->stats_nch as a publication token, but neither store carries any memory barrier: priv->channel_stats[ix] = kvzalloc_node(...); if (!priv->channel_stats[ix]) return -ENOMEM; priv->stats_nch++; Concurrent readers compute the loop bound from priv->stats_nch and then dereference priv->channel_stats[i] using plain accesses, e.g. for (i = 0; i < priv->stats_nch; i++) { struct mlx5e_channel_stats *cs = priv->channel_stats[i]; ... cs->rq.packets ... } On weakly-ordered architectures (ARM, PowerPC, RISC-V) the writes to channel_stats[ix] and stats_nch may become visible to other CPUs out of program order. A reader can observe stats_nch == N while still seeing channel_stats[N-1] == NULL, leading to a NULL pointer dereference in the channel_stats loop. This has been observed in production on BlueField-3 DPUs (arm64), where ovs-vswitchd queries netdev statistics over netlink during NIC bringup, racing mlx5e_open_channel() -> mlx5e_channel_stats_alloc() on another CPU: Unable to handle kernel NULL pointer dereference at virtual address 0x840 Hardware name: BlueField-3 DPU pc : mlx5e_fold_sw_stats64+0x30/0x180 [mlx5_core] Call trace: mlx5e_fold_sw_stats64+0x30/0x180 [mlx5_core] dev_get_stats+0x50/0xc0 ovs_vport_get_stats+0x38/0xac [openvswitch] ovs_vport_cmd_fill_info+0x194/0x290 [openvswitch] ovs_vport_cmd_get+0xbc/0x10c [openvswitch] genl_family_rcv_msg_doit+0xd0/0x160 genl_rcv_msg+0xec/0x1f0 netlink_rcv_skb+0x64/0x130 genl_rcv+0x40/0x60 netlink_unicast+0x2fc/0x370 netlink_sendmsg+0x1dc/0x454 ... __arm64_sys_sendmsg+0x2c/0x40 Add mlx5e_stats_nch_write() and mlx5e_stats_nch_read() helpers in en.h that wrap the smp_store_release()/smp_load_acquire() pair on stats_nch. The release/acquire pair establishes the contract: stats_nch == N => channel_stats[0..N-1] are visible and non-NULL. Publish the stats_nch increment via mlx5e_stats_nch_write() in the writer (mlx5e_channel_stats_alloc()), and read stats_nch via mlx5e_stats_nch_read() in all readers: mlx5e RX/TX queue stats, mlx5e_get_base_stats(), ethtool channels stats, IPoIB stats, the sw_stats fold and the HV VHCA stats agent. Added Reference https://git.kernel.org/stable/c/5a799714e8ca0bce9ea40694f49914cf1adbbaa9 Added Reference https://git.kernel.org/stable/c/5c7e3755abf663f033de24f917b77685e9543045 Added Reference https://git.kernel.org/stable/c/815515ec68f527ca755cb1e2c1ff9148f6b3ea56