diff options
author | Gal Pressman <gal@nvidia.com> | 2024-12-02 19:48:05 +0300 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2025-02-08 11:58:18 +0300 |
commit | 1cf21779596859e6bbb291a7d97fbb079f2b8ab1 (patch) | |
tree | 00488ea6c2382107f59913c7cf5169e4b96576fb /scripts/generate_rust_analyzer.py | |
parent | 364d7e7f3097318e5d00affee9ce53fc4b0639bc (diff) | |
download | linux-1cf21779596859e6bbb291a7d97fbb079f2b8ab1.tar.xz |
ethtool: Fix access to uninitialized fields in set RXNFC command
commit 94071909477677fc2a1abf3fb281f203f66cf3ca upstream.
The check for non-zero ring with RSS is only relevant for
ETHTOOL_SRXCLSRLINS command, in other cases the check tries to access
memory which was not initialized by the userspace tool. Only perform the
check in case of ETHTOOL_SRXCLSRLINS.
Without this patch, filter deletion (for example) could statistically
result in a false error:
# ethtool --config-ntuple eth3 delete 484
rmgr: Cannot delete RX class rule: Invalid argument
Cannot delete classification rule
Fixes: 9e43ad7a1ede ("net: ethtool: only allow set_rxnfc with rss + ring_cookie if driver opts in")
Link: https://lore.kernel.org/netdev/871a9ecf-1e14-40dd-bbd7-e90c92f89d47@nvidia.com/
Reviewed-by: Dragos Tatulea <dtatulea@nvidia.com>
Reviewed-by: Tariq Toukan <tariqt@nvidia.com>
Signed-off-by: Gal Pressman <gal@nvidia.com>
Reviewed-by: Edward Cree <ecree.xilinx@gmail.com>
Link: https://patch.msgid.link/20241202164805.1637093-1-gal@nvidia.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'scripts/generate_rust_analyzer.py')
0 files changed, 0 insertions, 0 deletions