Skip to content

Commit df20698

Browse files
hnaztorvalds
authored andcommitted
fs: fuse: account fuse_inode slab memory as reclaimable
Fuse inodes are currently included in the unreclaimable slab counts - SUnreclaim in /proc/meminfo, slab_unreclaimable in /proc/vmstat and the per-cgroup memory.stat. But they are reclaimable just like other filesystems' inodes, and /proc/sys/vm/drop_caches frees them easily. Mark the slab cache reclaimable. Link: http://lkml.kernel.org/r/[email protected] Signed-off-by: Johannes Weiner <[email protected]> Cc: Miklos Szeredi <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
1 parent b050e37 commit df20698

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

fs/fuse/inode.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1273,9 +1273,9 @@ static int __init fuse_fs_init(void)
12731273
int err;
12741274

12751275
fuse_inode_cachep = kmem_cache_create("fuse_inode",
1276-
sizeof(struct fuse_inode), 0,
1277-
SLAB_HWCACHE_ALIGN|SLAB_ACCOUNT,
1278-
fuse_inode_init_once);
1276+
sizeof(struct fuse_inode), 0,
1277+
SLAB_HWCACHE_ALIGN|SLAB_ACCOUNT|SLAB_RECLAIM_ACCOUNT,
1278+
fuse_inode_init_once);
12791279
err = -ENOMEM;
12801280
if (!fuse_inode_cachep)
12811281
goto out;

0 commit comments

Comments
 (0)