diff options
Diffstat (limited to 'drivers/net/sb1250-mac.c')
-rw-r--r-- | drivers/net/sb1250-mac.c | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/drivers/net/sb1250-mac.c b/drivers/net/sb1250-mac.c index fe41e4ec21ec..ce10cfa1ee53 100644 --- a/drivers/net/sb1250-mac.c +++ b/drivers/net/sb1250-mac.c | |||
@@ -2069,9 +2069,10 @@ static irqreturn_t sbmac_intr(int irq,void *dev_instance) | |||
2069 | static int sbmac_start_tx(struct sk_buff *skb, struct net_device *dev) | 2069 | static int sbmac_start_tx(struct sk_buff *skb, struct net_device *dev) |
2070 | { | 2070 | { |
2071 | struct sbmac_softc *sc = netdev_priv(dev); | 2071 | struct sbmac_softc *sc = netdev_priv(dev); |
2072 | unsigned long flags; | ||
2072 | 2073 | ||
2073 | /* lock eth irq */ | 2074 | /* lock eth irq */ |
2074 | spin_lock_irq (&sc->sbm_lock); | 2075 | spin_lock_irqsave(&sc->sbm_lock, flags); |
2075 | 2076 | ||
2076 | /* | 2077 | /* |
2077 | * Put the buffer on the transmit ring. If we | 2078 | * Put the buffer on the transmit ring. If we |
@@ -2081,14 +2082,14 @@ static int sbmac_start_tx(struct sk_buff *skb, struct net_device *dev) | |||
2081 | if (sbdma_add_txbuffer(&(sc->sbm_txdma),skb)) { | 2082 | if (sbdma_add_txbuffer(&(sc->sbm_txdma),skb)) { |
2082 | /* XXX save skb that we could not send */ | 2083 | /* XXX save skb that we could not send */ |
2083 | netif_stop_queue(dev); | 2084 | netif_stop_queue(dev); |
2084 | spin_unlock_irq(&sc->sbm_lock); | 2085 | spin_unlock_irqrestore(&sc->sbm_lock, flags); |
2085 | 2086 | ||
2086 | return 1; | 2087 | return 1; |
2087 | } | 2088 | } |
2088 | 2089 | ||
2089 | dev->trans_start = jiffies; | 2090 | dev->trans_start = jiffies; |
2090 | 2091 | ||
2091 | spin_unlock_irq (&sc->sbm_lock); | 2092 | spin_unlock_irqrestore(&sc->sbm_lock, flags); |
2092 | 2093 | ||
2093 | return 0; | 2094 | return 0; |
2094 | } | 2095 | } |
@@ -2568,14 +2569,15 @@ static void sbmac_mii_poll(struct net_device *dev) | |||
2568 | static void sbmac_tx_timeout (struct net_device *dev) | 2569 | static void sbmac_tx_timeout (struct net_device *dev) |
2569 | { | 2570 | { |
2570 | struct sbmac_softc *sc = netdev_priv(dev); | 2571 | struct sbmac_softc *sc = netdev_priv(dev); |
2572 | unsigned long flags; | ||
2571 | 2573 | ||
2572 | spin_lock_irq (&sc->sbm_lock); | 2574 | spin_lock_irqsave(&sc->sbm_lock, flags); |
2573 | 2575 | ||
2574 | 2576 | ||
2575 | dev->trans_start = jiffies; | 2577 | dev->trans_start = jiffies; |
2576 | dev->stats.tx_errors++; | 2578 | dev->stats.tx_errors++; |
2577 | 2579 | ||
2578 | spin_unlock_irq (&sc->sbm_lock); | 2580 | spin_unlock_irqrestore(&sc->sbm_lock, flags); |
2579 | 2581 | ||
2580 | printk (KERN_WARNING "%s: Transmit timed out\n",dev->name); | 2582 | printk (KERN_WARNING "%s: Transmit timed out\n",dev->name); |
2581 | } | 2583 | } |