diff options
author | Ingo Molnar <mingo@elte.hu> | 2008-07-11 04:46:50 -0400 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2008-07-11 04:46:50 -0400 |
commit | 0c81b2a1448bc6a2a9b2d6469fb0669fb4b25e5b (patch) | |
tree | 6f82579cae6d6e39fa9f837a3c349ded51e19d14 /drivers/net/forcedeth.c | |
parent | 0729fbf3bc70870370b4f43d652f05a468dc68b8 (diff) | |
parent | 70ff05554f91a1edda1f11684da1dbde09e2feea (diff) |
Merge branch 'linus' into core/rcu
Conflicts:
include/linux/rculist.h
kernel/rcupreempt.c
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'drivers/net/forcedeth.c')
-rw-r--r-- | drivers/net/forcedeth.c | 15 |
1 files changed, 13 insertions, 2 deletions
diff --git a/drivers/net/forcedeth.c b/drivers/net/forcedeth.c index 2cb244763292..20d4fe96a81c 100644 --- a/drivers/net/forcedeth.c +++ b/drivers/net/forcedeth.c | |||
@@ -4194,12 +4194,23 @@ static int nv_set_settings(struct net_device *dev, struct ethtool_cmd *ecmd) | |||
4194 | 4194 | ||
4195 | netif_carrier_off(dev); | 4195 | netif_carrier_off(dev); |
4196 | if (netif_running(dev)) { | 4196 | if (netif_running(dev)) { |
4197 | unsigned long flags; | ||
4198 | |||
4197 | nv_disable_irq(dev); | 4199 | nv_disable_irq(dev); |
4198 | netif_tx_lock_bh(dev); | 4200 | netif_tx_lock_bh(dev); |
4199 | spin_lock(&np->lock); | 4201 | /* with plain spinlock lockdep complains */ |
4202 | spin_lock_irqsave(&np->lock, flags); | ||
4200 | /* stop engines */ | 4203 | /* stop engines */ |
4204 | /* FIXME: | ||
4205 | * this can take some time, and interrupts are disabled | ||
4206 | * due to spin_lock_irqsave, but let's hope no daemon | ||
4207 | * is going to change the settings very often... | ||
4208 | * Worst case: | ||
4209 | * NV_RXSTOP_DELAY1MAX + NV_TXSTOP_DELAY1MAX | ||
4210 | * + some minor delays, which is up to a second approximately | ||
4211 | */ | ||
4201 | nv_stop_rxtx(dev); | 4212 | nv_stop_rxtx(dev); |
4202 | spin_unlock(&np->lock); | 4213 | spin_unlock_irqrestore(&np->lock, flags); |
4203 | netif_tx_unlock_bh(dev); | 4214 | netif_tx_unlock_bh(dev); |
4204 | } | 4215 | } |
4205 | 4216 | ||