diff options
author | Alex Elder <elder@linaro.org> | 2021-01-21 12:48:18 +0100 |
---|---|---|
committer | Jakub Kicinski <kuba@kernel.org> | 2021-01-23 22:16:00 +0100 |
commit | 148604e7eafb2f6af275d60b9ab27e7a9622e93f (patch) | |
tree | 5ba2f4f88fe2e3826705e37292090d278276bd85 /drivers | |
parent | net: ipa: count actual work done in gsi_channel_poll() (diff) | |
download | linux-148604e7eafb2f6af275d60b9ab27e7a9622e93f.tar.xz linux-148604e7eafb2f6af275d60b9ab27e7a9622e93f.zip |
net: ipa: heed napi_complete() return value
Pay attention to the return value of napi_complete(), completing
polling only if it returns true.
Just use napi rather than &channel->napi as the argument passed to
napi_complete().
Signed-off-by: Alex Elder <elder@linaro.org>
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/net/ipa/gsi.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/drivers/net/ipa/gsi.c b/drivers/net/ipa/gsi.c index 56a5eb61b20c..634f514e861e 100644 --- a/drivers/net/ipa/gsi.c +++ b/drivers/net/ipa/gsi.c @@ -1555,10 +1555,8 @@ static int gsi_channel_poll(struct napi_struct *napi, int budget) gsi_trans_complete(trans); } - if (count < budget) { - napi_complete(&channel->napi); + if (count < budget && napi_complete(napi)) gsi_irq_ieob_enable(channel->gsi, channel->evt_ring_id); - } return count; } |