Skip to content
Permalink
Browse files
Move netif_napi_add before bind_interdomain_evtchn_to_irqhandler
Suggested by Wei Liu to fix crash.
  • Loading branch information
talex5 committed Aug 15, 2014
1 parent 026c61c commit 6b6dcc2857d84070c94fe4e3498486337d292870
Showing with 3 additions and 3 deletions.
  1. +3 −3 drivers/net/xen-netback/interface.c
@@ -562,6 +562,9 @@ int xenvif_connect(struct xenvif_queue *queue, unsigned long tx_ring_ref,
init_waitqueue_head(&queue->inflight_wq);
atomic_set(&queue->inflight_packets, 0);

netif_napi_add(queue->vif->dev, &queue->napi, xenvif_poll,
XENVIF_NAPI_WEIGHT);

if (tx_evtchn == rx_evtchn) {
/* feature-split-event-channels == 0 */
err = bind_interdomain_evtchn_to_irqhandler(
@@ -615,9 +618,6 @@ int xenvif_connect(struct xenvif_queue *queue, unsigned long tx_ring_ref,
wake_up_process(queue->task);
wake_up_process(queue->dealloc_task);

netif_napi_add(queue->vif->dev, &queue->napi, xenvif_poll,
XENVIF_NAPI_WEIGHT);

return 0;

err_rx_unbind:

0 comments on commit 6b6dcc2

Please sign in to comment.