]> err.no Git - linux-2.6/blobdiff - drivers/net/phy/mdio_bus.c
FIXED_PHY must depend on PHYLIB=y
[linux-2.6] / drivers / net / phy / mdio_bus.c
index 6e9f619c491f74837a7f356943683094169e28bf..963630c65ca940d9dfc59ed57370c54dbfed7847 100644 (file)
@@ -49,13 +49,13 @@ int mdiobus_register(struct mii_bus *bus)
        int i;
        int err = 0;
 
-       mutex_init(&bus->mdio_lock);
-
        if (NULL == bus || NULL == bus->name ||
                        NULL == bus->read ||
                        NULL == bus->write)
                return -EINVAL;
 
+       mutex_init(&bus->mdio_lock);
+
        if (bus->reset)
                bus->reset(bus);