[PATCH] skge: resolve tx multiqueue bug

Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
From: Wang Chen
Date: Wednesday, July 23, 2008 - 1:50 am

Markus Trippelsdorf said the following on 2008-7-23 13:40:

Markus, please try this.

- Add netif_start_queue() in ->open()
- netif_carrier_*() is enough, remove netif_*_queue()

Signed-off-by: Wang Chen <wangchen@cn.fujitsu.com>
---
diff --git a/drivers/net/skge.c b/drivers/net/skge.c
index 2e26dce..7507585 100644
--- a/drivers/net/skge.c
+++ b/drivers/net/skge.c
@@ -1069,7 +1069,6 @@ static void skge_link_up(struct skge_port *skge)
 		    LED_BLK_OFF|LED_SYNC_OFF|LED_ON);
 
 	netif_carrier_on(skge->netdev);
-	netif_wake_queue(skge->netdev);
 
 	if (netif_msg_link(skge)) {
 		printk(KERN_INFO PFX
@@ -1084,7 +1083,6 @@ static void skge_link_down(struct skge_port *skge)
 {
 	skge_write8(skge->hw, SK_REG(skge->port, LNK_LED_REG), LED_OFF);
 	netif_carrier_off(skge->netdev);
-	netif_stop_queue(skge->netdev);
 
 	if (netif_msg_link(skge))
 		printk(KERN_INFO PFX "%s: Link is down.\n", skge->netdev->name);
@@ -2450,7 +2448,6 @@ static void skge_phy_reset(struct skge_port *skge)
 	int port = skge->port;
 	struct net_device *dev = hw->dev[port];
 
-	netif_stop_queue(skge->netdev);
 	netif_carrier_off(skge->netdev);
 
 	spin_lock_bh(&hw->phy_lock);
@@ -2640,6 +2637,7 @@ static int skge_up(struct net_device *dev)
 	spin_unlock_irq(&hw->hw_lock);
 
 	napi_enable(&skge->napi);
+	netif_start_queue(dev);
 	return 0;
 
  free_rx_ring:
@@ -3863,7 +3861,6 @@ static struct net_device *skge_devinit(struct skge_hw *hw, int port,
 
 	/* device is off until link detection */
 	netif_carrier_off(dev);
-	netif_stop_queue(dev);
 
 	return dev;
 }

--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
Re: [BUG] kernel BUG at net/core/dev.c:1328!, David Miller, (Mon Jul 21, 9:20 am)
Re: [BUG] kernel BUG at net/core/dev.c:1328!, Alessandro Guido, (Tue Jul 22, 2:54 am)
Re: [BUG] kernel BUG at net/core/dev.c:1328!, Alessandro Suardi, (Tue Jul 22, 1:18 pm)
Re: [BUG] kernel BUG at net/core/dev.c:1328!, David Miller, (Tue Jul 22, 3:56 pm)
Re: WARNING: at net/core/dev.c:1328!, Markus Trippelsdorf, (Tue Jul 22, 10:40 pm)
Re: [BUG] kernel BUG at net/core/dev.c:1328!, Alessandro Guido, (Wed Jul 23, 12:57 am)
[PATCH] skge: resolve tx multiqueue bug, Wang Chen, (Wed Jul 23, 1:50 am)
Re: [PATCH] skge: resolve tx multiqueue bug, Markus Trippelsdorf, (Wed Jul 23, 3:18 am)
Re: [BUG] kernel BUG at net/core/dev.c:1328!, Alessandro Suardi, (Wed Jul 23, 6:16 am)
Re: [PATCH] skge: resolve tx multiqueue bug, Markus Trippelsdorf, (Wed Jul 23, 7:03 am)
Re: [PATCH] skge: resolve tx multiqueue bug, Wang Chen, (Wed Jul 23, 8:21 am)
Re: [PATCH] skge: resolve tx multiqueue bug, David Miller, (Wed Jul 23, 3:30 pm)
Re: [PATCH] skge: resolve tx multiqueue bug, Wang Chen, (Wed Jul 23, 6:01 pm)
Re: [PATCH] skge: resolve tx multiqueue bug, Markus Trippelsdorf, (Wed Jul 23, 11:18 pm)