diff options
author | Helge Deller <deller@gmx.de> | 2018-01-12 22:57:15 +0100 |
---|---|---|
committer | Helge Deller <deller@gmx.de> | 2018-03-02 10:04:35 +0100 |
commit | fd8d0ca2563151204f3fe555dc8ca4bcfe8677a3 (patch) | |
tree | 7a0d974c8991b8813a604d9e70145194329f080f | |
parent | 0adb24e03a124b79130c9499731936b11ce2677d (diff) |
parisc: Hide virtual kernel memory layout
For security reasons do not expose the virtual kernel memory layout to
userspace.
Signed-off-by: Helge Deller <deller@gmx.de>
Suggested-by: Kees Cook <keescook@chromium.org>
Cc: stable@vger.kernel.org # 4.15
Reviewed-by: Kees Cook <keescook@chromium.org>
-rw-r--r-- | arch/parisc/mm/init.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/arch/parisc/mm/init.c b/arch/parisc/mm/init.c index 48f41399fc0b..cab32ee824d2 100644 --- a/arch/parisc/mm/init.c +++ b/arch/parisc/mm/init.c @@ -629,7 +629,12 @@ void __init mem_init(void) #endif mem_init_print_info(NULL); -#ifdef CONFIG_DEBUG_KERNEL /* double-sanity-check paranoia */ + +#if 0 + /* + * Do not expose the virtual kernel memory layout to userspace. + * But keep code for debugging purposes. + */ printk("virtual kernel memory layout:\n" " vmalloc : 0x%px - 0x%px (%4ld MB)\n" " memory : 0x%px - 0x%px (%4ld MB)\n" |