From: KOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com>
To: Hugh Dickins <hugh@veritas.com>,
KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>
Cc: kosaki.motohiro@jp.fujitsu.com,
Andrew Morton <akpm@linux-foundation.org>,
linux-mm@kvack.org
Subject: Re: [PATCH mmotm] memcg: avoid reclaim_stat oops when disabled
Date: Tue, 23 Dec 2008 10:29:46 +0900 (JST) [thread overview]
Message-ID: <20081223102625.164B.KOSAKI.MOTOHIRO@jp.fujitsu.com> (raw)
In-Reply-To: <Pine.LNX.4.64.0812230116210.20371@blonde.anvils>
> struct zone_reclaim_stat *
> mem_cgroup_get_reclaim_stat_from_page(struct page *page)
> {
> - struct page_cgroup *pc = lookup_page_cgroup(page);
> - struct mem_cgroup_per_zone *mz = page_cgroup_zoneinfo(pc);
> + struct page_cgroup *pc;
> + struct mem_cgroup_per_zone *mz;
>
> + if (mem_cgroup_disabled())
> + return NULL;
> +
> + pc = lookup_page_cgroup(page);
> + mz = page_cgroup_zoneinfo(pc);
> if (!mz)
> return NULL;
Oops, really thanks.
this patch is defenitly needed and corrent.
Reviewed-by: KOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com>
Kamezawa-san, I think memcg_test.txt should describe "cgroup_disabled=memory"
too. What do you think it?
--
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>
prev parent reply other threads:[~2008-12-23 1:29 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-12-23 1:24 Hugh Dickins
2008-12-23 1:23 ` KAMEZAWA Hiroyuki
2008-12-23 1:29 ` KOSAKI Motohiro [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=20081223102625.164B.KOSAKI.MOTOHIRO@jp.fujitsu.com \
--to=kosaki.motohiro@jp.fujitsu.com \
--cc=akpm@linux-foundation.org \
--cc=hugh@veritas.com \
--cc=kamezawa.hiroyu@jp.fujitsu.com \
--cc=linux-mm@kvack.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