All of lore.kernel.org
 help / color / mirror / Atom feed
From: Samuel Williams <samuel.williams@oriontransfer.co.nz>
To: adobriyan@gmail.com, linux-fsdevel@vger.kernel.org
Cc: Samuel Williams <samuel.williams@oriontransfer.co.nz>
Subject: [PATCH v2] Fix alignment of value in /proc/$pid/smaps
Date: Mon, 30 Dec 2019 21:41:25 +1300	[thread overview]
Message-ID: <20191230084125.267040-1-samuel.williams@oriontransfer.co.nz> (raw)
In-Reply-To: <20191230045303.226623-1-samuel.williams () oriontransfer ! co ! nz>

The /proc/$pid/smaps output has an alignment issue for the field
FilePmdMapped and THPeligible.

Increases the alignment of FilePmdMapped by 1 space, and converts the
alignment of THPeligible to use spaces instead of tabs, to be consistent
with the other fields.

Signed-off-by: Samuel Williams <samuel.williams@oriontransfer.co.nz>
---
Changes in v2:
  - Add missing "Signed-off-by". My sincere apologies for missing this.

 fs/proc/task_mmu.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/fs/proc/task_mmu.c b/fs/proc/task_mmu.c
index 9442631fd4af..f7ca20af2371 100644
--- a/fs/proc/task_mmu.c
+++ b/fs/proc/task_mmu.c
@@ -810,7 +810,7 @@ static void __show_smap(struct seq_file *m, const struct mem_size_stats *mss,
 	SEQ_PUT_DEC(" kB\nLazyFree:       ", mss->lazyfree);
 	SEQ_PUT_DEC(" kB\nAnonHugePages:  ", mss->anonymous_thp);
 	SEQ_PUT_DEC(" kB\nShmemPmdMapped: ", mss->shmem_thp);
-	SEQ_PUT_DEC(" kB\nFilePmdMapped: ", mss->file_thp);
+	SEQ_PUT_DEC(" kB\nFilePmdMapped:  ", mss->file_thp);
 	SEQ_PUT_DEC(" kB\nShared_Hugetlb: ", mss->shared_hugetlb);
 	seq_put_decimal_ull_width(m, " kB\nPrivate_Hugetlb: ",
 				  mss->private_hugetlb >> 10, 7);
@@ -840,7 +840,7 @@ static int show_smap(struct seq_file *m, void *v)
 
 	__show_smap(m, &mss, false);
 
-	seq_printf(m, "THPeligible:		%d\n",
+	seq_printf(m, "THPeligible:           %d\n",
 		   transparent_hugepage_enabled(vma));
 
 	if (arch_pkeys_enabled())
-- 
2.24.1


       reply	other threads:[~2019-12-30  8:42 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <20191230045303.226623-1-samuel.williams () oriontransfer ! co ! nz>
2019-12-30  8:41 ` Samuel Williams [this message]
2020-04-02 12:48   ` [PATCH v2] Fix alignment of value in /proc/$pid/smaps Kirill A. Shutemov

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=20191230084125.267040-1-samuel.williams@oriontransfer.co.nz \
    --to=samuel.williams@oriontransfer.co.nz \
    --cc=adobriyan@gmail.com \
    --cc=linux-fsdevel@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.