Skip to content

Commit d1def91

Browse files
ebiedermdavem330
authored andcommitted
tilepro: Don't receive packets when the napi budget == 0
Processing any incoming packets with a with a napi budget of 0 is incorrect driver behavior. This matters as netpoll will shortly call drivers with a budget of 0 to avoid receive packet processing happening in hard irq context. Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com> Signed-off-by: David S. Miller <davem@davemloft.net>
1 parent d110ec4 commit d1def91

1 file changed

Lines changed: 3 additions & 0 deletions

File tree

‎drivers/net/ethernet/tile/tilepro.c‎

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -831,6 +831,9 @@ static int tile_net_poll(struct napi_struct *napi, int budget)
831831

832832
unsigned int work = 0;
833833

834+
if (budget <= 0)
835+
goto done;
836+
834837
while (priv->active) {
835838
int index = qup->__packet_receive_read;
836839
if (index == qsp->__packet_receive_queue.__packet_write)

0 commit comments

Comments
 (0)