mt76: avoid enabling interrupt if NAPI poll is still pending

if napi_complete() returns false, it means that polling is still pending.
Interrupts should not fire until the polling is no longer scheduled

Signed-off-by: Felix Fietkau <nbd@nbd.name>
This commit is contained in:
Felix Fietkau 2019-10-07 12:33:39 +02:00
parent e7aaa72f47
commit 3e0705acd4
1 changed files with 1 additions and 3 deletions

View File

@ -539,10 +539,8 @@ mt76_dma_rx_poll(struct napi_struct *napi, int budget)
rcu_read_unlock();
if (done < budget) {
napi_complete(napi);
if (done < budget && napi_complete(napi))
dev->drv->rx_poll_complete(dev, qid);
}
return done;
}