From: Randy Dunlap <rdunlap@xenotime.net>
To: Glauber Costa <glommer@parallels.com>
Cc: davem@davemloft.net, linux-kernel@vger.kernel.org,
netdev@vger.kernel.org, cgroups@vger.kernel.org,
Stephen Rothwell <sfr@canb.auug.org.au>
Subject: Re: [PATCH] move sock_update_memcg outside of CONFIG_INET
Date: Mon, 16 Jan 2012 10:48:21 -0800 [thread overview]
Message-ID: <4F1470F5.7090803@xenotime.net> (raw)
In-Reply-To: <1326701079-10331-1-git-send-email-glommer@parallels.com>
On 01/16/2012 12:04 AM, Glauber Costa wrote:
> Although only used currently for tcp sockets, this function
> is now used in common sock code (for sock_clone())
>
> Commit 475f1b52645a29936b9df1d8fcd45f7e56bd4a9f moved the
> declaration of sock_update_clone() to inside sock.c, but
> this only fixes the problem when CONFIG_CGROUP_MEM_RES_CTLR_KMEM
> is also not defined.
>
> This patch here is verified to fix both problems, although
> reverting the previous one is not necessary.
>
> Signed-off-by: Glauber Costa <glommer@parallels.com>
> CC: David S. Miller <davem@davemloft.net>
> CC: Stephen Rothwell <sfr@canb.auug.org.au>
Reported-by: Randy Dunlap <rdunlap@xenotime.net>
Acked-by: Randy Dunlap <rdunlap@xenotime.net>
Thanks.
> ---
> mm/memcontrol.c | 2 +-
> 1 files changed, 1 insertions(+), 1 deletions(-)
>
> diff --git a/mm/memcontrol.c b/mm/memcontrol.c
> index 602207b..3dbff4d 100644
> --- a/mm/memcontrol.c
> +++ b/mm/memcontrol.c
> @@ -373,7 +373,6 @@ static void mem_cgroup_put(struct mem_cgroup *memcg);
>
> /* Writing them here to avoid exposing memcg's inner layout */
> #ifdef CONFIG_CGROUP_MEM_RES_CTLR_KMEM
> -#ifdef CONFIG_INET
> #include <net/sock.h>
> #include <net/ip.h>
>
> @@ -420,6 +419,7 @@ void sock_release_memcg(struct sock *sk)
> }
> }
>
> +#ifdef CONFIG_INET
> struct cg_proto *tcp_proto_cgroup(struct mem_cgroup *memcg)
> {
> if (!memcg || mem_cgroup_is_root(memcg))
--
~Randy
*** Remember to use Documentation/SubmitChecklist when testing your code ***
next prev parent reply other threads:[~2012-01-16 18:48 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-01-16 8:04 [PATCH] move sock_update_memcg outside of CONFIG_INET Glauber Costa
2012-01-16 18:48 ` Randy Dunlap [this message]
[not found] ` <1326701079-10331-1-git-send-email-glommer-bzQdu9zFT3WakBO8gow8eQ@public.gmane.org>
2012-01-17 15:16 ` David Miller
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=4F1470F5.7090803@xenotime.net \
--to=rdunlap@xenotime.net \
--cc=cgroups@vger.kernel.org \
--cc=davem@davemloft.net \
--cc=glommer@parallels.com \
--cc=linux-kernel@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=sfr@canb.auug.org.au \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).