Browse Source

qcacmn: Remove locks from object manager debug API

The object manager global lock is used in few
debug APIs. In these instances the log is taken
only on the local copy and the updates are happening
on the local copy without the lock.

So there is nothing that is protected by taking these locks
and there is also a scenario where this lock is resulting in
deadlock, so removing these locks.

Change-Id: I583de096538a5f9c87cbcfa2b267e82630f3278f
CRs-Fixed: 2930205
Vivek 4 năm trước cách đây
mục cha
commit
57cacda10f

+ 0 - 10
umac/cmn_services/obj_mgr/src/wlan_objmgr_debug.c

@@ -179,9 +179,7 @@ void wlan_objmgr_notify_log_delete(void *obj,
 		return;
 		return;
 	}
 	}
 
 
-	qdf_spin_lock_bh(&g_umac_glb_obj->global_lock);
 	debug_info = g_umac_glb_obj->debug_info;
 	debug_info = g_umac_glb_obj->debug_info;
-	qdf_spin_unlock_bh(&g_umac_glb_obj->global_lock);
 
 
 	if (!debug_info) {
 	if (!debug_info) {
 		obj_mgr_err("debug_info is null");
 		obj_mgr_err("debug_info is null");
@@ -274,9 +272,7 @@ void wlan_objmgr_notify_destroy(void *obj,
 	const char *obj_name;
 	const char *obj_name;
 	union wlan_objmgr_del_obj *del_obj = (union wlan_objmgr_del_obj *)&obj;
 	union wlan_objmgr_del_obj *del_obj = (union wlan_objmgr_del_obj *)&obj;
 
 
-	qdf_spin_lock_bh(&g_umac_glb_obj->global_lock);
 	debug_info = g_umac_glb_obj->debug_info;
 	debug_info = g_umac_glb_obj->debug_info;
-	qdf_spin_unlock_bh(&g_umac_glb_obj->global_lock);
 
 
 	if (!debug_info) {
 	if (!debug_info) {
 		obj_mgr_err("debug_info is null");
 		obj_mgr_err("debug_info is null");
@@ -446,9 +442,7 @@ static void wlan_objmgr_iterate_log_del_obj_handler(void *timer_arg)
 	qdf_time_t cur_tstamp;
 	qdf_time_t cur_tstamp;
 	QDF_STATUS status;
 	QDF_STATUS status;
 
 
-	qdf_spin_lock_bh(&g_umac_glb_obj->global_lock);
 	debug_info = g_umac_glb_obj->debug_info;
 	debug_info = g_umac_glb_obj->debug_info;
-	qdf_spin_unlock_bh(&g_umac_glb_obj->global_lock);
 
 
 	if (!debug_info) {
 	if (!debug_info) {
 		obj_mgr_err("debug_info is not initialized");
 		obj_mgr_err("debug_info is not initialized");
@@ -521,9 +515,7 @@ void wlan_objmgr_debug_info_deinit(void)
 	qdf_list_t *list;
 	qdf_list_t *list;
 	bool is_child_alive = false;
 	bool is_child_alive = false;
 
 
-	qdf_spin_lock_bh(&g_umac_glb_obj->global_lock);
 	debug_info = g_umac_glb_obj->debug_info;
 	debug_info = g_umac_glb_obj->debug_info;
-	qdf_spin_unlock_bh(&g_umac_glb_obj->global_lock);
 
 
 	if (!debug_info) {
 	if (!debug_info) {
 		obj_mgr_err("debug_info is not initialized");
 		obj_mgr_err("debug_info is not initialized");
@@ -590,9 +582,7 @@ void wlan_objmgr_debug_info_init(void)
 	qdf_spinlock_create(&debug_info->list_lock);
 	qdf_spinlock_create(&debug_info->list_lock);
 
 
 	/* attach debug_info object to global object */
 	/* attach debug_info object to global object */
-	qdf_spin_lock_bh(&g_umac_glb_obj->global_lock);
 	g_umac_glb_obj->debug_info = debug_info;
 	g_umac_glb_obj->debug_info = debug_info;
-	qdf_spin_unlock_bh(&g_umac_glb_obj->global_lock);
 }
 }
 
 
 #ifdef WLAN_OBJMGR_REF_ID_TRACE
 #ifdef WLAN_OBJMGR_REF_ID_TRACE