@@ -210,6 +210,7 @@ ethtool \- query or control network driver and hardware settings
.BN tx
.BN rx\-buf\-len
.B3 tcp\-data\-split auto on off
+.BN hds\-thresh
.BN cqe\-size
.BN tx\-push
.BN rx\-push
@@ -692,6 +693,9 @@ Changes the size of a buffer in the Rx ring.
.BI tcp\-data\-split \ auto|on|off
Specifies the state of TCP data split.
.TP
+.BI hds\-thresh \ N
+Specifies the threshold value of tcp data split
+.TP
.BI cqe\-size \ N
Changes the size of completion queue event.
.TP
@@ -5874,6 +5874,7 @@ static const struct option args[] = {
" [ tx-push on|off ]\n"
" [ rx-push on|off ]\n"
" [ tx-push-buf-len N]\n"
+ " [ hds-thresh N ]\n"
},
{
.opts = "-k|--show-features|--show-offload",
@@ -161,6 +161,8 @@ static const struct pretty_nla_desc __rings_desc[] = {
NLATTR_DESC_BOOL(ETHTOOL_A_RINGS_RX_PUSH),
NLATTR_DESC_U32(ETHTOOL_A_RINGS_TX_PUSH_BUF_LEN),
NLATTR_DESC_U32(ETHTOOL_A_RINGS_TX_PUSH_BUF_LEN_MAX),
+ NLATTR_DESC_U32(ETHTOOL_A_RINGS_HDS_THRESH),
+ NLATTR_DESC_U32(ETHTOOL_A_RINGS_HDS_THRESH_MAX),
};
static const struct pretty_nla_desc __channels_desc[] = {
@@ -51,6 +51,8 @@ int rings_reply_cb(const struct nlmsghdr *nlhdr, void *data)
show_u32("tx-max", "TX:\t\t\t", tb[ETHTOOL_A_RINGS_TX_MAX]);
show_u32("tx-push-buff-max-len", "TX push buff len:\t",
tb[ETHTOOL_A_RINGS_TX_PUSH_BUF_LEN_MAX]);
+ show_u32("hds-thresh-max", "HDS thresh:\t\t",
+ tb[ETHTOOL_A_RINGS_HDS_THRESH_MAX]);
print_string(PRINT_FP, NULL, "Current hardware settings:\n", NULL);
show_u32("rx", "RX:\t\t\t", tb[ETHTOOL_A_RINGS_RX]);
show_u32("rx-mini", "RX Mini:\t\t", tb[ETHTOOL_A_RINGS_RX_MINI]);
@@ -83,6 +85,8 @@ int rings_reply_cb(const struct nlmsghdr *nlhdr, void *data)
print_string(PRINT_ANY, tcp_hds_key, tcp_hds_fmt, tcp_hds_buf);
break;
}
+ show_u32("hds-thresh", "HDS thresh:\t\t",
+ tb[ETHTOOL_A_RINGS_HDS_THRESH]);
close_json_object();
@@ -194,6 +198,12 @@ static const struct param_parser sring_params[] = {
.handler = nl_parse_u8bool,
.min_argc = 1,
},
+ {
+ .arg = "hds-thresh",
+ .type = ETHTOOL_A_RINGS_HDS_THRESH,
+ .handler = nl_parse_direct_u32,
+ .min_argc = 0,
+ },
{}
};
HDS(Header Data Split) threshold value is used by header-data-split. If received packet's length is larger than hds-thresh value, header/data of packet will be splited. ethtool -g|--get-ring <interface name> hds-thresh ethtool -G|--set-ring <interface name> hds-thresh <0 - MAX> The minimum value is 0, which indicates header/data will be splited for all receive packets. The maximum value is up to hardware limitation. Signed-off-by: Taehee Yoo <ap420073@gmail.com> --- This is an RFC due to merge-window. ethtool.8.in | 4 ++++ ethtool.c | 1 + netlink/desc-ethtool.c | 2 ++ netlink/rings.c | 10 ++++++++++ 4 files changed, 17 insertions(+)