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>
This commit is contained in:
Alex Elder 2021-01-21 05:48:18 -06:00 committed by Jakub Kicinski
parent c80c4a1ea4
commit 148604e7ea

View File

@ -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;
}