net: dm9k: show only one phy on miibus
PATCH 1/1 net: dm9k: show only one phy on miibus
Signed-off-by Antony Pavlov <[email protected]>
--- drivers/net/dm9k.c | 9 +++++++++ 1 file changed, 9 insertions(+)
drivers/net/dm9k.c +9 -0
@@ -359,6 +359,11 @@ static int dm9k_phy_read(struct mii_bus *bus, int addr, int reg)struct dm9k *priv = bus->priv;struct device_d *dev = &bus->dev; +/* Show only one phy on miibus */ +if (addr !=0 ) { +return 0xffff ; + } +/* Fill the phyxcer register into REG_0C */ dm9k_iow (priv,DM9K_EPAR ,DM9K_PHY | reg);dm9k_iow (priv,DM9K_EPCR ,0xc );/* Issue phyxcer read command */
@@ -378,6 +383,10 @@ static int dm9k_phy_write(struct mii_bus *bus, int addr, int reg, u16 val)struct dm9k *priv = bus->priv;struct device_d *dev = &bus->dev; +if (addr !=0 ) { +return 0 ; + } +/* Fill the phyxcer register into REG_0C */ dm9k_iow (priv,DM9K_EPAR ,DM9K_PHY | reg);
Signature · 7 lines
2.1.0 _______________________________________________ barebox mailing list [email protected] http://lists.infradead.org/mailman/listinfo/barebox
Quoted 10 lines · Antony Pavlov
Signed-off-by Antony Pavlov <[email protected]>--- drivers/net/dm9k.c | 9 +++++++++ 1 file changed, 9 insertions(+)drivers/net/dm9k.c +0
-0
drivers/net/dm9k.c static int dm9k_phy_read(struct mii_bus *bus, int addr, int reg) · line 365
Quoted 7 lines
drivers/net/dm9k.c +4
-0@@ -359,6 +359,11 @@ static int dm9k_phy_read(struct mii_bus *bus, int addr, int reg)struct dm9k *priv = bus->priv;struct device_d *dev = &bus->dev; +/* Show only one phy on miibus */ +if (addr !=0 ) { +return 0xffff ; + }
In the datasheet I can see that the dm9000 has an internal phy but also supports an external phy. The above seems true for the internal, but what about the external? Is support for this missing anyway since I can't find any references in the code?
Sascha
Signature · 9 lines
Pengutronix e.K. | | Industrial Linux Solutions | http://www.pengutronix.de/ | Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 | Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 | _______________________________________________ barebox mailing list [email protected] http://lists.infradead.org/mailman/listinfo/barebox