summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlexey Dobriyan <adobriyan@gmail.com>2018-04-10 16:31:12 -0700
committerLinus Torvalds <torvalds@linux-foundation.org>2018-04-11 10:28:33 -0700
commit2acddbe8168967adebf4623923242c9a4f9e1aee (patch)
tree472f700ed85de19878939441eedfc9bce040819f
parent195b8cf0689554db764f459730c81f741887aa5f (diff)
proc: account "struct pde_opener"
The allocation is persistent in fact as any fool can open a file in /proc and sit on it. Link: http://lkml.kernel.org/r/20180214082409.GC17157@avx2 Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com> Cc: Al Viro <viro@ZenIV.linux.org.uk> Cc: Kees Cook <keescook@chromium.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
-rw-r--r--fs/proc/inode.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/proc/inode.c b/fs/proc/inode.c
index 5349eb07ac29..89618836887d 100644
--- a/fs/proc/inode.c
+++ b/fs/proc/inode.c
@@ -103,7 +103,7 @@ void __init proc_init_kmemcache(void)
init_once);
pde_opener_cache =
kmem_cache_create("pde_opener", sizeof(struct pde_opener), 0,
- SLAB_PANIC, NULL);
+ SLAB_ACCOUNT|SLAB_PANIC, NULL);
}
static int proc_show_options(struct seq_file *seq, struct dentry *root)