GFS2: Delete debugfs files only after we evict the glocks
authorBob Peterson <rpeterso@redhat.com>
Fri, 28 Jul 2017 12:22:55 +0000 (07:22 -0500)
committerBob Peterson <rpeterso@redhat.com>
Wed, 9 Aug 2017 14:36:39 +0000 (09:36 -0500)
This patch moves the call to gfs2_delete_debugfs_file so that it
comes after the glock hash table has been cleared. This way we
can query the debugfs files if umount hangs.

Signed-off-by: Bob Peterson <rpeterso@redhat.com>
fs/gfs2/ops_fstype.c
fs/gfs2/super.c

index e76058d34b7468b3762a6955f401af822c7a8e9a..51752de54f110323ed35e34d12bd3363c1974136 100644 (file)
@@ -1388,7 +1388,6 @@ static void gfs2_kill_sb(struct super_block *sb)
        sdp->sd_root_dir = NULL;
        sdp->sd_master_dir = NULL;
        shrink_dcache_sb(sb);
-       gfs2_delete_debugfs_file(sdp);
        free_percpu(sdp->sd_lkstats);
        kill_block_super(sb);
 }
index 87271a859a8d197f3e6561d17af9479a8df3cff2..1918bb5fc9431f1b6c431e1733e6bfeeb2389e10 100644 (file)
@@ -924,6 +924,7 @@ restart:
        gfs2_jindex_free(sdp);
        /*  Take apart glock structures and buffer lists  */
        gfs2_gl_hash_clear(sdp);
+       gfs2_delete_debugfs_file(sdp);
        /*  Unmount the locking protocol  */
        gfs2_lm_unmount(sdp);