crash: remove an unused argument from reserve_crashkernel_generic()

cmdline argument is not used in reserve_crashkernel_generic() so remove
it.  Correspondingly, all the callers have been updated as well.

No functional change intended.

Link: https://lkml.kernel.org/r/20250131113830.925179-3-sourabhjain@linux.ibm.com
Signed-off-by: Sourabh Jain <sourabhjain@linux.ibm.com>
Acked-by: Hari Bathini <hbathini@linux.ibm.com>
Acked-by: Baoquan He <bhe@redhat.com>
Cc: Madhavan Srinivasan <maddy@linux.ibm.com>
Cc: Mahesh Salgaonkar <mahesh@linux.ibm.com>
Cc: Michael Ellerman <mpe@ellerman.id.au>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
This commit is contained in:
Sourabh Jain 2025-01-31 17:08:25 +05:30 committed by Andrew Morton
parent 9986fb5164
commit 7b54a96f30
6 changed files with 17 additions and 26 deletions

View File

@ -98,21 +98,19 @@ static void __init arch_reserve_crashkernel(void)
{ {
unsigned long long low_size = 0; unsigned long long low_size = 0;
unsigned long long crash_base, crash_size; unsigned long long crash_base, crash_size;
char *cmdline = boot_command_line;
bool high = false; bool high = false;
int ret; int ret;
if (!IS_ENABLED(CONFIG_CRASH_RESERVE)) if (!IS_ENABLED(CONFIG_CRASH_RESERVE))
return; return;
ret = parse_crashkernel(cmdline, memblock_phys_mem_size(), ret = parse_crashkernel(boot_command_line, memblock_phys_mem_size(),
&crash_size, &crash_base, &crash_size, &crash_base,
&low_size, &high); &low_size, &high);
if (ret) if (ret)
return; return;
reserve_crashkernel_generic(cmdline, crash_size, crash_base, reserve_crashkernel_generic(crash_size, crash_base, low_size, high);
low_size, high);
} }
static phys_addr_t __init max_zone_phys(phys_addr_t zone_limit) static phys_addr_t __init max_zone_phys(phys_addr_t zone_limit)

View File

@ -259,18 +259,17 @@ static void __init arch_reserve_crashkernel(void)
int ret; int ret;
unsigned long long low_size = 0; unsigned long long low_size = 0;
unsigned long long crash_base, crash_size; unsigned long long crash_base, crash_size;
char *cmdline = boot_command_line;
bool high = false; bool high = false;
if (!IS_ENABLED(CONFIG_CRASH_RESERVE)) if (!IS_ENABLED(CONFIG_CRASH_RESERVE))
return; return;
ret = parse_crashkernel(cmdline, memblock_phys_mem_size(), ret = parse_crashkernel(boot_command_line, memblock_phys_mem_size(),
&crash_size, &crash_base, &low_size, &high); &crash_size, &crash_base, &low_size, &high);
if (ret) if (ret)
return; return;
reserve_crashkernel_generic(cmdline, crash_size, crash_base, low_size, high); reserve_crashkernel_generic(crash_size, crash_base, low_size, high);
} }
static void __init fdt_setup(void) static void __init fdt_setup(void)

View File

@ -1396,21 +1396,19 @@ static void __init arch_reserve_crashkernel(void)
{ {
unsigned long long low_size = 0; unsigned long long low_size = 0;
unsigned long long crash_base, crash_size; unsigned long long crash_base, crash_size;
char *cmdline = boot_command_line;
bool high = false; bool high = false;
int ret; int ret;
if (!IS_ENABLED(CONFIG_CRASH_RESERVE)) if (!IS_ENABLED(CONFIG_CRASH_RESERVE))
return; return;
ret = parse_crashkernel(cmdline, memblock_phys_mem_size(), ret = parse_crashkernel(boot_command_line, memblock_phys_mem_size(),
&crash_size, &crash_base, &crash_size, &crash_base,
&low_size, &high); &low_size, &high);
if (ret) if (ret)
return; return;
reserve_crashkernel_generic(cmdline, crash_size, crash_base, reserve_crashkernel_generic(crash_size, crash_base, low_size, high);
low_size, high);
} }
void __init paging_init(void) void __init paging_init(void)

View File

@ -472,14 +472,13 @@ static void __init memblock_x86_reserve_range_setup_data(void)
static void __init arch_reserve_crashkernel(void) static void __init arch_reserve_crashkernel(void)
{ {
unsigned long long crash_base, crash_size, low_size = 0; unsigned long long crash_base, crash_size, low_size = 0;
char *cmdline = boot_command_line;
bool high = false; bool high = false;
int ret; int ret;
if (!IS_ENABLED(CONFIG_CRASH_RESERVE)) if (!IS_ENABLED(CONFIG_CRASH_RESERVE))
return; return;
ret = parse_crashkernel(cmdline, memblock_phys_mem_size(), ret = parse_crashkernel(boot_command_line, memblock_phys_mem_size(),
&crash_size, &crash_base, &crash_size, &crash_base,
&low_size, &high); &low_size, &high);
if (ret) if (ret)
@ -490,8 +489,7 @@ static void __init arch_reserve_crashkernel(void)
return; return;
} }
reserve_crashkernel_generic(cmdline, crash_size, crash_base, reserve_crashkernel_generic(crash_size, crash_base, low_size, high);
low_size, high);
} }
static struct resource standard_io_resources[] = { static struct resource standard_io_resources[] = {

View File

@ -32,13 +32,12 @@ int __init parse_crashkernel(char *cmdline, unsigned long long system_ram,
#define CRASH_ADDR_HIGH_MAX memblock_end_of_DRAM() #define CRASH_ADDR_HIGH_MAX memblock_end_of_DRAM()
#endif #endif
void __init reserve_crashkernel_generic(char *cmdline, void __init reserve_crashkernel_generic(unsigned long long crash_size,
unsigned long long crash_size,
unsigned long long crash_base, unsigned long long crash_base,
unsigned long long crash_low_size, unsigned long long crash_low_size,
bool high); bool high);
#else #else
static inline void __init reserve_crashkernel_generic(char *cmdline, static inline void __init reserve_crashkernel_generic(
unsigned long long crash_size, unsigned long long crash_size,
unsigned long long crash_base, unsigned long long crash_base,
unsigned long long crash_low_size, unsigned long long crash_low_size,

View File

@ -375,8 +375,7 @@ static int __init reserve_crashkernel_low(unsigned long long low_size)
return 0; return 0;
} }
void __init reserve_crashkernel_generic(char *cmdline, void __init reserve_crashkernel_generic(unsigned long long crash_size,
unsigned long long crash_size,
unsigned long long crash_base, unsigned long long crash_base,
unsigned long long crash_low_size, unsigned long long crash_low_size,
bool high) bool high)