]> git.baikalelectronics.ru Git - kernel.git/commitdiff
s390/setup: cleanup reserve/remove_oldmem
authorVasily Gorbik <gor@linux.ibm.com>
Thu, 8 Oct 2020 13:07:27 +0000 (15:07 +0200)
committerVasily Gorbik <gor@linux.ibm.com>
Fri, 18 Jun 2021 14:41:19 +0000 (16:41 +0200)
Since OLDMEM_BASE/OLDMEM_SIZE is already taken into consideration and is
reflected in ident_map_size. reserve/remove_oldmem() is no longer needed
and could be removed.

Reviewed-by: Alexander Gordeev <agordeev@linux.ibm.com>
Signed-off-by: Vasily Gorbik <gor@linux.ibm.com>
arch/s390/kernel/setup.c

index 9145ef983f38634fcf3f0e065c57f33503027f38..b58ee83f30e38439ded156d9f8757ac23f98c00a 100644 (file)
@@ -585,30 +585,6 @@ static void __init reserve_above_ident_map(void)
        memblock_reserve(ident_map_size, ULONG_MAX);
 }
 
-/*
- * Make sure that oldmem, where the dump is stored, is protected
- */
-static void __init reserve_oldmem(void)
-{
-#ifdef CONFIG_CRASH_DUMP
-       if (OLDMEM_BASE)
-               /* Forget all memory above the running kdump system */
-               memblock_reserve(OLDMEM_SIZE, (phys_addr_t)ULONG_MAX);
-#endif
-}
-
-/*
- * Make sure that oldmem, where the dump is stored, is protected
- */
-static void __init remove_oldmem(void)
-{
-#ifdef CONFIG_CRASH_DUMP
-       if (OLDMEM_BASE)
-               /* Forget all memory above the running kdump system */
-               memblock_remove(OLDMEM_SIZE, (phys_addr_t)ULONG_MAX);
-#endif
-}
-
 /*
  * Reserve memory for kdump kernel to be loaded with kexec
  */
@@ -1074,7 +1050,6 @@ void __init setup_arch(char **cmdline_p)
 
        /* Do some memory reservations *before* memory is added to memblock */
        reserve_above_ident_map();
-       reserve_oldmem();
        reserve_kernel();
        reserve_initrd();
        reserve_certificate_list();
@@ -1085,7 +1060,6 @@ void __init setup_arch(char **cmdline_p)
        memblock_add_mem_detect_info();
 
        free_mem_detect_info();
-       remove_oldmem();
 
        setup_uv();
        setup_memory_end();