All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH net-next 0/5] ethtool: add support to set/get tx spare buf size and rx buf len
@ 2021-08-25  6:40 Guangbin Huang
  2021-08-25  6:40 ` [PATCH net-next 1/5] ethtool: add support to set/get tx spare buf size Guangbin Huang
                   ` (4 more replies)
  0 siblings, 5 replies; 11+ messages in thread
From: Guangbin Huang @ 2021-08-25  6:40 UTC (permalink / raw)
  To: davem, kuba, mkubecek, andrew, amitc, idosch, danieller
  Cc: netdev, lipeng321, chenhao288, huangguangbin2

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


^ permalink raw reply	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2021-08-26  7:26 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-08-25  6:40 [PATCH net-next 0/5] ethtool: add support to set/get tx spare buf size and rx buf len Guangbin Huang
2021-08-25  6:40 ` [PATCH net-next 1/5] ethtool: add support to set/get tx spare buf size Guangbin Huang
2021-08-25 14:56   ` Jakub Kicinski
2021-08-26  6:55     ` huangguangbin (A)
2021-08-26  7:26   ` Michal Kubecek
2021-08-25  6:40 ` [PATCH net-next 2/5] net: hns3: add support to set/get tx spare buf via ethtool for hns3 driver Guangbin Huang
2021-08-25  6:40 ` [PATCH net-next 3/5] ethtool: add support to set/get rx buf len Guangbin Huang
2021-08-25 15:09   ` Jakub Kicinski
2021-08-26  7:05     ` huangguangbin (A)
2021-08-25  6:40 ` [PATCH net-next 4/5] net: hns3: add support to set/get rx buf len via ethtool for hns3 driver Guangbin Huang
2021-08-25  6:40 ` [PATCH net-next 5/5] net: hns3: remove the way to set tx spare buf via module parameter Guangbin Huang

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.