scst: take scst_mutex before calling scst_del_free_acg() in scst_proc_cleanup_module()

Take lock before a call that ends up at the lockdep_assert_held() in
scst_del_free_acg() without locking.

Signed-off-by: David Butterfield <dab21774@gmail.com>



git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@7118 d57e44dd-8a1f-0410-8b47-8ef2f437770f
This commit is contained in:
Vladislav Bolkhovitin
2017-04-13 23:42:51 +00:00
parent bbd9b42a2e
commit a4a1e480b1

View File

@@ -1213,7 +1213,11 @@ void scst_proc_cleanup_module(void)
/* We may not bother about locks here */
scst_proc_cleanup_sgv();
mutex_lock(&scst_mutex);
scst_proc_cleanup_groups();
mutex_unlock(&scst_mutex);
scst_proc_cleanup_module_log();
remove_proc_entry(SCST_PROC_THREADS_NAME, scst_proc_scsi_tgt);
remove_proc_entry(SCST_PROC_HELP_NAME, scst_proc_scsi_tgt);