Merge tag 'mvebu-fixes-3.18' of git://git.infradead.org/linux-mvebu into fixes
[firefly-linux-kernel-4.4.55.git] / net / dsa / slave.c
index 8030489d9cbe84f73cfd5ebbae82f60383f707b1..6d1817449c3675bb4ddd6d47a16ea017a5213e0d 100644 (file)
@@ -11,6 +11,7 @@
 #include <linux/list.h>
 #include <linux/etherdevice.h>
 #include <linux/phy.h>
+#include <linux/phy_fixed.h>
 #include <linux/of_net.h>
 #include <linux/of_mdio.h>
 #include "dsa_priv.h"
@@ -598,7 +599,7 @@ dsa_slave_create(struct dsa_switch *ds, struct device *parent,
        netif_carrier_off(slave_dev);
 
        if (p->phy != NULL) {
-               if (ds->drv->get_phy_flags(ds, port))
+               if (ds->drv->get_phy_flags)
                        p->phy->dev_flags |= ds->drv->get_phy_flags(ds, port);
 
                phy_attach(slave_dev, dev_name(&p->phy->dev),