Skip to content

Commit

Permalink
ibmveth: enable interrupts after napi_complete()
Browse files Browse the repository at this point in the history
The interrupt is enabled before napi_complete(). A network timeout
occurs if the interrupt handler is called before napi_complete().

Fix the bug by enabling the interrupt after napi_complete().

Signed-off-by: Yongbae Park <yongbae2@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
Yongbae Park authored and David S. Miller committed Mar 10, 2015
1 parent 5778d39 commit 4736edc
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions drivers/net/ethernet/ibm/ibmveth.c
Original file line number Diff line number Diff line change
Expand Up @@ -1136,6 +1136,8 @@ static int ibmveth_poll(struct napi_struct *napi, int budget)
ibmveth_replenish_task(adapter);

if (frames_processed < budget) {
napi_complete(napi);

/* We think we are done - reenable interrupts,
* then check once more to make sure we are done.
*/
Expand All @@ -1144,8 +1146,6 @@ static int ibmveth_poll(struct napi_struct *napi, int budget)

BUG_ON(lpar_rc != H_SUCCESS);

napi_complete(napi);

if (ibmveth_rxq_pending_buffer(adapter) &&
napi_reschedule(napi)) {
lpar_rc = h_vio_signal(adapter->vdev->unit_address,
Expand Down

0 comments on commit 4736edc

Please sign in to comment.