diff options
author | Andreas Gruenbacher <agruenba@redhat.com> | 2022-12-10 00:14:01 +0300 |
---|---|---|
committer | Andreas Gruenbacher <agruenba@redhat.com> | 2022-12-15 14:41:22 +0300 |
commit | ba3e77a4a22af018d2fe4d745902b2531ca82aba (patch) | |
tree | 478e5ca0dd5333f322b49446ce5f277b7cee7490 /fs/gfs2/glock.h | |
parent | f0c0ade8d874fb127f9b451d415bee8cbb6bf7a6 (diff) | |
download | linux-ba3e77a4a22af018d2fe4d745902b2531ca82aba.tar.xz |
gfs2: Remove support for glock holder auto-demotion
Remove the support for glock holder auto-demotion (commit dc732906c245
and folow-ups) as we are not planning to use this feature, and the
additional code therefore only adds unnecessary complexity.
Signed-off-by: Andreas Gruenbacher <agruenba@redhat.com>
Diffstat (limited to 'fs/gfs2/glock.h')
-rw-r--r-- | fs/gfs2/glock.h | 20 |
1 files changed, 0 insertions, 20 deletions
diff --git a/fs/gfs2/glock.h b/fs/gfs2/glock.h index e4be9e4bc979..f37ac087e2c1 100644 --- a/fs/gfs2/glock.h +++ b/fs/gfs2/glock.h @@ -156,8 +156,6 @@ static inline struct gfs2_holder *gfs2_glock_is_locked_by_me(struct gfs2_glock * list_for_each_entry(gh, &gl->gl_holders, gh_list) { if (!test_bit(HIF_HOLDER, &gh->gh_iflags)) break; - if (test_bit(HIF_MAY_DEMOTE, &gh->gh_iflags)) - continue; if (gh->gh_owner_pid == pid) goto out; } @@ -308,24 +306,6 @@ static inline bool gfs2_holder_queued(struct gfs2_holder *gh) return !list_empty(&gh->gh_list); } -static inline void gfs2_holder_allow_demote(struct gfs2_holder *gh) -{ - struct gfs2_glock *gl = gh->gh_gl; - - spin_lock(&gl->gl_lockref.lock); - set_bit(HIF_MAY_DEMOTE, &gh->gh_iflags); - spin_unlock(&gl->gl_lockref.lock); -} - -static inline void gfs2_holder_disallow_demote(struct gfs2_holder *gh) -{ - struct gfs2_glock *gl = gh->gh_gl; - - spin_lock(&gl->gl_lockref.lock); - clear_bit(HIF_MAY_DEMOTE, &gh->gh_iflags); - spin_unlock(&gl->gl_lockref.lock); -} - extern void gfs2_inode_remember_delete(struct gfs2_glock *gl, u64 generation); extern bool gfs2_inode_already_deleted(struct gfs2_glock *gl, u64 generation); |