linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
From: Michal Hocko <mhocko@suse.cz>
To: David Rientjes <rientjes@google.com>
Cc: Andrew Morton <akpm@linux-foundation.org>,
	Linus Torvalds <torvalds@linux-foundation.org>,
	Randy Dunlap <rdunlap@xenotime.net>,
	KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>,
	"Kirill A. Shutemov" <kirill@shutemov.name>,
	"David S. Miller" <davem@davemloft.net>,
	"Eric W. Biederman" <ebiederm@xmission.com>,
	Eric Dumazet <eric.dumazet@gmail.com>,
	Glauber Costa <glommer@parallels.com>,
	linux-kernel@vger.kernel.org, linux-mm@kvack.org
Subject: Re: [patch for-linus] memcg, kmem: fix build error when CONFIG_INET is disabled
Date: Wed, 10 Oct 2012 11:27:25 +0200	[thread overview]
Message-ID: <20121010092725.GA23288@dhcp22.suse.cz> (raw)
In-Reply-To: <alpine.DEB.2.00.1210092325500.9528@chino.kir.corp.google.com>

On Tue 09-10-12 23:32:35, David Rientjes wrote:
> Commit e1aab161e013 ("socket: initial cgroup code.") causes a build error 
> when CONFIG_INET is disabled in Linus' tree:
> 
> net/built-in.o: In function `sk_update_clone':
> net/core/sock.c:1336: undefined reference to `sock_update_memcg'
> 
> sock_update_memcg() is only defined when CONFIG_INET is enabled, so fix it 
> by defining the dummy function without this option.
> 
> Reported-by: Randy Dunlap <rdunlap@xenotime.net>
> Signed-off-by: David Rientjes <rientjes@google.com>

Acked-by: Michal Hocko <mhocko@suse.cz>

Thanks!

> ---
>  Checking the logs, Randy reported this in an email to LKML on 
>  September 24 and didn't get a response...
> 
>  include/linux/memcontrol.h |    4 ++--
>  1 files changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/include/linux/memcontrol.h b/include/linux/memcontrol.h
> --- a/include/linux/memcontrol.h
> +++ b/include/linux/memcontrol.h
> @@ -396,7 +396,7 @@ enum {
>  };
>  
>  struct sock;
> -#ifdef CONFIG_MEMCG_KMEM
> +#if defined(CONFIG_INET) && defined(CONFIG_MEMCG_KMEM)
>  void sock_update_memcg(struct sock *sk);
>  void sock_release_memcg(struct sock *sk);
>  #else
> @@ -406,6 +406,6 @@ static inline void sock_update_memcg(struct sock *sk)
>  static inline void sock_release_memcg(struct sock *sk)
>  {
>  }
> -#endif /* CONFIG_MEMCG_KMEM */
> +#endif /* CONFIG_INET && CONFIG_MEMCG_KMEM */
>  #endif /* _LINUX_MEMCONTROL_H */
>  
> 
> --
> 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>

-- 
Michal Hocko
SUSE Labs

--
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>

      parent reply	other threads:[~2012-10-10  9:27 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-10-10  6:32 [patch for-linus] memcg, kmem: fix build error when CONFIG_INET is disabled David Rientjes
2012-10-10  8:56 ` Glauber Costa
2012-10-10  9:27   ` Michal Hocko
2012-10-10  9:29     ` Glauber Costa
2012-10-10 14:33       ` Fengguang Wu
2012-10-10 20:17         ` David Rientjes
2012-10-10 20:27           ` Glauber Costa
2012-10-10  9:27 ` Michal Hocko [this message]

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=20121010092725.GA23288@dhcp22.suse.cz \
    --to=mhocko@suse.cz \
    --cc=akpm@linux-foundation.org \
    --cc=davem@davemloft.net \
    --cc=ebiederm@xmission.com \
    --cc=eric.dumazet@gmail.com \
    --cc=glommer@parallels.com \
    --cc=kamezawa.hiroyu@jp.fujitsu.com \
    --cc=kirill@shutemov.name \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=rdunlap@xenotime.net \
    --cc=rientjes@google.com \
    --cc=torvalds@linux-foundation.org \
    /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).