Thread View: linux.kernel.netdev
1 messages
1 total messages
Started by Nicolai Buchwitz
Sat, 28 Nov 2026 12:50
Re: [PATCH net-next v9 1/3] net: macb: cache ENST config across link down/up
Author: Nicolai Buchwitz
Date: Sat, 28 Nov 2026 12:50
Date: Sat, 28 Nov 2026 12:50
46 lines
10692 bytes
10692 bytes
On 27.11.2026 22:44, Théo Lebrun wrote:
> Currently, ENST is not explicitly restored across interface close/open.
> If HW keeps its register state then ENST is kept, otherwise it is lost;
> but we do not write the ENST schedule again on open.
>
> This causes trouble if the config is not compatible with the new open
> and link-up. The two issues that can occur are a link speed change (as
> all timings are configured in a unit relative to the link speed) or a
> change in the # of queues.
>
> The latter is the main reason we do this change before implementing
> ethtool -L support.
>
> If on link-up, the cached ENST config is invalid (link speed changed),
> then we ignore the cached config, log a warning and disable ENST on all
> queues. If it is valid, we explicitly re-apply it.
>
> We ignore the cached config, hoping the current link speed is a
> degraded
> state which will recover.
>
> Take this opportunity to replace a kmalloc in
> macb_taprio_setup_replace() with a simple and tiny (104b) stack value.
>
> Drop the old hack of checking for pm_runtime_suspended(), which has
> little value because we could race with the runtime_suspend() call.
>
> Synchronise our config using the existing bp->mac_cfg_lock mutex, taken
> by macb_taprio_setup_replace() and macb_taprio_destroy(). To avoid an
> ABBA deadlock between bp->mac_cfg_lock and phydev->lock taken by
> phylink_ethtool_ksettings_get(), cache the link speed as
> bp->speed_mbps.
>
> Fixes: 89934dbf169e ("net: macb: Add TAPRIO traffic scheduling
> support")
> Cc: <stable+noautosel@kernel.org> # more a feature than a bugfix!
> Signed-off-by: Théo Lebrun <theo.lebrun@bootlin.com>
> ---
> [...]
Reviewed-by: Nicolai Buchwitz <nb@tipi-net.de>
Thanks,
Nicolai
Thread Navigation
This is a paginated view of messages in the thread with full content displayed inline.
Messages are displayed in chronological order, with the original post highlighted in green.
Use pagination controls to navigate through all messages in large threads.
Back to All Threads