Skip to content

Commit 0bcfe68

Browse files
committed
Revert "memcg: enable accounting for pollfd and select bits arrays"
This reverts commit b655843. Just like with the memcg lock accounting, the kernel test robot reports a sizeable performance regression for this commit, and while it clearly does the rigth thing in theory, we'll need to look at just how to avoid or minimize the performance overhead of the memcg accounting. People already have suggestions on how to do that, but it's "future work". So revert it for now. [ Note: the first link below is for this same commit but a different commit ID, because it's the kernel test robot ended up noticing it in Andrew Morton's patch queue ] Link: https://lore.kernel.org/lkml/20210905132732.GC15026@xsang-OptiPlex-9020/ Link: https://lore.kernel.org/lkml/20210907150757.GE17617@xsang-OptiPlex-9020/ Acked-by: Jens Axboe <axboe@kernel.dk> Acked-by: Shakeel Butt <shakeelb@google.com> Acked-by: Roman Gushchin <guro@fb.com> Cc: Tejun Heo <tj@kernel.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
1 parent 3754707 commit 0bcfe68

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

‎fs/select.c‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -655,7 +655,7 @@ int core_sys_select(int n, fd_set __user *inp, fd_set __user *outp,
655655
goto out_nofds;
656656

657657
alloc_size = 6 * size;
658-
bits = kvmalloc(alloc_size, GFP_KERNEL_ACCOUNT);
658+
bits = kvmalloc(alloc_size, GFP_KERNEL);
659659
if (!bits)
660660
goto out_nofds;
661661
}
@@ -1000,7 +1000,7 @@ static int do_sys_poll(struct pollfd __user *ufds, unsigned int nfds,
10001000

10011001
len = min(todo, POLLFD_PER_PAGE);
10021002
walk = walk->next = kmalloc(struct_size(walk, entries, len),
1003-
GFP_KERNEL_ACCOUNT);
1003+
GFP_KERNEL);
10041004
if (!walk) {
10051005
err = -ENOMEM;
10061006
goto out_fds;

0 commit comments

Comments
 (0)