lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  PHC 
Open Source and information security mailing list archives
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Date:	Tue, 21 Oct 2014 01:27:14 +0200
From:	Petr Holasek <>
Cc:	David Rientjes <>,
	Dave Hansen <>,
Subject: [RFC][PATCH] add pagesize field to /proc/pid/numa_maps

There were some similar attempts to add vma's pagesize to numa_maps in the past,
so I've distilled the most straightforward one - adding pagesize field
expressing size in kbytes to each line. Although page size can be also obtained
from smaps file, adding pagesize to numa_maps makes the interface more compact
and easier to use without need for traversing other files.

New numa_maps output looks like that:

2aaaaac00000 default file=/dev/hugepages/hugepagefile huge pagesize=2097152 dirty=1 N0=1
7f302441a000 default file=/usr/lib64/ pagesize=4096 mapped=65 mapmax=38 N0=65

Signed-off-by: Petr Holasek <>
 fs/proc/task_mmu.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/fs/proc/task_mmu.c b/fs/proc/task_mmu.c
index 4e0388c..964c4de 100644
--- a/fs/proc/task_mmu.c
+++ b/fs/proc/task_mmu.c
@@ -1498,6 +1498,9 @@ static int show_numa_map(struct seq_file *m, void *v, int is_pid)
 	if (!md->pages)
 		goto out;
+	seq_puts(m, " pagesize=");
+	seq_printf(m, "%lu", vma_kernel_pagesize(vma));
 	if (md->anon)
 		seq_printf(m, " anon=%lu", md->anon);

To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to
More majordomo info at
Please read the FAQ at

Powered by blists - more mailing lists