Commit f45a7bcc authored by Alex Elder's avatar Alex Elder Committed by David S. Miller
Browse files

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: default avatarSharath Chandra Vurukala <sharathv@codeaurora.com>
Signed-off-by: default avatarAlex Elder <elder@linaro.org>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 5e5502e0
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -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;