aboutsummaryrefslogtreecommitdiffstats
path: root/target
diff options
context:
space:
mode:
authorGabor Juhos <juhosg@openwrt.org>2012-02-15 13:47:52 +0000
committerGabor Juhos <juhosg@openwrt.org>2012-02-15 13:47:52 +0000
commitc51e57d97299ed29c5fd2a825f04c86fda2c90b4 (patch)
tree4f210b7cf2973f173c5858248f1c34100bfbaf21 /target
parent846b753561da1a9598a1f34a92ac28dd46b41ae4 (diff)
downloadupstream-c51e57d97299ed29c5fd2a825f04c86fda2c90b4.tar.gz
upstream-c51e57d97299ed29c5fd2a825f04c86fda2c90b4.tar.bz2
upstream-c51e57d97299ed29c5fd2a825f04c86fda2c90b4.zip
ramips: raeth: force link down in ramips_phy_stop
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@30550 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'target')
-rw-r--r--target/linux/ramips/files/drivers/net/ramips.c13
1 files changed, 6 insertions, 7 deletions
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