diff options
author | Bob Peterson <rpeterso@redhat.com> | 2022-12-06 00:12:59 +0100 |
---|---|---|
committer | Andreas Gruenbacher <agruenba@redhat.com> | 2023-01-31 22:40:24 +0100 |
commit | 6c0246a96e08cd1b5036c34c52de99bd9dffbb48 (patch) | |
tree | 4d6075705c03e4e63740c0ee65fe35b7f8e6295d /fs/gfs2/glops.c | |
parent | gfs2: Add SDF_DEACTIVATING super block flag (diff) | |
download | linux-6c0246a96e08cd1b5036c34c52de99bd9dffbb48.tar.xz linux-6c0246a96e08cd1b5036c34c52de99bd9dffbb48.zip |
gfs2: Cease delete work during unmount
Add a check to delete_work_func() so that it quits when it finds that
the filesystem is deactivating. This speeds up the delete workqueue
draining in gfs2_kill_sb().
In addition, make sure that iopen_go_callback() won't queue any new
delete work while the filesystem is deactivating.
Signed-off-by: Bob Peterson <rpeterso@redhat.com>
Signed-off-by: Andreas Gruenbacher <agruenba@redhat.com>
Diffstat (limited to 'fs/gfs2/glops.c')
-rw-r--r-- | fs/gfs2/glops.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/fs/gfs2/glops.c b/fs/gfs2/glops.c index 007cd59d0e47..ad14818a790a 100644 --- a/fs/gfs2/glops.c +++ b/fs/gfs2/glops.c @@ -648,7 +648,8 @@ static void iopen_go_callback(struct gfs2_glock *gl, bool remote) struct gfs2_inode *ip = gl->gl_object; struct gfs2_sbd *sdp = gl->gl_name.ln_sbd; - if (!remote || sb_rdonly(sdp->sd_vfs)) + if (!remote || sb_rdonly(sdp->sd_vfs) || + test_bit(SDF_DEACTIVATING, &sdp->sd_flags)) return; if (gl->gl_demote_state == LM_ST_UNLOCKED && |