summaryrefslogtreecommitdiff
path: root/fs/gfs2/glops.c
diff options
context:
space:
mode:
authorAndreas Gruenbacher <agruenba@redhat.com>2024-03-30 05:08:32 +0100
committerAndreas Gruenbacher <agruenba@redhat.com>2024-05-29 15:34:55 +0200
commit3f4475bf24de31cce4a0c7d1372d4ab02b1f1407 (patch)
treec08a15ad5fbda687bdc7c703c66f38f402cc43ce /fs/gfs2/glops.c
parent767fd5a0160774178a597b7a7b6e07915fe00efa (diff)
Revert "GFS2: Don't add all glocks to the lru"
This reverts commit e7ccaf5fe1590667b3fa2f8df5c5ec9ba0dc5b85. Before commit e7ccaf5fe159, every time a resource group glock was dequeued by gfs2_glock_dq(), it was added to the glock LRU list even though the glock was still referenced by the resource group and could never be evicted, anyway. Commit e7ccaf5fe159 added a GLOF_LRU hack to avoid that overhead for resource group glocks, and that hack was since adopted for some other types of glocks as well. We now no longer add glocks to the glock LRU list while they are still referenced. This solves the underlying problem, and obsoletes the GLOF_LRU hack. Signed-off-by: Andreas Gruenbacher <agruenba@redhat.com> (cherry picked from commit 3e5257c810cba91e274d07f3db5cf013c7c830be)
Diffstat (limited to 'fs/gfs2/glops.c')
-rw-r--r--fs/gfs2/glops.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/fs/gfs2/glops.c b/fs/gfs2/glops.c
index 39bb6758a2a0..7bc7f6785abd 100644
--- a/fs/gfs2/glops.c
+++ b/fs/gfs2/glops.c
@@ -727,7 +727,7 @@ const struct gfs2_glock_operations gfs2_inode_glops = {
.go_held = inode_go_held,
.go_dump = inode_go_dump,
.go_type = LM_TYPE_INODE,
- .go_flags = GLOF_ASPACE | GLOF_LRU | GLOF_LVB,
+ .go_flags = GLOF_ASPACE | GLOF_LVB,
.go_unlocked = inode_go_unlocked,
};
@@ -751,13 +751,13 @@ const struct gfs2_glock_operations gfs2_iopen_glops = {
.go_type = LM_TYPE_IOPEN,
.go_callback = iopen_go_callback,
.go_dump = inode_go_dump,
- .go_flags = GLOF_LRU | GLOF_NONDISK,
+ .go_flags = GLOF_NONDISK,
.go_subclass = 1,
};
const struct gfs2_glock_operations gfs2_flock_glops = {
.go_type = LM_TYPE_FLOCK,
- .go_flags = GLOF_LRU | GLOF_NONDISK,
+ .go_flags = GLOF_NONDISK,
};
const struct gfs2_glock_operations gfs2_nondisk_glops = {
@@ -768,7 +768,7 @@ const struct gfs2_glock_operations gfs2_nondisk_glops = {
const struct gfs2_glock_operations gfs2_quota_glops = {
.go_type = LM_TYPE_QUOTA,
- .go_flags = GLOF_LVB | GLOF_LRU | GLOF_NONDISK,
+ .go_flags = GLOF_LVB | GLOF_NONDISK,
};
const struct gfs2_glock_operations gfs2_journal_glops = {