From a1575e6ec0a6a048494a24ddbc1dd833a076ecae Mon Sep 17 00:00:00 2001 From: Ashok Vuyyuru Date: Wed, 18 Sep 2019 20:55:33 +0530 Subject: [PATCH] msm: ipa3: Fix to not remove endpoint delay if stop channel fails Because of removing endpoint delay when the stop channel failed case observing some junk packets received on a pipe. To avoid junk packets, add change to avoid endpoint delay if stopping GSI channel fails. Change-Id: I4d3d8d9a0de823229d780fe31c8d7f1162e20668 Signed-off-by: Ashok Vuyyuru --- drivers/platform/msm/ipa/ipa_v3/ipa_client.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/drivers/platform/msm/ipa/ipa_v3/ipa_client.c b/drivers/platform/msm/ipa/ipa_v3/ipa_client.c index 6b56ab6c494b..605cdb5b8228 100644 --- a/drivers/platform/msm/ipa/ipa_v3/ipa_client.c +++ b/drivers/platform/msm/ipa/ipa_v3/ipa_client.c @@ -1056,7 +1056,8 @@ static int ipa3_stop_ul_chan_with_data_drain(u32 qmi_req_id, if (!stop_in_proc) goto exit; - if (remove_delay && ep->ep_delay_set) { + /* Remove delay only if stop channel success*/ + if (remove_delay && ep->ep_delay_set == true && !stop_in_proc) { memset(&ep_cfg_ctrl, 0, sizeof(struct ipa_ep_cfg_ctrl)); ep_cfg_ctrl.ipa_ep_delay = false; result = ipa3_cfg_ep_ctrl(clnt_hdl, @@ -1137,7 +1138,7 @@ disable_force_clear_and_exit: if (should_force_clear) ipa3_disable_force_clear(qmi_req_id); exit: - if (remove_delay && ep->ep_delay_set) { + if (remove_delay && ep->ep_delay_set == true && !stop_in_proc) { memset(&ep_cfg_ctrl, 0, sizeof(struct ipa_ep_cfg_ctrl)); ep_cfg_ctrl.ipa_ep_delay = false; result = ipa3_cfg_ep_ctrl(clnt_hdl,