🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Thread View: linux.kernel.netdev
2 messages
2 total messages Started by Andrew Lunn Tue, 13 Oct 2026 12:37
Re: [PATCH net-next v2 2/3] selftests: drv-net: pause: Validate the pause autonegotiation with a partner
#2769
Author: Andrew Lunn
Date: Tue, 13 Oct 2026 12:37
26 lines
7174 bytes
> > Firmware-managed NICs such as ice also keep the link on close by default.
> > In drivers/net/ethernet/intel/ice/ice_main.c, the PHY is only taken down
> > on close when ICE_FLAG_LINK_DOWN_ON_CLOSE_ENA is set:
> > 
> > 	if (test_bit(ICE_FLAG_LINK_DOWN_ON_CLOSE_ENA, vsi->back->flags)) {
> > 		int link_err = ice_phy_cfg(vsi, false);
> > 
> > On this kind of hardware, a directly connected peer would be cached as
> > cfg.lp_controllable = False. pause_aneg_resolution(), and the four later
> > tests in the series, would then skip with "is not directly connected".
> > That message points at cabling, when the real cause is that the PHY
> > stayed powered.
> > 
> > The new remote lp_advertising checks in pause_advertising_test() would
> > also be skipped without any notice.
> 
> Not much we can do if the peer doesn't behave as expected here. Not sure this
> requires attention.

I sounds like anything with a BMC is going to hit this. So i doubt you
will see it with your stmmac boards. Maybe sometime in the future we
can query the NIC to see if it supports NCSI and change the test
behaviour to fit?

	Andrew
Re: [PATCH net-next v2 2/3] selftests: drv-net: pause: Validate the pause autonegotiation with a partner
#2872
Author: Andrew Lunn
Date: Tue, 13 Oct 2026 14:49
43 lines
8158 bytes
On Tue, Oct 13, 2026 at 04:02:44PM +0200, Maxime Chevallier wrote:
> 
> 
> On 10/13/26 14:37, Andrew Lunn wrote:
> >>> Firmware-managed NICs such as ice also keep the link on close by default.
> >>> In drivers/net/ethernet/intel/ice/ice_main.c, the PHY is only taken down
> >>> on close when ICE_FLAG_LINK_DOWN_ON_CLOSE_ENA is set:
> >>>
> >>> 	if (test_bit(ICE_FLAG_LINK_DOWN_ON_CLOSE_ENA, vsi->back->flags)) {
> >>> 		int link_err = ice_phy_cfg(vsi, false);
> >>>
> >>> On this kind of hardware, a directly connected peer would be cached as
> >>> cfg.lp_controllable = False. pause_aneg_resolution(), and the four later
> >>> tests in the series, would then skip with "is not directly connected".
> >>> That message points at cabling, when the real cause is that the PHY
> >>> stayed powered.
> >>>
> >>> The new remote lp_advertising checks in pause_advertising_test() would
> >>> also be skipped without any notice.
> >>
> >> Not much we can do if the peer doesn't behave as expected here. Not sure this
> >> requires attention.
> > 
> > I sounds like anything with a BMC is going to hit this. So i doubt you
> > will see it with your stmmac boards. Maybe sometime in the future we
> > can query the NIC to see if it supports NCSI and change the test
> > behaviour to fit?
> 
> Maybe the strategy is wrong then, the goal is to check that we're directly
> connected to our test peer through a cable, or indirectly through a switch.
> 
> Link flapping seemed to me like the most generic solution, but maybe we can
> do something entirely different ? Like for example trigger a re-negotiation
> with ethtool -r and check for link flap, or maybe more reliably, ask the user
> to pass a flag to the selftest command saying if yes or no we're directly
> connected ?

Triggering a renegotiation is probably the best. I've no experience
with BMCs, but i suspect a down will not work, because it cuts the BMC
off from the network. A renegotiation does seem like a safer choice.

     Andrew
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