From: Alex Elder Date: Fri, 15 May 2020 19:52:03 +0000 (-0500) Subject: net: ipa: don't be a hog in gsi_channel_poll() X-Git-Tag: v5.15~3831^2~44 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=f45a7bccdc190e2cf6ca3a527edbc4c80d7114ef;p=platform%2Fkernel%2Flinux-starfive.git net: ipa: don't be a hog in gsi_channel_poll() The iteration count value used in gsi_channel_poll() is intended to limit poll iterations to the budget supplied as an argument. But it's never updated. Fix this bug by incrementing the count each time through the loop. Reported-by: Sharath Chandra Vurukala Signed-off-by: Alex Elder Signed-off-by: David S. Miller --- diff --git a/drivers/net/ipa/gsi.c b/drivers/net/ipa/gsi.c index b671bea..8d9ca1c 100644 --- a/drivers/net/ipa/gsi.c +++ b/drivers/net/ipa/gsi.c @@ -1392,6 +1392,7 @@ static int gsi_channel_poll(struct napi_struct *napi, int budget) while (count < budget) { struct gsi_trans *trans; + count++; trans = gsi_channel_poll_one(channel); if (!trans) break;