Commit 2c7e46ed authored by Klaus Kudielka's avatar Klaus Kudielka Committed by Jakub Kicinski

net: dsa: mv88e6xxx: mask apparently non-existing phys during probing

To avoid excessive mdio bus transactions during probing, mask all phy
addresses that do not exist (there is a 1:1 mapping between switch port
number and phy address).
Suggested-by: default avatarAndrew Lunn <andrew@lunn.ch>
Signed-off-by: default avatarKlaus Kudielka <klaus.kudielka@gmail.com>
Reviewed-by: default avatarAndrew Lunn <andrew@lunn.ch>
Reviewed-by: default avatarVladimir Oltean <olteanv@gmail.com>
Reviewed-by: default avatarFlorian Fainelli <f.fainelli@gmail.com>
Signed-off-by: default avatarJakub Kicinski <kuba@kernel.org>
parent 2cb0658d
...@@ -3805,6 +3805,7 @@ static int mv88e6xxx_mdio_register(struct mv88e6xxx_chip *chip, ...@@ -3805,6 +3805,7 @@ static int mv88e6xxx_mdio_register(struct mv88e6xxx_chip *chip,
bus->read_c45 = mv88e6xxx_mdio_read_c45; bus->read_c45 = mv88e6xxx_mdio_read_c45;
bus->write_c45 = mv88e6xxx_mdio_write_c45; bus->write_c45 = mv88e6xxx_mdio_write_c45;
bus->parent = chip->dev; bus->parent = chip->dev;
bus->phy_mask = GENMASK(31, mv88e6xxx_num_ports(chip));
if (!external) { if (!external) {
err = mv88e6xxx_g2_irq_mdio_setup(chip, bus); err = mv88e6xxx_g2_irq_mdio_setup(chip, bus);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment