浏览代码

qcacld-3.0: deregister policy mgr cb upon stop modules

There is chance that some active thread is running and
skip stop modules. In that case driver should not
deregister policy mgr callback.
Call hdd_deregister_policy_manager_callback after
active thread check when stop modules.

Change-Id: I5fe3e438e87da0b333ae9b20994e58228fa67918
CRs-Fixed: 2443271
Liangwei Dong 6 年之前
父节点
当前提交
857cb8464f
共有 1 个文件被更改,包括 2 次插入3 次删除
  1. 2 3
      core/hdd/src/wlan_hdd_main.c

+ 2 - 3
core/hdd/src/wlan_hdd_main.c

@@ -11223,9 +11223,6 @@ int hdd_wlan_stop_modules(struct hdd_context *hdd_ctx, bool ftm_mode)
 	struct target_psoc_info *tgt_hdl;
 
 	hdd_enter();
-
-	hdd_deregister_policy_manager_callback(hdd_ctx->psoc);
-
 	qdf_ctx = cds_get_context(QDF_MODULE_ID_QDF_DEVICE);
 	if (!qdf_ctx) {
 		hdd_err("QDF device context NULL");
@@ -11248,6 +11245,8 @@ int hdd_wlan_stop_modules(struct hdd_context *hdd_ctx, bool ftm_mode)
 		}
 	}
 
+	hdd_deregister_policy_manager_callback(hdd_ctx->psoc);
+
 	/* free user wowl patterns */
 	hdd_free_user_wowl_ptrns();