Re: [PATCH net-next v8 04/10] bnge: add RXFH ethtool support

From: netdev-bot+sashiko

Date: Thu Nov 19 2026 - 12:10:24 EST


Thank you for your contribution! Sashiko AI review found more severe
issue(s) in other patches of this series. This mail is only an FYI, in case
you want to address the nit picks below when you respin.

Low priority / nit picks for your consideration:

- [Low] The commit message does not mention a functional change in
bnge_alloc_irqs() (drivers/net/ethernet/broadcom/bnge/bnge_resc.c).

--

bnge: add RXFH ethtool support

This patch adds the ethtool RXFH operations (get/set_rxfh and
get/set_rxfh_fields) to bnge. Changes are only accepted while the device
is down. It also moves the default RSS key to netdev_rss_key_fill() and
removes the RSS_HASH_TYPE_DELTA_CAP handling.

> diff --git a/drivers/net/ethernet/broadcom/bnge/bnge_resc.c b/drivers/net/ethernet/broadcom/bnge/bnge_resc.c
> index 506ceee775e19..25aa6e7c43c37 100644
> --- a/drivers/net/ethernet/broadcom/bnge/bnge_resc.c
> +++ b/drivers/net/ethernet/broadcom/bnge/bnge_resc.c

[ ... ]

> @@ -435,12 +435,17 @@ int bnge_alloc_irqs(struct bnge_dev *bd)
> * We dont need to consider NQs as they have been calculated
> * and must be more than irqs_demand.
> */
> + old_rx = bd->rx_nr_rings;
> rc = bnge_adjust_rings(bd, &bd->rx_nr_rings,
> &bd->tx_nr_rings,
> irqs_demand - aux_msix, min == 1);
> if (rc)
> goto err_free_irqs;
>
> + /* The indirection table may point at rings that were just removed */
> + if (bd->rx_nr_rings != old_rx)
> + bnge_set_dflt_rss_indir_tbl(bd);
> +

[Severity: Low]
This isn't a bug, but should the commit message mention this change in
bnge_alloc_irqs()?

During probe, bnge_init_one() first calls bnge_net_init_dflt_config(),
which fills the default indirection table from the original rx_nr_rings.
It then calls bnge_alloc_irqs():

bnge_init_one()
bnge_net_init_dflt_config() <- table filled from original rx_nr_rings
bnge_alloc_irqs()
bnge_adjust_rings() <- rx_nr_rings may shrink here

Without the new reset, the table could still hold entries for RX rings
that were just removed, and the new get_rxfh would report them before the
first open.

That looks like a fix for a stale-index problem that existed before this
patch. Would it be better as a separate patch, possibly with a Fixes: tag?

The changelog covers the other side changes in detail, such as the new
default key source, the removal of rss_hash_key_valid and the removal of
DELTA_CAP. It does not mention this reset. It also does not mention the
new BNGE_RSS_CAP_IPV6_FLOW_LABEL_RSS_CAP bit or the renumbering of the
BNGE_RSS_CAP_* enum in bnge.h.

> tx_cp = bnge_num_tx_to_cp(bd, bd->tx_nr_rings);
> bd->nq_nr_rings = (min == 1) ?
> max_t(u16, tx_cp, bd->rx_nr_rings) :

--
Sashiko AI review · https://netdev-ai.bots.linux.dev/sashiko/#/patchset/20261116140653.1685797-1-vikas.gupta%40broadcom.com