aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/forcedeth.c
diff options
context:
space:
mode:
authorDavid S. Miller <davem@davemloft.net>2008-07-06 02:08:07 -0400
committerDavid S. Miller <davem@davemloft.net>2008-07-06 02:08:07 -0400
commitea2aca084ba82aaf7c148d04914ceed8758ce08a (patch)
treedcb3f4f849cf48deac2dd3bafd5c2cd2f0e7dc79 /drivers/net/forcedeth.c
parentf3032be921cd126615ce3bfd7084e3d319f3f892 (diff)
parentc5a78ac00c400df29645e59938700301efb371d0 (diff)
Merge branch 'master' of master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6
Conflicts: Documentation/feature-removal-schedule.txt drivers/net/wan/hdlc_fr.c drivers/net/wireless/iwlwifi/iwl-4965.c drivers/net/wireless/iwlwifi/iwl3945-base.c
Diffstat (limited to 'drivers/net/forcedeth.c')
-rw-r--r--drivers/net/forcedeth.c15
1 files changed, 13 insertions, 2 deletions
diff --git a/drivers/net/forcedeth.c b/drivers/net/forcedeth.c
index afd063fe11af..786d668c612e 100644
--- a/drivers/net/forcedeth.c
+++ b/drivers/net/forcedeth.c
@@ -4198,12 +4198,23 @@ static int nv_set_settings(struct net_device *dev, struct ethtool_cmd *ecmd)
4198 4198
4199 netif_carrier_off(dev); 4199 netif_carrier_off(dev);
4200 if (netif_running(dev)) { 4200 if (netif_running(dev)) {
4201 unsigned long flags;
4202
4201 nv_disable_irq(dev); 4203 nv_disable_irq(dev);
4202 netif_tx_lock_bh(dev); 4204 netif_tx_lock_bh(dev);
4203 spin_lock(&np->lock); 4205 /* with plain spinlock lockdep complains */
4206 spin_lock_irqsave(&np->lock, flags);
4204 /* stop engines */ 4207 /* stop engines */
4208 /* FIXME:
4209 * this can take some time, and interrupts are disabled
4210 * due to spin_lock_irqsave, but let's hope no daemon
4211 * is going to change the settings very often...
4212 * Worst case:
4213 * NV_RXSTOP_DELAY1MAX + NV_TXSTOP_DELAY1MAX
4214 * + some minor delays, which is up to a second approximately
4215 */
4205 nv_stop_rxtx(dev); 4216 nv_stop_rxtx(dev);
4206 spin_unlock(&np->lock); 4217 spin_unlock_irqrestore(&np->lock, flags);
4207 netif_tx_unlock_bh(dev); 4218 netif_tx_unlock_bh(dev);
4208 } 4219 }
4209 4220