fsl_pq_mdio: Revive UCC MDIO support
authorAnton Vorontsov <avorontsov@ru.mvista.com>
Tue, 31 Mar 2009 08:33:52 +0000 (08:33 +0000)
committerDavid S. Miller <davem@davemloft.net>
Thu, 2 Apr 2009 08:28:00 +0000 (01:28 -0700)
commit 1577ecef766650a57fceb171acee2b13cbfaf1d3 ("netdev: Merge UCC
and gianfar MDIO bus drivers") introduced a regression so that UCC
MDIO buses no longer work.

This is because fsl_pq_mdio driver wrongly masks all non-TBI PHYs
for !fsl,gianfar-mdio buses, while it should do that only for
fsl,gianfar-tbi buses.

Signed-off-by: Anton Vorontsov <avorontsov@ru.mvista.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/fsl_pq_mdio.c

index b3079a5a7f2bda4929d4a68a56ac326a11b250c7..d9e1ecfbf3607c18d8a4d3dcfa01aa0d26a0e192 100644 (file)
@@ -387,7 +387,7 @@ static int fsl_pq_mdio_probe(struct of_device *ofdev,
         * The TBIPHY-only buses will find PHYs at every address,
         * so we mask them all but the TBI
         */
-       if (!of_device_is_compatible(np, "fsl,gianfar-mdio"))
+       if (of_device_is_compatible(np, "fsl,gianfar-tbi"))
                new_bus->phy_mask = ~(1 << tbiaddr);
 
        err = mdiobus_register(new_bus);