From: Gabor Juhos Date: Wed, 15 Feb 2012 13:47:52 +0000 (+0000) Subject: ramips: raeth: force link down in ramips_phy_stop X-Git-Tag: attitude_adjustment_12.09~2346 X-Git-Url: http://git.lede-project.org./?a=commitdiff_plain;h=b3b79365f3d244392e4fa43118f1b6063a2182ac;p=openwrt%2Fsvn-archive%2Fopenwrt.git ramips: raeth: force link down in ramips_phy_stop SVN-Revision: 30550 --- diff --git a/target/linux/ramips/files/drivers/net/ramips.c b/target/linux/ramips/files/drivers/net/ramips.c index 9f76779af4..6fa115135d 100644 --- a/target/linux/ramips/files/drivers/net/ramips.c +++ b/target/linux/ramips/files/drivers/net/ramips.c @@ -424,14 +424,13 @@ ramips_phy_stop(struct raeth_priv *re) { unsigned long flags; - if (re->phy_dev) { + if (re->phy_dev) phy_stop(re->phy_dev); - } else { - spin_lock_irqsave(&re->phy_lock, flags); - re->link = 0; - ramips_link_adjust(re); - spin_unlock_irqrestore(&re->phy_lock, flags); - } + + spin_lock_irqsave(&re->phy_lock, flags); + re->link = 0; + ramips_link_adjust(re); + spin_unlock_irqrestore(&re->phy_lock, flags); } #else static inline int