Thread (14 messages) flat view 14 messages, 5 authors, 3d ago

Re: [PATCH net 5/5] ethtool: document that GRXCLSRLALL rule_cnt is a caller-provided limit

From: Joe Damato <hidden>
Date: 2026-09-03 20:16:46

On Wed, Sep 02, 2026 at 08:26:11PM -0700, Jakub Kicinski wrote:
Three drivers have shipped a get_rxnfc() which dumps its entire rule
table into rule_locs, reading rule_cnt as "how many rules do I have"
rather than "how many entries did the caller allocate".  Nothing in the
callback's documentation contradicted that reading.  The distinction only
matters because the ioctl lets an unprivileged caller pick rule_cnt
directly, so getting it wrong is a heap overflow rather than a truncated
dump.

Signed-off-by: Jakub Kicinski <kuba@kernel.org>
---
CC: andrew@lunn.ch
---
 include/linux/ethtool.h | 6 ++++++
 1 file changed, 6 insertions(+)
Reviewed-by: Joe Damato <redacted>
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help