]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
ethtool: Clarify len/n_stats fields in/out semantics
authorGal Pressman <gal@nvidia.com>
Thu, 15 Jan 2026 06:05:44 +0000 (08:05 +0200)
committerJakub Kicinski <kuba@kernel.org>
Fri, 16 Jan 2026 03:06:46 +0000 (19:06 -0800)
commit567873005dca1be0a3b3e2e309a8f0de14d2b827
treeb46724a9440b4e89fb06272e7f29dbb56ad2d887
parentc27022497dd9b8a8922dbb878c255e4260a90e6c
ethtool: Clarify len/n_stats fields in/out semantics

Document that the 'len' field in ethtool_gstrings and 'n_stats' field in
ethtool_stats optionally serve dual purposes: on entry they specify the
number of items requested, and on return they indicate the number
actually returned (which is not necessarily the same).

Signed-off-by: Gal Pressman <gal@nvidia.com>
Reviewed-by: Dragos Tatulea <dtatulea@nvidia.com>
Link: https://patch.msgid.link/20260115060544.481550-1-gal@nvidia.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
include/uapi/linux/ethtool.h