Merge branch 'for_linus' of master.kernel.org:/pub/scm/linux/kernel/git/galak/powerpc
[sfrench/cifs-2.6.git] / drivers / net / phy / mdio_bus.c
index fc4aee96cdfd87757d35786d19ddbd6211d1f8be..fc2f0e695a13a572a2309003243afe3ca685c6b1 100644 (file)
@@ -131,7 +131,8 @@ static int mdio_bus_match(struct device *dev, struct device_driver *drv)
        struct phy_device *phydev = to_phy_device(dev);
        struct phy_driver *phydrv = to_phy_driver(drv);
 
-       return (phydrv->phy_id == (phydev->phy_id & phydrv->phy_id_mask));
+       return ((phydrv->phy_id & phydrv->phy_id_mask) ==
+               (phydev->phy_id & phydrv->phy_id_mask));
 }
 
 /* Suspend and resume.  Copied from platform_suspend and