Re: [PATCH net-next 1/5] ethtool: add support to set/get tx spare buf size
From: huangguangbin (A) <hidden>
Date: 2021-08-26 06:55:38
On 2021/8/25 22:56, Jakub Kicinski wrote:
On Wed, 25 Aug 2021 14:40:51 +0800 Guangbin Huang wrote:quoted
From: Hao Chen <redacted> Add support for ethtool to set/get tx spare buf size. Signed-off-by: Hao Chen <redacted> Signed-off-by: Guangbin Huang <redacted> --- include/uapi/linux/ethtool.h | 1 + net/ethtool/ioctl.c | 1 + 2 files changed, 2 insertions(+)diff --git a/include/uapi/linux/ethtool.h b/include/uapi/linux/ethtool.h index b6db6590baf0..266e95e4fb33 100644 --- a/include/uapi/linux/ethtool.h +++ b/include/uapi/linux/ethtool.h@@ -231,6 +231,7 @@ enum tunable_id { ETHTOOL_RX_COPYBREAK, ETHTOOL_TX_COPYBREAK, ETHTOOL_PFC_PREVENTION_TOUT, /* timeout in msecs */ + ETHTOOL_TX_COPYBREAK_BUF_SIZE,We need good documentation for the new tunable.
Ok.
quoted
/* * Add your fresh new tunable attribute above and remember to update * tunable_strings[] in net/ethtool/common.cdiff --git a/net/ethtool/ioctl.c b/net/ethtool/ioctl.c index f2abc3152888..9fc801298fde 100644 --- a/net/ethtool/ioctl.c +++ b/net/ethtool/ioctl.c@@ -2377,6 +2377,7 @@ static int ethtool_tunable_valid(const struct ethtool_tunable *tuna) switch (tuna->id) { case ETHTOOL_RX_COPYBREAK: case ETHTOOL_TX_COPYBREAK: + case ETHTOOL_TX_COPYBREAK_BUF_SIZE: if (tuna->len != sizeof(u32) || tuna->type_id != ETHTOOL_TUNABLE_U32) return -EINVAL;.