From: Johannes Weiner <hannes@cmpxchg.org>
To: akpm@linux-foundation.org
Cc: ak@linux.intel.com, aarcange@redhat.com,
kamezawa.hiroyu@jp.fujitsu.com, mm-commits@vger.kernel.org,
linux-mm@kvack.org, linux-kernel@vger.kernel.org
Subject: Re: + mm-add-vm-counters-for-transparent-hugepages.patch added to -mm tree
Date: Thu, 24 Mar 2011 14:12:14 +0100 [thread overview]
Message-ID: <20110324131214.GB2310@cmpxchg.org> (raw)
In-Reply-To: <201103050008.p2508U6M011956@imap1.linux-foundation.org>
On Fri, Mar 04, 2011 at 04:08:30PM -0800, akpm@linux-foundation.org wrote:
> diff -puN mm/vmstat.c~mm-add-vm-counters-for-transparent-hugepages mm/vmstat.c
> --- a/mm/vmstat.c~mm-add-vm-counters-for-transparent-hugepages
> +++ a/mm/vmstat.c
> @@ -946,6 +946,14 @@ static const char * const vmstat_text[]
> "unevictable_pgs_stranded",
> "unevictable_pgs_mlockfreed",
> #endif
> +
> +#ifdef CONFIG_TRANSPARENT_HUGEPAGE
> + "thp_fault_alloc",
> + "thp_fault_fallback",
> + "thp_collapse_alloc",
> + "thp_collapse_alloc_failed",
> + "thp_split",
> +#endif
> };
This first #endif in this hunk does not belong to the unevictable
counters, as one could be easily trapped into assuming, it's the
higher level 'vm event counters enabled'. The thp event name strings
should be part of that block as well.
Since there are no zone stat items after the event counters, the only
misbehaviour for now would be having those strings defined on a THP &&
!VM_EVENT_COUNTERS config.
Signed-off-by: Johannes Weiner <hannes@cmpxchg.org>
---
diff --git a/mm/vmstat.c b/mm/vmstat.c
index fca991c..5db50e8 100644
--- a/mm/vmstat.c
+++ b/mm/vmstat.c
@@ -959,7 +959,6 @@ static const char * const vmstat_text[] = {
"unevictable_pgs_cleared",
"unevictable_pgs_stranded",
"unevictable_pgs_mlockfreed",
-#endif
#ifdef CONFIG_TRANSPARENT_HUGEPAGE
"thp_fault_alloc",
@@ -968,6 +967,8 @@ static const char * const vmstat_text[] = {
"thp_collapse_alloc_failed",
"thp_split",
#endif
+
+#endif /* CONFIG_VM_EVENTS_COUNTERS */
};
static void zoneinfo_show_print(struct seq_file *m, pg_data_t *pgdat,
parent reply other threads:[~2011-03-24 13:12 UTC|newest]
Thread overview: expand[flat|nested] mbox.gz Atom feed
[parent not found: <201103050008.p2508U6M011956@imap1.linux-foundation.org>]
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=20110324131214.GB2310@cmpxchg.org \
--to=hannes@cmpxchg.org \
--cc=aarcange@redhat.com \
--cc=ak@linux.intel.com \
--cc=akpm@linux-foundation.org \
--cc=kamezawa.hiroyu@jp.fujitsu.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=mm-commits@vger.kernel.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
all inboxes | Powered by JetHome®