Thread (22 messages) 22 messages, 5 authors, 2016-08-23

Re: [PATCH RESEND 8/8] af_unix: charge buffers to kmemcg

From: Eric Dumazet <hidden>
Date: 2016-05-24 13:02:06
Also in: linux-fsdevel, lkml, netdev

On Tue, 2016-05-24 at 11:49 +0300, Vladimir Davydov wrote:
Unix sockets can consume a significant amount of system memory, hence
they should be accounted to kmemcg.

Since unix socket buffers are always allocated from process context,
all we need to do to charge them to kmemcg is set __GFP_ACCOUNT in
sock->sk_allocation mask.
I have two questions : 

1) What happens when a buffer, allocated from socket <A> lands in a
different socket <B>, maybe owned by another user/process.

Who owns it now, in term of kmemcg accounting ?

2) Has performance impact been evaluated ?

Thanks.



--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org.  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help