diff options
Diffstat (limited to 'drivers/net/ethernet/freescale/gianfar_ethtool.c')
-rw-r--r-- | drivers/net/ethernet/freescale/gianfar_ethtool.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/net/ethernet/freescale/gianfar_ethtool.c b/drivers/net/ethernet/freescale/gianfar_ethtool.c index 891dbee6e6c1..76d70708f864 100644 --- a/drivers/net/ethernet/freescale/gianfar_ethtool.c +++ b/drivers/net/ethernet/freescale/gianfar_ethtool.c | |||
@@ -533,6 +533,9 @@ static int gfar_spauseparam(struct net_device *dev, | |||
533 | struct gfar __iomem *regs = priv->gfargrp[0].regs; | 533 | struct gfar __iomem *regs = priv->gfargrp[0].regs; |
534 | u32 oldadv, newadv; | 534 | u32 oldadv, newadv; |
535 | 535 | ||
536 | if (!phydev) | ||
537 | return -ENODEV; | ||
538 | |||
536 | if (!(phydev->supported & SUPPORTED_Pause) || | 539 | if (!(phydev->supported & SUPPORTED_Pause) || |
537 | (!(phydev->supported & SUPPORTED_Asym_Pause) && | 540 | (!(phydev->supported & SUPPORTED_Asym_Pause) && |
538 | (epause->rx_pause != epause->tx_pause))) | 541 | (epause->rx_pause != epause->tx_pause))) |