]> git.baikalelectronics.ru Git - kernel.git/commitdiff
riscv: mm: init: remove unnecessary "#ifdef CONFIG_CRASH_DUMP"
authorJisheng Zhang <jszhang@kernel.org>
Mon, 6 Dec 2021 15:03:49 +0000 (23:03 +0800)
committerPalmer Dabbelt <palmer@rivosinc.com>
Wed, 19 Jan 2022 17:56:30 +0000 (09:56 -0800)
The is_kdump_kernel() returns false for !CRASH_DUMP case, so we don't
need the #ifdef CONFIG_CRASH_DUMP for is_kdump_kernel() checking.

Signed-off-by: Jisheng Zhang <jszhang@kernel.org>
Reviewed-by: Alexandre Ghiti <alex@ghiti.fr>
Signed-off-by: Palmer Dabbelt <palmer@rivosinc.com>
arch/riscv/mm/init.c

index 0624c68331d82ec13857526f3ffcc33358e38e66..122352823835a48e92b9e81f7183393a22a712d6 100644 (file)
@@ -791,12 +791,10 @@ static void __init reserve_crashkernel(void)
         * since it doesn't make much sense and we have limited memory
         * resources.
         */
-#ifdef CONFIG_CRASH_DUMP
        if (is_kdump_kernel()) {
                pr_info("crashkernel: ignoring reservation request\n");
                return;
        }
-#endif
 
        ret = parse_crashkernel(boot_command_line, memblock_phys_mem_size(),
                                &crash_size, &crash_base);