From bbd9b42a2e7e3a93dfb58805cff142030d1b9583 Mon Sep 17 00:00:00 2001 From: Vladislav Bolkhovitin Date: Thu, 13 Apr 2017 23:41:14 +0000 Subject: [PATCH] scst: take scst_mutex before calling scst_del_free_acg() in exit_scst() scst_del_free_acg() does lockdep_assert_held(&scst_mutex), so we'd better take the lock before calling it. Signed-off-by: David Butterfield git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@7117 d57e44dd-8a1f-0410-8b47-8ef2f437770f --- scst/src/scst_main.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/scst/src/scst_main.c b/scst/src/scst_main.c index 1f6139e52..da92985fb 100644 --- a/scst/src/scst_main.c +++ b/scst/src/scst_main.c @@ -2859,7 +2859,9 @@ static void __exit exit_scst(void) scsi_unregister_interface(&scst_interface); #ifdef CONFIG_SCST_PROC + mutex_lock(&scst_mutex); scst_del_free_acg(scst_default_acg, false); + mutex_unlock(&scst_mutex); #endif scst_sgv_pools_deinit();