Commit c582a7fe authored by Hauke Mehrtens's avatar Hauke Mehrtens Committed by David S. Miller

net: lantiq: Use napi_complete_done()

Use napi_complete_done() and activate the interrupts when this function
returns true. This way the generic NAPI code can take care of activating
the interrupts.
Signed-off-by: default avatarHauke Mehrtens <hauke@hauke-m.de>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 74c7b80e
...@@ -230,8 +230,8 @@ static int xrx200_poll_rx(struct napi_struct *napi, int budget) ...@@ -230,8 +230,8 @@ static int xrx200_poll_rx(struct napi_struct *napi, int budget)
} }
if (rx < budget) { if (rx < budget) {
napi_complete(&ch->napi); if (napi_complete_done(&ch->napi, rx))
ltq_dma_enable_irq(&ch->dma); ltq_dma_enable_irq(&ch->dma);
} }
return rx; return rx;
...@@ -272,8 +272,8 @@ static int xrx200_tx_housekeeping(struct napi_struct *napi, int budget) ...@@ -272,8 +272,8 @@ static int xrx200_tx_housekeeping(struct napi_struct *napi, int budget)
netif_wake_queue(net_dev); netif_wake_queue(net_dev);
if (pkts < budget) { if (pkts < budget) {
napi_complete(&ch->napi); if (napi_complete_done(&ch->napi, pkts))
ltq_dma_enable_irq(&ch->dma); ltq_dma_enable_irq(&ch->dma);
} }
return pkts; return pkts;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment