From 13ca1cd2cfb24bd3edf7d19ce27d98f283f080c2 Mon Sep 17 00:00:00 2001 From: Krunal Soni Date: Wed, 5 Sep 2018 10:58:05 -0700 Subject: [PATCH] qcacmn: Fix policy manager utfw API to delete all connection policy_mgr_decr_connection_count_utfw() API is using policy_mgr_psoc_enable() API to reset policy manager table as well as timer deinit but it does more than resetting the table which causes a stablity issue. For example, policy_mgr_psoc_enable() API calls to reinitialization connection_update_done_evt event which triggers stability issue as it has been already initialized once. Purpose of delete all connection option is, to reset the policy manager table, to reset any timers which can be achieved by calling policy_mgr_psoc_disable() followed by policy_mgr_psoc_enable() Change-Id: Ie3328e150ead99418ddd5025b42a2669e95e1553 CRs-Fixed: 2305419 --- umac/cmn_services/policy_mgr/src/wlan_policy_mgr_action.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/umac/cmn_services/policy_mgr/src/wlan_policy_mgr_action.c b/umac/cmn_services/policy_mgr/src/wlan_policy_mgr_action.c index e2295cf93156..22c07a0bd777 100644 --- a/umac/cmn_services/policy_mgr/src/wlan_policy_mgr_action.c +++ b/umac/cmn_services/policy_mgr/src/wlan_policy_mgr_action.c @@ -2084,6 +2084,11 @@ QDF_STATUS policy_mgr_decr_connection_count_utfw(struct wlan_objmgr_psoc *psoc, QDF_STATUS status; if (del_all) { + status = policy_mgr_psoc_disable(psoc); + if (!QDF_IS_STATUS_SUCCESS(status)) { + policy_mgr_err("Policy manager initialization failed"); + return QDF_STATUS_E_FAILURE; + } status = policy_mgr_psoc_enable(psoc); if (!QDF_IS_STATUS_SUCCESS(status)) { policy_mgr_err("Policy manager initialization failed");