msm: ipa: remove delay in out of buffer recovery procedure

When a RX pipe runs out of buffers, a delayed work is scheduled
to re-attempt the replenish process but the single threaded
workqueue will not process that work till the existing work is
retired. The existing work will be retired after sufficient
inacvitivty is detected but in this corner-case, we can do this
immediately since no further packets will be received.

Change-Id: Ia12a35aaadcb95c94471ae0ffea8c61a9a3d26f7
CRs-Fixed: 854938
Acked-by: Ady Abraham <adya@qti.qualcomm.com>
Signed-off-by: Skylar Chang <chiaweic@codeaurora.org>
This commit is contained in:
Skylar Chang 2017-07-06 15:36:47 -07:00
parent e868dcc8bb
commit c52d43aece

View file

@ -1188,6 +1188,15 @@ static void ipa3_handle_rx(struct ipa3_sys_context *sys)
} else {
inactive_cycles = 0;
}
/*
* if pipe is out of buffers there is no point polling for
* completed descs; release the worker so delayed work can
* run in a timely manner
*/
if (sys->len == 0)
break;
} while (inactive_cycles <= POLLING_INACTIVITY_RX);
trace_poll_to_intr3(sys->ep->client);