From aa7f8fc315d0276f6253c02466f7655ad8f45e49 Mon Sep 17 00:00:00 2001 From: Chris Wilson <chris@chris-wilson.co.uk> Date: Mon, 1 Jul 2019 15:29:03 +0100 Subject: [PATCH] mm: Show slab debug as offsets from section base not hashed pointers Since the kernel now used hashed pointers for raw addresses, it is very hard to guage the relative placement within a section, and since the hash value will never match up with any contents, using it provides no information relevant for slab debugging. Show the relative offset into each section, so that some reference for the hexdump is provided. References: https://gitlab.freedesktop.org/drm/intel/-/issues/8038 Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Signed-off-by: Rodrigo Vivi <rodrigo.vivi@intel.com> --- mm/slub.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mm/slub.c b/mm/slub.c index 19980419b176c..509f54bd3b4b1 100644 --- a/mm/slub.c +++ b/mm/slub.c @@ -909,7 +909,7 @@ static void print_section(char *level, char *text, u8 *addr, unsigned int length) { metadata_access_enable(); - print_hex_dump(level, text, DUMP_PREFIX_ADDRESS, + print_hex_dump(level, text, DUMP_PREFIX_OFFSET, 16, 1, kasan_reset_tag((void *)addr), length, 1); metadata_access_disable(); } -- GitLab