Whamcloud - gitweb
LU-10595 mgc: don't proccess cld during stopping 90/33190/2
authorAlexander Boyko <c17825@cray.com>
Tue, 18 Sep 2018 12:21:52 +0000 (08:21 -0400)
committerOleg Drokin <green@whamcloud.com>
Wed, 10 Oct 2018 01:48:55 +0000 (01:48 +0000)
The patch fixes the log processing during stopping. It was general
protection fault at mgc_process_cfg_log() at lsi access. Lsi pointer
was wrong 38323172756f6663, and all cld->cld_cfg.cfg_sb had invalid
data.

Signed-off-by: Alexander Boyko <c17825@cray.com>
Cray-bug-id: LUS-6199
Change-Id: Ie4f35ba5be707ab8d274cc26fd2c230ffcb0a16e
Reviewed-on: https://review.whamcloud.com/33190
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Andreas Dilger <adilger@whamcloud.com>
Reviewed-by: James Simmons <uja.ornl@yahoo.com>
Tested-by: James Simmons <uja.ornl@yahoo.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
lustre/mgc/mgc_request.c

index f640e0e..381a57a 100644 (file)
@@ -2099,6 +2099,11 @@ restart:
                                goto restart;
                        } else {
                                mutex_lock(&cld->cld_lock);
+                               /* unlock/lock mutex, so check stopping again */
+                               if (cld->cld_stopping) {
+                                       mutex_unlock(&cld->cld_lock);
+                                       RETURN(0);
+                               }
                                spin_lock(&config_list_lock);
                                cld->cld_lostlock = 1;
                                spin_unlock(&config_list_lock);