#include <linux/phylink.h>
#include <linux/regmap.h>
#include <linux/regulator/consumer.h>
-@@ -2568,128 +2569,11 @@ static int mt7531_rgmii_setup(struct mt7
+@@ -2598,128 +2599,11 @@ static int mt7531_rgmii_setup(struct mt7
return 0;
}
static int
mt7531_mac_config(struct dsa_switch *ds, int port, unsigned int mode,
phy_interface_t interface)
-@@ -2712,11 +2596,11 @@ mt7531_mac_config(struct dsa_switch *ds,
+@@ -2742,11 +2626,11 @@ mt7531_mac_config(struct dsa_switch *ds,
phydev = dp->slave->phydev;
return mt7531_rgmii_setup(priv, port, interface, phydev);
case PHY_INTERFACE_MODE_SGMII:
default:
return -EINVAL;
}
-@@ -2741,11 +2625,11 @@ mt753x_phylink_mac_select_pcs(struct dsa
+@@ -2771,11 +2655,11 @@ mt753x_phylink_mac_select_pcs(struct dsa
switch (interface) {
case PHY_INTERFACE_MODE_TRGMII:
default:
return NULL;
}
-@@ -2986,86 +2870,6 @@ static void mt7530_pcs_get_state(struct
+@@ -3016,86 +2900,6 @@ static void mt7530_pcs_get_state(struct
state->pause |= MLO_PAUSE_TX;
}
static int mt753x_pcs_config(struct phylink_pcs *pcs, unsigned int mode,
phy_interface_t interface,
const unsigned long *advertising,
-@@ -3085,18 +2889,57 @@ static const struct phylink_pcs_ops mt75
+@@ -3115,18 +2919,57 @@ static const struct phylink_pcs_ops mt75
.pcs_an_restart = mt7530_pcs_an_restart,
};
int i, ret;
/* Initialise the PCS devices */
-@@ -3104,8 +2947,6 @@ mt753x_setup(struct dsa_switch *ds)
+@@ -3134,8 +2977,6 @@ mt753x_setup(struct dsa_switch *ds)
priv->pcs[i].pcs.ops = priv->info->pcs_ops;
priv->pcs[i].priv = priv;
priv->pcs[i].port = i;
}
ret = priv->info->sw_setup(ds);
-@@ -3120,6 +2961,16 @@ mt753x_setup(struct dsa_switch *ds)
+@@ -3150,6 +2991,16 @@ mt753x_setup(struct dsa_switch *ds)
if (ret && priv->irq)
mt7530_free_irq_common(priv);
return ret;
}
-@@ -3211,7 +3062,7 @@ static const struct mt753x_info mt753x_t
+@@ -3241,7 +3092,7 @@ static const struct mt753x_info mt753x_t
},
[ID_MT7531] = {
.id = ID_MT7531,
.sw_setup = mt7531_setup,
.phy_read = mt7531_ind_phy_read,
.phy_write = mt7531_ind_phy_write,
-@@ -3319,7 +3170,7 @@ static void
+@@ -3349,7 +3200,7 @@ static void
mt7530_remove(struct mdio_device *mdiodev)
{
struct mt7530_priv *priv = dev_get_drvdata(&mdiodev->dev);
if (!priv)
return;
-@@ -3338,6 +3189,10 @@ mt7530_remove(struct mdio_device *mdiode
+@@ -3368,6 +3219,10 @@ mt7530_remove(struct mdio_device *mdiode
mt7530_free_irq(priv);
dsa_unregister_switch(priv->ds);