diff options
author | Jeff Garzik <jeff@garzik.org> | 2008-06-27 02:20:20 -0400 |
---|---|---|
committer | Jeff Garzik <jgarzik@redhat.com> | 2008-06-28 10:23:38 -0400 |
commit | be0976be9148f31ee0d1997354c3e30ff8d07587 (patch) | |
tree | 18792bffd7130b7c3894c64992f60e388e111141 /drivers/net | |
parent | 28cd4289abc2c8db90344ee4ff064a9bdf086fdf (diff) |
[netdrvr] kill sync_irq-before-freq_irq pattern
synchronize_irq() is superfluous when free_irq() call immediately follows it,
because free_irq() also does a synchronize_irq() call of its own.
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
Diffstat (limited to 'drivers/net')
-rw-r--r-- | drivers/net/8139cp.c | 1 | ||||
-rw-r--r-- | drivers/net/8139too.c | 1 | ||||
-rw-r--r-- | drivers/net/dl2k.c | 2 | ||||
-rw-r--r-- | drivers/net/pci-skeleton.c | 1 | ||||
-rw-r--r-- | drivers/net/tsi108_eth.c | 1 | ||||
-rw-r--r-- | drivers/net/typhoon.c | 3 |
6 files changed, 1 insertions, 8 deletions
diff --git a/drivers/net/8139cp.c b/drivers/net/8139cp.c index 934db350e339..6011d6fabef0 100644 --- a/drivers/net/8139cp.c +++ b/drivers/net/8139cp.c | |||
@@ -1213,7 +1213,6 @@ static int cp_close (struct net_device *dev) | |||
1213 | 1213 | ||
1214 | spin_unlock_irqrestore(&cp->lock, flags); | 1214 | spin_unlock_irqrestore(&cp->lock, flags); |
1215 | 1215 | ||
1216 | synchronize_irq(dev->irq); | ||
1217 | free_irq(dev->irq, dev); | 1216 | free_irq(dev->irq, dev); |
1218 | 1217 | ||
1219 | cp_free_rings(cp); | 1218 | cp_free_rings(cp); |
diff --git a/drivers/net/8139too.c b/drivers/net/8139too.c index 0cd8e258f882..75317a14ad1c 100644 --- a/drivers/net/8139too.c +++ b/drivers/net/8139too.c | |||
@@ -2231,7 +2231,6 @@ static int rtl8139_close (struct net_device *dev) | |||
2231 | 2231 | ||
2232 | spin_unlock_irqrestore (&tp->lock, flags); | 2232 | spin_unlock_irqrestore (&tp->lock, flags); |
2233 | 2233 | ||
2234 | synchronize_irq (dev->irq); /* racy, but that's ok here */ | ||
2235 | free_irq (dev->irq, dev); | 2234 | free_irq (dev->irq, dev); |
2236 | 2235 | ||
2237 | rtl8139_tx_clear (tp); | 2236 | rtl8139_tx_clear (tp); |
diff --git a/drivers/net/dl2k.c b/drivers/net/dl2k.c index 8277e89e552d..f8037110a522 100644 --- a/drivers/net/dl2k.c +++ b/drivers/net/dl2k.c | |||
@@ -1753,7 +1753,7 @@ rio_close (struct net_device *dev) | |||
1753 | 1753 | ||
1754 | /* Stop Tx and Rx logics */ | 1754 | /* Stop Tx and Rx logics */ |
1755 | writel (TxDisable | RxDisable | StatsDisable, ioaddr + MACCtrl); | 1755 | writel (TxDisable | RxDisable | StatsDisable, ioaddr + MACCtrl); |
1756 | synchronize_irq (dev->irq); | 1756 | |
1757 | free_irq (dev->irq, dev); | 1757 | free_irq (dev->irq, dev); |
1758 | del_timer_sync (&np->timer); | 1758 | del_timer_sync (&np->timer); |
1759 | 1759 | ||
diff --git a/drivers/net/pci-skeleton.c b/drivers/net/pci-skeleton.c index fffc49befe04..53451c3b2c0d 100644 --- a/drivers/net/pci-skeleton.c +++ b/drivers/net/pci-skeleton.c | |||
@@ -1739,7 +1739,6 @@ static int netdrv_close (struct net_device *dev) | |||
1739 | 1739 | ||
1740 | spin_unlock_irqrestore (&tp->lock, flags); | 1740 | spin_unlock_irqrestore (&tp->lock, flags); |
1741 | 1741 | ||
1742 | synchronize_irq (dev->irq); | ||
1743 | free_irq (dev->irq, dev); | 1742 | free_irq (dev->irq, dev); |
1744 | 1743 | ||
1745 | netdrv_tx_clear (dev); | 1744 | netdrv_tx_clear (dev); |
diff --git a/drivers/net/tsi108_eth.c b/drivers/net/tsi108_eth.c index febfaee44fe9..43fde99b24ac 100644 --- a/drivers/net/tsi108_eth.c +++ b/drivers/net/tsi108_eth.c | |||
@@ -1437,7 +1437,6 @@ static int tsi108_close(struct net_device *dev) | |||
1437 | dev_kfree_skb(skb); | 1437 | dev_kfree_skb(skb); |
1438 | } | 1438 | } |
1439 | 1439 | ||
1440 | synchronize_irq(data->irq_num); | ||
1441 | free_irq(data->irq_num, dev); | 1440 | free_irq(data->irq_num, dev); |
1442 | 1441 | ||
1443 | /* Discard the RX ring. */ | 1442 | /* Discard the RX ring. */ |
diff --git a/drivers/net/typhoon.c b/drivers/net/typhoon.c index c0dd25ba7a18..8549f1159a30 100644 --- a/drivers/net/typhoon.c +++ b/drivers/net/typhoon.c | |||
@@ -334,8 +334,6 @@ enum state_values { | |||
334 | #define TYPHOON_RESET_TIMEOUT_NOSLEEP ((6 * 1000000) / TYPHOON_UDELAY) | 334 | #define TYPHOON_RESET_TIMEOUT_NOSLEEP ((6 * 1000000) / TYPHOON_UDELAY) |
335 | #define TYPHOON_WAIT_TIMEOUT ((1000000 / 2) / TYPHOON_UDELAY) | 335 | #define TYPHOON_WAIT_TIMEOUT ((1000000 / 2) / TYPHOON_UDELAY) |
336 | 336 | ||
337 | #define typhoon_synchronize_irq(x) synchronize_irq(x) | ||
338 | |||
339 | #if defined(NETIF_F_TSO) | 337 | #if defined(NETIF_F_TSO) |
340 | #define skb_tso_size(x) (skb_shinfo(x)->gso_size) | 338 | #define skb_tso_size(x) (skb_shinfo(x)->gso_size) |
341 | #define TSO_NUM_DESCRIPTORS 2 | 339 | #define TSO_NUM_DESCRIPTORS 2 |
@@ -2143,7 +2141,6 @@ typhoon_close(struct net_device *dev) | |||
2143 | printk(KERN_ERR "%s: unable to stop runtime\n", dev->name); | 2141 | printk(KERN_ERR "%s: unable to stop runtime\n", dev->name); |
2144 | 2142 | ||
2145 | /* Make sure there is no irq handler running on a different CPU. */ | 2143 | /* Make sure there is no irq handler running on a different CPU. */ |
2146 | typhoon_synchronize_irq(dev->irq); | ||
2147 | free_irq(dev->irq, dev); | 2144 | free_irq(dev->irq, dev); |
2148 | 2145 | ||
2149 | typhoon_free_rx_rings(tp); | 2146 | typhoon_free_rx_rings(tp); |