aboutsummaryrefslogtreecommitdiffstats
path: root/target/linux/realtek/files-5.4
diff options
context:
space:
mode:
authorBjørn Mork <bjorn@mork.no>2021-03-13 17:45:50 +0100
committerPetr Štetiar <ynezz@true.cz>2021-03-17 10:01:21 +0100
commit785d830e889ba18793acf369e447d704269169af (patch)
tree2169b3dd3429aeb8d3ea43e6c0c9afadb6632e93 /target/linux/realtek/files-5.4
parentb8e473d18c6af2abf0d047247fdbe6d178228ac0 (diff)
downloadupstream-785d830e889ba18793acf369e447d704269169af.tar.gz
upstream-785d830e889ba18793acf369e447d704269169af.tar.bz2
upstream-785d830e889ba18793acf369e447d704269169af.zip
realtek: need to handle PHY_INTERFACE_MODE_NA for sfps
From the validate docs in include/linux/phylink.h: When state->interface is PHY_INTERFACE_MODE_NA, phylink expects the MAC driver to return all supported link modes. Tested-by: Birger Koblitz <mail@birger-koblitz.de> Signed-off-by: Bjørn Mork <bjorn@mork.no>
Diffstat (limited to 'target/linux/realtek/files-5.4')
-rw-r--r--target/linux/realtek/files-5.4/drivers/net/dsa/rtl83xx/dsa.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/target/linux/realtek/files-5.4/drivers/net/dsa/rtl83xx/dsa.c b/target/linux/realtek/files-5.4/drivers/net/dsa/rtl83xx/dsa.c
index af6d92cbc2..2c49ea27a1 100644
--- a/target/linux/realtek/files-5.4/drivers/net/dsa/rtl83xx/dsa.c
+++ b/target/linux/realtek/files-5.4/drivers/net/dsa/rtl83xx/dsa.c
@@ -245,6 +245,7 @@ static void rtl83xx_phylink_validate(struct dsa_switch *ds, int port,
pr_debug("In %s port %d", __func__, port);
if (!phy_interface_mode_is_rgmii(state->interface) &&
+ state->interface != PHY_INTERFACE_MODE_NA &&
state->interface != PHY_INTERFACE_MODE_1000BASEX &&
state->interface != PHY_INTERFACE_MODE_MII &&
state->interface != PHY_INTERFACE_MODE_REVMII &&