[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <1629873655-51539-1-git-send-email-huangguangbin2@huawei.com>
Date: Wed, 25 Aug 2021 14:40:50 +0800
From: Guangbin Huang <huangguangbin2@...wei.com>
To: <davem@...emloft.net>, <kuba@...nel.org>, <mkubecek@...e.cz>,
<andrew@...n.ch>, <amitc@...lanox.com>, <idosch@...sch.org>,
<danieller@...dia.com>
CC: <netdev@...r.kernel.org>, <lipeng321@...wei.com>,
<chenhao288@...ilicon.com>, <huangguangbin2@...wei.com>
Subject: [PATCH net-next 0/5] ethtool: add support to set/get tx spare buf size and rx buf len
This series add support to set/get tx spare buf size and rx buf len via
ethtool and hns3 driver implements them.
Tx spare buf size is used for tx copybreak feature which for small size
packet or frag. Use ethtool --get-tunable command to get it, and ethtool
--set-tunable command to set it, examples are as follow:
1. set tx spare buf size to 102400:
$ ethtool --set-tunable eth1 tx-buf-size 102400
2. get tx spare buf size:
$ ethtool --get-tunable eth1 tx-buf-size
tx-buf-size: 102400
Rx buf len is buffer length of each rx BD. Use ethtool -g command to get
it, and ethtool -G command to set it, examples are as follow:
1. set rx buf len to 4096
$ ethtool -G eth1 rx-buf-len 4096
2. get rx buf len
$ ethtool -g eth1
...
RX Buf Len: 4096
Hao Chen (5):
ethtool: add support to set/get tx spare buf size
net: hns3: add support to set/get tx spare buf via ethtool for hns3
driver
ethtool: add support to set/get rx buf len
net: hns3: add support to set/get rx buf len via ethtool for hns3
driver
net: hns3: remove the way to set tx spare buf via module parameter
drivers/net/ethernet/hisilicon/hns3/hns3_enet.c | 11 +--
drivers/net/ethernet/hisilicon/hns3/hns3_enet.h | 2 +
drivers/net/ethernet/hisilicon/hns3/hns3_ethtool.c | 98 ++++++++++++++++++++--
include/uapi/linux/ethtool.h | 3 +
include/uapi/linux/ethtool_netlink.h | 1 +
net/ethtool/ioctl.c | 1 +
net/ethtool/netlink.h | 2 +-
net/ethtool/rings.c | 11 ++-
8 files changed, 112 insertions(+), 17 deletions(-)
--
2.8.1
Powered by blists - more mailing lists