aboutsummaryrefslogtreecommitdiffstats
path: root/net/core/netpoll.c
diff options
context:
space:
mode:
Diffstat (limited to 'net/core/netpoll.c')
-rw-r--r--net/core/netpoll.c12
1 files changed, 7 insertions, 5 deletions
diff --git a/net/core/netpoll.c b/net/core/netpoll.c
index cf64c1ffa4cd..556b08298669 100644
--- a/net/core/netpoll.c
+++ b/net/core/netpoll.c
@@ -76,7 +76,7 @@ static void queue_process(struct work_struct *work)
76 76
77 local_irq_save(flags); 77 local_irq_save(flags);
78 __netif_tx_lock(txq, smp_processor_id()); 78 __netif_tx_lock(txq, smp_processor_id());
79 if (netif_tx_queue_frozen_or_stopped(txq) || 79 if (netif_xmit_frozen_or_stopped(txq) ||
80 ops->ndo_start_xmit(skb, dev) != NETDEV_TX_OK) { 80 ops->ndo_start_xmit(skb, dev) != NETDEV_TX_OK) {
81 skb_queue_head(&npinfo->txq, skb); 81 skb_queue_head(&npinfo->txq, skb);
82 __netif_tx_unlock(txq); 82 __netif_tx_unlock(txq);
@@ -317,7 +317,7 @@ void netpoll_send_skb_on_dev(struct netpoll *np, struct sk_buff *skb,
317 for (tries = jiffies_to_usecs(1)/USEC_PER_POLL; 317 for (tries = jiffies_to_usecs(1)/USEC_PER_POLL;
318 tries > 0; --tries) { 318 tries > 0; --tries) {
319 if (__netif_tx_trylock(txq)) { 319 if (__netif_tx_trylock(txq)) {
320 if (!netif_tx_queue_stopped(txq)) { 320 if (!netif_xmit_stopped(txq)) {
321 status = ops->ndo_start_xmit(skb, dev); 321 status = ops->ndo_start_xmit(skb, dev);
322 if (status == NETDEV_TX_OK) 322 if (status == NETDEV_TX_OK)
323 txq_trans_update(txq); 323 txq_trans_update(txq);
@@ -422,6 +422,7 @@ static void arp_reply(struct sk_buff *skb)
422 struct sk_buff *send_skb; 422 struct sk_buff *send_skb;
423 struct netpoll *np, *tmp; 423 struct netpoll *np, *tmp;
424 unsigned long flags; 424 unsigned long flags;
425 int hlen, tlen;
425 int hits = 0; 426 int hits = 0;
426 427
427 if (list_empty(&npinfo->rx_np)) 428 if (list_empty(&npinfo->rx_np))
@@ -479,8 +480,9 @@ static void arp_reply(struct sk_buff *skb)
479 if (tip != np->local_ip) 480 if (tip != np->local_ip)
480 continue; 481 continue;
481 482
482 send_skb = find_skb(np, size + LL_ALLOCATED_SPACE(np->dev), 483 hlen = LL_RESERVED_SPACE(np->dev);
483 LL_RESERVED_SPACE(np->dev)); 484 tlen = np->dev->needed_tailroom;
485 send_skb = find_skb(np, size + hlen + tlen, hlen);
484 if (!send_skb) 486 if (!send_skb)
485 continue; 487 continue;
486 488
@@ -763,7 +765,7 @@ int __netpoll_setup(struct netpoll *np)
763 } 765 }
764 766
765 /* last thing to do is link it to the net device structure */ 767 /* last thing to do is link it to the net device structure */
766 RCU_INIT_POINTER(ndev->npinfo, npinfo); 768 rcu_assign_pointer(ndev->npinfo, npinfo);
767 769
768 return 0; 770 return 0;
769 771