[PATCH 09/26] mm/show_mem: Annotate static information into meminspect

From: Eugen Hristev

Date: Wed Nov 19 2025 - 10:45:34 EST


Annotate vital static information into inspection table:
- _totalram_pages

Information on these variables is stored into dedicated inspection section.

Signed-off-by: Eugen Hristev <eugen.hristev@xxxxxxxxxx>
---
mm/show_mem.c | 2 ++
1 file changed, 2 insertions(+)

diff --git a/mm/show_mem.c b/mm/show_mem.c
index 3a4b5207635d..be9cded4acdb 100644
--- a/mm/show_mem.c
+++ b/mm/show_mem.c
@@ -14,12 +14,14 @@
#include <linux/mmzone.h>
#include <linux/swap.h>
#include <linux/vmstat.h>
+#include <linux/meminspect.h>

#include "internal.h"
#include "swap.h"

atomic_long_t _totalram_pages __read_mostly;
EXPORT_SYMBOL(_totalram_pages);
+MEMINSPECT_SIMPLE_ENTRY(_totalram_pages);
unsigned long totalreserve_pages __read_mostly;
unsigned long totalcma_pages __read_mostly;

--
2.43.0