[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20240614200156.GX8447@kernel.org>
Date: Fri, 14 Jun 2024 21:01:56 +0100
From: Simon Horman <horms@...nel.org>
To: David Wei <dw@...idwei.uk>
Cc: Michael Chan <michael.chan@...adcom.com>,
Andy Gospodarek <andrew.gospodarek@...adcom.com>,
Adrian Alvarado <adrian.alvarado@...adcom.com>,
Somnath Kotur <somnath.kotur@...adcom.com>, netdev@...r.kernel.org,
Pavel Begunkov <asml.silence@...il.com>,
Jakub Kicinski <kuba@...nel.org>, David Ahern <dsahern@...nel.org>,
"David S. Miller" <davem@...emloft.net>,
Eric Dumazet <edumazet@...gle.com>, Paolo Abeni <pabeni@...hat.com>
Subject: Re: [PATCH net-next v1 2/3] bnxt_en: split rx ring helpers out from
ring helpers
On Mon, Jun 10, 2024 at 07:33:23PM -0700, David Wei wrote:
> To prepare for queue API implementation, split rx ring functions out
> from ring helpers. These new helpers will be called from queue API
> implementation.
>
> Signed-off-by: David Wei <dw@...idwei.uk>
> ---
> drivers/net/ethernet/broadcom/bnxt/bnxt.c | 302 ++++++++++++++--------
> 1 file changed, 195 insertions(+), 107 deletions(-)
>
> diff --git a/drivers/net/ethernet/broadcom/bnxt/bnxt.c b/drivers/net/ethernet/broadcom/bnxt/bnxt.c
...
> +static int bnxt_init_one_rx_ring(struct bnxt *bp, int ring_nr)
> +{
> + struct bnxt_rx_ring_info *rxr;
> + struct bnxt_ring_struct *ring;
> +
> + rxr = &bp->rx_ring[ring_nr];
> + ring = &rxr->rx_ring_struct;
Hi David,
A minor nit from my side.
ring is set but otherwise unused in this function.
Flagged by W=1 builds with gcc-13 and clang-18.
> + bnxt_init_one_rx_ring_rxbd(bp, rxr);
> +
> + netif_queue_set_napi(bp->dev, ring_nr, NETDEV_QUEUE_TYPE_RX,
> + &rxr->bnapi->napi);
> +
> + if (BNXT_RX_PAGE_MODE(bp) && bp->xdp_prog) {
> + bpf_prog_add(bp->xdp_prog, 1);
> + rxr->xdp_prog = bp->xdp_prog;
> + }
> +
> + bnxt_init_one_rx_agg_ring_rxbd(bp, rxr);
>
> return bnxt_alloc_one_rx_ring(bp, ring_nr);
> }
...
Powered by blists - more mailing lists