[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <alpine.DEB.2.10.1709201343320.97971@chino.kir.corp.google.com>
Date: Wed, 20 Sep 2017 13:45:33 -0700 (PDT)
From: David Rientjes <rientjes@...gle.com>
To: Yang Shi <yang.s@...baba-inc.com>
cc: cl@...ux.com, penberg@...nel.org, iamjoonsoo.kim@....com,
akpm@...ux-foundation.org, mhocko@...nel.org, linux-mm@...ck.org,
linux-kernel@...r.kernel.org
Subject: Re: [PATCH 1/2] tools: slabinfo: add "-U" option to show unreclaimable
slabs only
On Thu, 21 Sep 2017, Yang Shi wrote:
> diff --git a/tools/vm/slabinfo.c b/tools/vm/slabinfo.c
> index b9d34b3..9673190 100644
> --- a/tools/vm/slabinfo.c
> +++ b/tools/vm/slabinfo.c
> @@ -83,6 +83,7 @@ struct aliasinfo {
> int sort_loss;
> int extended_totals;
> int show_bytes;
> +int unreclaim_only;
>
> /* Debug options */
> int sanity;
> @@ -132,6 +133,7 @@ static void usage(void)
> "-L|--Loss Sort by loss\n"
> "-X|--Xtotals Show extended summary information\n"
> "-B|--Bytes Show size in bytes\n"
> + "-U|--unreclaim Show unreclaimable slabs only\n"
> "\nValid debug options (FZPUT may be combined)\n"
> "a / A Switch on all debug options (=FZUP)\n"
> "- Switch off all debug options\n"
I suppose this should be s/unreclaim/Unreclaim/
> @@ -568,6 +570,9 @@ static void slabcache(struct slabinfo *s)
> if (strcmp(s->name, "*") == 0)
> return;
>
> + if (unreclaim_only && s->reclaim_account)
> + return;
> +
> if (actual_slabs == 1) {
> report(s);
> return;
> @@ -1346,6 +1351,7 @@ struct option opts[] = {
> { "Loss", no_argument, NULL, 'L'},
> { "Xtotals", no_argument, NULL, 'X'},
> { "Bytes", no_argument, NULL, 'B'},
> + { "unreclaim", no_argument, NULL, 'U'},
> { NULL, 0, NULL, 0 }
> };
>
Same.
After that:
Acked-by: David Rientjes <rientjes@...gle.com>
Also, you may find it better to remove the "RFC" tag from the patchset's
header email since it's agreed that we want this.
Powered by blists - more mailing lists