net: dsa: mv88e6xxx: Fix PHY interrupts by parameterising PHY base address

Most of the mv88e6xxx switches have the PHYs at address 0, 1, 2, ...
The 6341 however has the PHYs at 0x10, 0x11, 0x12. Add a parameter to
the info structure for this base address.

Testing of 6f88284f3b ("net: dsa: mv88e6xxx: Add MDIO interrupts for
internal PHYs") was performed on the 6341. So it works only on the
6341. Use this base information to correctly set the interrupt.

Fixes: 6f88284f3b ("net: dsa: mv88e6xxx: Add MDIO interrupts for internal PHYs")
Signed-off-by: Andrew Lunn <andrew@lunn.ch>
Signed-off-by: David S. Miller <davem@davemloft.net>
这个提交包含在:
Andrew Lunn
2018-05-05 20:58:22 +02:00
提交者 David S. Miller
父节点 98f0a39529
当前提交 9255bacd57
修改 3 个文件,包含 28 行新增1 行删除

查看文件

@@ -1118,7 +1118,7 @@ int mv88e6xxx_g2_irq_mdio_setup(struct mv88e6xxx_chip *chip,
err = irq;
goto out;
}
bus->irq[chip->info->port_base_addr + phy] = irq;
bus->irq[chip->info->phy_base_addr + phy] = irq;
}
return 0;
out: