Browse Source

dataipa: unlock qmi mutex before the workqueue

Make sure to unlock mutex before adding qmi client req to work queue

Change-Id: I6c85017600c797b64063925be6717151ddb5a0c9
Signed-off-by: Michael Adisumarta <[email protected]>
Michael Adisumarta 3 years ago
parent
commit
201ab59656
1 changed files with 2 additions and 2 deletions
  1. 2 2
      drivers/platform/msm/ipa/ipa_v3/ipa_qmi_service.c

+ 2 - 2
drivers/platform/msm/ipa/ipa_v3/ipa_qmi_service.c

@@ -2110,18 +2110,18 @@ void ipa3_qmi_service_exit(void)
 		ipa3_svc_handle = NULL;
 	}
 
-	/* qmi-client */
-
 	/* Release client handle */
 	mutex_lock(&ipa3_qmi_lock);
 	if (ipa_q6_clnt != NULL) {
 		qmi_handle_release(ipa_q6_clnt);
 		vfree(ipa_q6_clnt);
 		ipa_q6_clnt = NULL;
+		mutex_unlock(&ipa3_qmi_lock);
 		if (ipa_clnt_req_workqueue) {
 			destroy_workqueue(ipa_clnt_req_workqueue);
 			ipa_clnt_req_workqueue = NULL;
 		}
+		mutex_lock(&ipa3_qmi_lock);
 	}
 
 	/* clean the QMI msg cache */