[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20230301200055.69e86e53@kernel.org>
Date: Wed, 1 Mar 2023 20:00:55 -0800
From: Jakub Kicinski <kuba@...nel.org>
To: Shay Agroskin <shayagr@...zon.com>
Cc: David Miller <davem@...emloft.net>, <netdev@...r.kernel.org>,
"Woodhouse, David" <dwmw@...zon.com>,
"Machulsky, Zorik" <zorik@...zon.com>,
"Matushevsky, Alexander" <matua@...zon.com>,
Saeed Bshara <saeedb@...zon.com>,
"Wilson, Matt" <msw@...zon.com>,
"Liguori, Anthony" <aliguori@...zon.com>,
"Bshara, Nafea" <nafea@...zon.com>,
"Belgazal, Netanel" <netanel@...zon.com>,
"Saidi, Ali" <alisaidi@...zon.com>,
"Herrenschmidt, Benjamin" <benh@...zon.com>,
"Kiyanovski, Arthur" <akiyano@...zon.com>,
"Dagan, Noam" <ndagan@...zon.com>,
"Arinzon, David" <darinzon@...zon.com>,
"Itzko, Shahar" <itzko@...zon.com>,
"Abboud, Osama" <osamaabb@...zon.com>
Subject: Re: [PATCH RFC v1 net-next 1/5] ethtool: Add support for
configuring tx_push_buf_len
On Wed, 1 Mar 2023 19:59:12 +0200 Shay Agroskin wrote:
> @@ -98,7 +100,12 @@ static int rings_fill_reply(struct sk_buff *skb,
> (kr->cqe_size &&
> (nla_put_u32(skb, ETHTOOL_A_RINGS_CQE_SIZE, kr->cqe_size))) ||
> nla_put_u8(skb, ETHTOOL_A_RINGS_TX_PUSH, !!kr->tx_push) ||
> - nla_put_u8(skb, ETHTOOL_A_RINGS_RX_PUSH, !!kr->rx_push))
> + nla_put_u8(skb, ETHTOOL_A_RINGS_RX_PUSH, !!kr->rx_push) ||
> + (kr->tx_push_buf_len &&
> + (nla_put_u32(skb, ETHTOOL_A_RINGS_TX_PUSH_BUF_LEN_MAX,
> + kr->tx_push_buf_max_len) ||
> + nla_put_u32(skb, ETHTOOL_A_RINGS_TX_PUSH_BUF_LEN,
> + kr->tx_push_buf_len))))
Why gate both on kr->tx_push_buf_len and not current and max separately?
Is kr->tx_push_buf_len == 0 never a valid setting?
Otherwise LGTM!
Could you add this chunk to expose the value in the YAML spec?
diff --git a/Documentation/netlink/specs/ethtool.yaml b/Documentation/netlink/specs/ethtool.yaml
index 35c462bce56f..2dd6aef582e4 100644
--- a/Documentation/netlink/specs/ethtool.yaml
+++ b/Documentation/netlink/specs/ethtool.yaml
@@ -163,6 +163,12 @@ doc: Partial family for Ethtool Netlink.
-
name: rx-push
type: u8
+ -
+ name: tx-push-buf-len
+ type: u32
+ -
+ name: tx-push-buf-len-max
+ type: u32
-
name: mm-stat
@@ -309,6 +315,8 @@ doc: Partial family for Ethtool Netlink.
- cqe-size
- tx-push
- rx-push
+ - tx-push-buf-len
+ - tx-push-buf-len-max
dump: *ring-get-op
-
name: rings-set
Powered by blists - more mailing lists