]> git.ipfire.org Git - thirdparty/linux.git/commitdiff
fuse: shrink once after all buckets have been scanned
authorMiklos Szeredi <mszeredi@redhat.com>
Wed, 14 Jan 2026 14:53:42 +0000 (15:53 +0100)
committerChristian Brauner <brauner@kernel.org>
Fri, 16 Jan 2026 18:15:14 +0000 (19:15 +0100)
In fuse_dentry_tree_work() move the shrink_dentry_list() out from the loop.

Suggested-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Miklos Szeredi <mszeredi@redhat.com>
Link: https://patch.msgid.link/20260114145344.468856-6-mszeredi@redhat.com
Signed-off-by: Christian Brauner <brauner@kernel.org>
fs/fuse/dir.c

index def2b2e1f96bf062d1a781a22c830f80659c4b59..3927cb069236e9c52674301831c6d655397f24c5 100644 (file)
@@ -187,8 +187,8 @@ static void fuse_dentry_tree_work(struct work_struct *work)
                        node = rb_first(&dentry_hash[i].tree);
                }
                spin_unlock(&dentry_hash[i].lock);
-               shrink_dentry_list(&dispose);
        }
+       shrink_dentry_list(&dispose);
 
        if (inval_wq)
                schedule_delayed_work(&dentry_tree_work,