Netdev List
 help / color / mirror / Atom feed
* [PATCH net-next 0/2] net: stmmac: only use MAC loopback for selftests
@ 2026-07-28 15:57 Maxime Chevallier
  2026-07-28 15:57 ` [PATCH net-next 1/2] net: stmmac: Don't use PHY " Maxime Chevallier
  2026-07-28 15:57 ` [PATCH net-next 2/2] net: stmmac: Don't rely on the PHY for flow-control testing Maxime Chevallier
  0 siblings, 2 replies; 3+ messages in thread
From: Maxime Chevallier @ 2026-07-28 15:57 UTC (permalink / raw)
  To: Andrew Lunn, Jakub Kicinski, davem, Eric Dumazet, Paolo Abeni,
	Simon Horman, Maxime Coquelin, Alexandre Torgue, Russell King
  Cc: Maxime Chevallier, Oleksij Rempel, Zxyan Zhu, thomas.petazzoni,
	Alexis Lothoré, netdev, linux-kernel, linux-arm-kernel,
	linux-stm32

stmmac selftests currently use PHY loopback when a PHY is attached, and
fallback to MAC loopback otherwise. PHY loopback however isn't ideal nor
necessary for the tests we are running, that only stress the internal
stmmac features.

Some PHYs bring the carrier state down when in loopback mode, which will
prevent any packet transmission even for ourselves, making selftests
fail for non-stmmac related reasons.

Let's rely only on MAC-side loopback for selftests, making it clear that
any problem found with stmmac selftests are indeed caused by the stmmac
driver, and not external factors.

This was tested on :

 - Cyclone V with RGMII link to KSZ9031
 - Cyclone V with 1000BaseX
 - imx8mp with RGMII link to KSZ9131
 - stm32mp157& with RGMII link to RTL8211F
 - Allwinner H2+ with an internal PHY

Maxime Chevallier (2):
  net: stmmac: Don't use PHY loopback for selftests
  net: stmmac: Don't rely on the PHY for flow-control testing

 .../stmicro/stmmac/stmmac_selftests.c         | 117 ++----------------
 1 file changed, 11 insertions(+), 106 deletions(-)

-- 
2.55.0


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2026-07-28 15:57 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-07-28 15:57 [PATCH net-next 0/2] net: stmmac: only use MAC loopback for selftests Maxime Chevallier
2026-07-28 15:57 ` [PATCH net-next 1/2] net: stmmac: Don't use PHY " Maxime Chevallier
2026-07-28 15:57 ` [PATCH net-next 2/2] net: stmmac: Don't rely on the PHY for flow-control testing Maxime Chevallier

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox