]> git.kernelconcepts.de Git - karo-tx-linux.git/commitdiff
net: fec: reset PHY in the probe() function rather when opening the net device
authorLothar Waßmann <LW@KARO-electronics.de>
Mon, 16 Jun 2014 10:28:23 +0000 (12:28 +0200)
committerLothar Waßmann <LW@KARO-electronics.de>
Mon, 16 Jun 2014 16:11:53 +0000 (18:11 +0200)
This fixes an intermittent failure to detect the PHY.

drivers/net/ethernet/freescale/fec_main.c

index 543c92a6f0259d9c881488902e1f6eeb088aa42f..27f0bb62c27ff9d7cea5a4a6e3571c4a75493272 100644 (file)
@@ -2165,9 +2165,6 @@ fec_enet_open(struct net_device *ndev)
        netif_start_queue(ndev);
        fep->opened = 1;
 
-       /* reset phy */
-       fec_reset_phy(fep->pdev);
-
        return 0;
 }
 
@@ -2604,6 +2601,8 @@ fec_probe(struct platform_device *pdev)
                fep->reg_phy = NULL;
        }
 
+       fec_reset_phy(pdev);
+
        if (fep->bufdesc_ex)
                fec_ptp_init(pdev);