[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20250724101822.GJ1150792@horms.kernel.org>
Date: Thu, 24 Jul 2025 11:18:22 +0100
From: Simon Horman <horms@...nel.org>
To: Mohsin Bashir <mohsin.bashr@...il.com>
Cc: netdev@...r.kernel.org, kuba@...nel.org, alexanderduyck@...com,
andrew+netdev@...n.ch, davem@...emloft.net, edumazet@...gle.com,
pabeni@...hat.com, vadim.fedorenko@...ux.dev, jdamato@...tly.com,
sdf@...ichev.me, aleksander.lobakin@...el.com, ast@...nel.org,
daniel@...earbox.net, hawk@...nel.org, john.fastabend@...il.com
Subject: Re: [PATCH net-next 8/9] eth: fbnic: Collect packet statistics for
XDP
On Wed, Jul 23, 2025 at 07:59:25AM -0700, Mohsin Bashir wrote:
> Add support for XDP statistics collection and reporting via rtnl_link
> and netdev_queue API.
>
> For XDP programs without frags support, fbnic requires MTU to be less
> than the HDS threshold. If an over-sized frame is received, the frame
> is dropped and recorded as rx_length_errors reported via ip stats to
> highlight that this is an error.
>
> Signed-off-by: Jakub Kicinski <kuba@...nel.org>
> Signed-off-by: Mohsin Bashir <mohsin.bashr@...il.com>
> ---
> .../device_drivers/ethernet/meta/fbnic.rst | 10 +++++
> .../net/ethernet/meta/fbnic/fbnic_netdev.c | 30 +++++++++++++
> drivers/net/ethernet/meta/fbnic/fbnic_txrx.c | 44 +++++++++++++++++--
> drivers/net/ethernet/meta/fbnic/fbnic_txrx.h | 1 +
> 4 files changed, 82 insertions(+), 3 deletions(-)
>
> diff --git a/Documentation/networking/device_drivers/ethernet/meta/fbnic.rst b/Documentation/networking/device_drivers/ethernet/meta/fbnic.rst
> index afb8353daefd..ad5e2cba7afc 100644
> --- a/Documentation/networking/device_drivers/ethernet/meta/fbnic.rst
> +++ b/Documentation/networking/device_drivers/ethernet/meta/fbnic.rst
> @@ -160,3 +160,13 @@ behavior and potential performance bottlenecks.
> credit exhaustion
> - ``pcie_ob_rd_no_np_cred``: Read requests dropped due to non-posted
> credit exhaustion
> +
> +XDP Length Error:
> +~~~~~~~~~~~~~~~~~
> +
> +For XDP programs without frags support, fbnic tries to make sure that MTU fits
> +into a single buffer. If an oversized frame is received and gets fragmented,
> +it is dropped and the following netlink counters are updated
> + - ``rx-length``: number of frames dropped due to lack of fragmentation
> + support in the attached XDP program
> + - ``rx-errors``: total number of packets with errors received on the interface
Hi Mohsin,
make hmtldocs complains a bit about this:
.../fbnic.rst:170: ERROR: Unexpected indentation. [docutils]
.../fbnic.rst:171: WARNING: Bullet list ends without a blank line; unexpected unindent. [docutils]
Empirically, and I admit there was much trial and error involved,
I was able to address this by:
* adding a blank before the start of the list
* updating the indentation of the follow-on line of the first entry of the list
Your mileage may vary.
diff --git a/Documentation/networking/device_drivers/ethernet/meta/fbnic.rst b/Documentation/networking/device_drivers/ethernet/meta/fbnic.rst
index ad5e2cba7afc..fb6559fa4be4 100644
--- a/Documentation/networking/device_drivers/ethernet/meta/fbnic.rst
+++ b/Documentation/networking/device_drivers/ethernet/meta/fbnic.rst
@@ -167,6 +167,7 @@ XDP Length Error:
For XDP programs without frags support, fbnic tries to make sure that MTU fits
into a single buffer. If an oversized frame is received and gets fragmented,
it is dropped and the following netlink counters are updated
+
- ``rx-length``: number of frames dropped due to lack of fragmentation
- support in the attached XDP program
+ support in the attached XDP program
- ``rx-errors``: total number of packets with errors received on the interface
Powered by blists - more mailing lists