提交 0220ff7f 编写于 作者: S Stefan Weil 提交者: David S. Miller

cpmac: prevent fatal exception in cpmac_end_xmit

We should not be stopping the subqueues in cpmac_end_xmit
but rather test the status of them. Replace the calls to
netif_subqueue_stop by __netif_subqueue_stopped. This
fixes an unrecoverable exception from happening when
running the driver.
Signed-off-by: NStefan Weil <weil@mail.berlios.de>
Signed-off-by: NFlorian Fainelli <florian@openwrt.org>
Signed-off-by: NDavid S. Miller <davem@davemloft.net>
上级 69bd4ae5
...@@ -615,13 +615,13 @@ static void cpmac_end_xmit(struct net_device *dev, int queue) ...@@ -615,13 +615,13 @@ static void cpmac_end_xmit(struct net_device *dev, int queue)
dev_kfree_skb_irq(desc->skb); dev_kfree_skb_irq(desc->skb);
desc->skb = NULL; desc->skb = NULL;
if (netif_subqueue_stopped(dev, queue)) if (__netif_subqueue_stopped(dev, queue))
netif_wake_subqueue(dev, queue); netif_wake_subqueue(dev, queue);
} else { } else {
if (netif_msg_tx_err(priv) && net_ratelimit()) if (netif_msg_tx_err(priv) && net_ratelimit())
printk(KERN_WARNING printk(KERN_WARNING
"%s: end_xmit: spurious interrupt\n", dev->name); "%s: end_xmit: spurious interrupt\n", dev->name);
if (netif_subqueue_stopped(dev, queue)) if (__netif_subqueue_stopped(dev, queue))
netif_wake_subqueue(dev, queue); netif_wake_subqueue(dev, queue);
} }
} }
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册