Commit 0dac8f6b authored by Vasily Gorbik's avatar Vasily Gorbik Committed by Martin Schwidefsky

s390/mm: add kasan shadow to the debugfs pgtable dump

This change adds address space markers for kasan shadow memory.
Reviewed-by: default avatarMartin Schwidefsky <schwidefsky@de.ibm.com>
Signed-off-by: default avatarVasily Gorbik <gor@linux.ibm.com>
Signed-off-by: default avatarMartin Schwidefsky <schwidefsky@de.ibm.com>
parent b6cbe3e8
...@@ -3,6 +3,7 @@ ...@@ -3,6 +3,7 @@
#include <linux/debugfs.h> #include <linux/debugfs.h>
#include <linux/sched.h> #include <linux/sched.h>
#include <linux/mm.h> #include <linux/mm.h>
#include <asm/kasan.h>
#include <asm/sections.h> #include <asm/sections.h>
#include <asm/pgtable.h> #include <asm/pgtable.h>
...@@ -17,18 +18,26 @@ enum address_markers_idx { ...@@ -17,18 +18,26 @@ enum address_markers_idx {
IDENTITY_NR = 0, IDENTITY_NR = 0,
KERNEL_START_NR, KERNEL_START_NR,
KERNEL_END_NR, KERNEL_END_NR,
#ifdef CONFIG_KASAN
KASAN_SHADOW_START_NR,
KASAN_SHADOW_END_NR,
#endif
VMEMMAP_NR, VMEMMAP_NR,
VMALLOC_NR, VMALLOC_NR,
MODULES_NR, MODULES_NR,
}; };
static struct addr_marker address_markers[] = { static struct addr_marker address_markers[] = {
[IDENTITY_NR] = {0, "Identity Mapping"}, [IDENTITY_NR] = {0, "Identity Mapping"},
[KERNEL_START_NR] = {(unsigned long)_stext, "Kernel Image Start"}, [KERNEL_START_NR] = {(unsigned long)_stext, "Kernel Image Start"},
[KERNEL_END_NR] = {(unsigned long)_end, "Kernel Image End"}, [KERNEL_END_NR] = {(unsigned long)_end, "Kernel Image End"},
[VMEMMAP_NR] = {0, "vmemmap Area"}, #ifdef CONFIG_KASAN
[VMALLOC_NR] = {0, "vmalloc Area"}, [KASAN_SHADOW_START_NR] = {KASAN_SHADOW_START, "Kasan Shadow Start"},
[MODULES_NR] = {0, "Modules Area"}, [KASAN_SHADOW_END_NR] = {KASAN_SHADOW_END, "Kasan Shadow End"},
#endif
[VMEMMAP_NR] = {0, "vmemmap Area"},
[VMALLOC_NR] = {0, "vmalloc Area"},
[MODULES_NR] = {0, "Modules Area"},
{ -1, NULL } { -1, NULL }
}; };
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment