Files
infix/patches/linux/6.18.39/0017-net-dsa-mv88e6xxx-Honor-ports-being-managed-via-in-b.patch
T

43 lines
1.3 KiB
Diff

From b23b36d1963b8a8b61adc26a1971c78623987285 Mon Sep 17 00:00:00 2001
From: Tobias Waldekranz <tobias@waldekranz.com>
Date: Mon, 22 Apr 2024 23:18:01 +0200
Subject: [PATCH 17/50] net: dsa: mv88e6xxx: Honor ports being managed via
in-band-status
Keep all link parameters in their unforced states when the port is
declared as being managed via in-band-status, and let the MAC
configure itself, via whatever method is being used (e.g. SGMII or
USXGMII autoneg)
This state is the default set up by mv88e6xxx_port_setup_mac(), so all
we have to do is to make the phylink MAC callbacks no-ops in cases
when in-band-status is being used.
---
drivers/net/dsa/mv88e6xxx/chip.c | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/drivers/net/dsa/mv88e6xxx/chip.c b/drivers/net/dsa/mv88e6xxx/chip.c
index c51588e74aed..de230df48545 100644
--- a/drivers/net/dsa/mv88e6xxx/chip.c
+++ b/drivers/net/dsa/mv88e6xxx/chip.c
@@ -965,6 +965,9 @@ static void mv88e6xxx_mac_link_down(struct phylink_config *config,
int port = dp->index;
int err = 0;
+ if (mode == MLO_AN_INBAND)
+ return;
+
ops = chip->info->ops;
mv88e6xxx_reg_lock(chip);
@@ -997,6 +1000,9 @@ static void mv88e6xxx_mac_link_up(struct phylink_config *config,
int port = dp->index;
int err = 0;
+ if (mode == MLO_AN_INBAND)
+ return;
+
ops = chip->info->ops;
mv88e6xxx_reg_lock(chip);