|
@@ -1026,6 +1026,15 @@ static void mv88e6xxx_port_stp_state_set(struct dsa_switch *ds, int port,
|
|
|
dev_err(ds->dev, "p%d: failed to update state\n", port);
|
|
|
}
|
|
|
|
|
|
+static int mv88e6xxx_trunk_setup(struct mv88e6xxx_chip *chip)
|
|
|
+{
|
|
|
+ /* Clear all trunk masks and mapping */
|
|
|
+ if (chip->info->global2_addr)
|
|
|
+ return mv88e6xxx_g2_trunk_clear(chip);
|
|
|
+
|
|
|
+ return 0;
|
|
|
+}
|
|
|
+
|
|
|
static int mv88e6xxx_pot_setup(struct mv88e6xxx_chip *chip)
|
|
|
{
|
|
|
if (chip->info->ops->pot_clear)
|
|
@@ -2239,6 +2248,10 @@ static int mv88e6xxx_setup(struct dsa_switch *ds)
|
|
|
if (err)
|
|
|
goto unlock;
|
|
|
|
|
|
+ err = mv88e6xxx_trunk_setup(chip);
|
|
|
+ if (err)
|
|
|
+ goto unlock;
|
|
|
+
|
|
|
/* Setup PTP Hardware Clock and timestamping */
|
|
|
if (chip->info->ptp_support) {
|
|
|
err = mv88e6xxx_ptp_setup(chip);
|