Re: [PATCH net-next 3/7] bng_en: add ethtool link settings, get_link, and nway_reset

From: Bhargava Chenna Marreddy

Date: Tue Feb 24 2026 - 14:23:11 EST


On Tue, Feb 24, 2026 at 1:15 AM Andrew Lunn <andrew@xxxxxxx> wrote:
>
> > + if (link_info->auto_pause_setting & BNGE_LINK_PAUSE_RX)
> > + linkmode_set_bit(ETHTOOL_LINK_MODE_Pause_BIT,
> > + lk_ksettings->link_modes.advertising);
> > + if (hweight8(link_info->auto_pause_setting & BNGE_LINK_PAUSE_BOTH) == 1)
> > + linkmode_set_bit(ETHTOOL_LINK_MODE_Asym_Pause_BIT,
> > + lk_ksettings->link_modes.advertising);
>
> It is not clear to me how you are configuring pause, and in particular
> if pause it being autoneg or forced.
>
> Ethtool has:
>
> ethtool -A|--pause devname [autoneg on|off] [rx on|off] [tx on|off]
>
> The autoneg here is separate to global autoneg. You can have global
> autoneg on, but pause autoneg off, meaning the pause configuration is
> forced.
>
> The PHY should only be advertising pause if pause autoneg is on.
>
> Andrew

Thanks, Andrew.

You are correct. Since we haven't yet implemented .get_pauseparam and
.set_pauseparam ethtool ops, there's currently no user-facing way to
independently
control pause autoneg vs. forced pause.

Internally, the driver is designed to handle these independently using
the following flags:

#define BNGE_AUTONEG_SPEED 1 (BIT 0 of elink_info->autoneg)
#define BNGE_AUTONEG_FLOW_CTRL 2 (BIT 1 of elink_info->autoneg)

During initialization, bnge_init_ethtool_link_settings() populates
these bits in elink_info->autoneg
based on the hardware's current state. However, the logic to toggle
them via ethtool is not yet exposed.

We intentionally kept this series focused on the base link bring-up to
keep the patch size manageable.
Would you prefer that we include the .get_pauseparam and
.set_pauseparam support in this series,
or is it okay to address the independent control in a follow-up patch?

Thanks,
Bhargava Marreddy

Attachment: smime.p7s
Description: S/MIME Cryptographic Signature