diff options
author | Nimrod Andy <B38611@freescale.com> | 2014-12-11 04:20:33 +0300 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2014-12-11 07:37:01 +0300 |
commit | 0c5a3aef9ffc8a7a6fb74be6d87e066b5424f8c3 (patch) | |
tree | 4a549a98368a3f9baa6e552dc3072b4da535c070 /drivers | |
parent | e17f7fecddd4b6a5a6b0758fc0301e9233d3ae78 (diff) | |
download | linux-0c5a3aef9ffc8a7a6fb74be6d87e066b5424f8c3.tar.xz |
net: fec: only enable mdio interrupt before phy device link up
Before phy device link up, we only enable FEC mdio interrupt, which
is more reasonable.
Signed-off-by: Fugang Duan <B38611@freescale.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/net/ethernet/freescale/fec_main.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/drivers/net/ethernet/freescale/fec_main.c b/drivers/net/ethernet/freescale/fec_main.c index 85c955e4383f..8c5b15ee5ed7 100644 --- a/drivers/net/ethernet/freescale/fec_main.c +++ b/drivers/net/ethernet/freescale/fec_main.c @@ -1075,7 +1075,10 @@ fec_restart(struct net_device *ndev) fec_ptp_start_cyclecounter(ndev); /* Enable interrupts we wish to service */ - writel(FEC_DEFAULT_IMASK, fep->hwp + FEC_IMASK); + if (fep->link) + writel(FEC_DEFAULT_IMASK, fep->hwp + FEC_IMASK); + else + writel(FEC_ENET_MII, fep->hwp + FEC_IMASK); /* Init the interrupt coalescing */ fec_enet_itr_coal_init(ndev); |