summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorYouling Tang <tangyouling@loongson.cn>2020-09-12 09:32:24 +0800
committerSimon Horman <horms@verge.net.au>2020-09-25 07:55:22 +0200
commit7bd251654aadae993eb7d15ce1b39f61e9cee41a (patch)
treee4cfd6ae369e60b4e4fd73aee2e9915abaa07a07
parenta47b10c457eb6b353c81d15a4662cdf298e519ac (diff)
downloadkexec-tools-7bd251654aadae993eb7d15ce1b39f61e9cee41a.tar.gz
kexec-tools: mips: Remove commandline parameter "mem"
"mem=" indicating the memory region the new kernel can use to boot into. And passed to the dump-capture kernel by kernel commandline parameter "mem=". But in the dump-capture kernel, we don’t need to use this parameter now, so remove "mem" and don't add "mem=" to new kernel commandline. Signed-off-by: Youling Tang <tangyouling@loongson.cn> Signed-off-by: Simon Horman <horms@verge.net.au>
-rw-r--r--kexec/arch/mips/crashdump-mips.c29
1 files changed, 0 insertions, 29 deletions
diff --git a/kexec/arch/mips/crashdump-mips.c b/kexec/arch/mips/crashdump-mips.c
index fc92e646..26d5043f 100644
--- a/kexec/arch/mips/crashdump-mips.c
+++ b/kexec/arch/mips/crashdump-mips.c
@@ -243,33 +243,6 @@ static void ultoa(unsigned long i, char *str)
}
}
-/* Adds the appropriate mem= options to command line, indicating the
- * memory region the new kernel can use to boot into. */
-static int cmdline_add_mem(char *cmdline, unsigned long addr,
- unsigned long size)
-{
- int cmdlen, len;
- char str[50], *ptr;
-
- addr = addr/1024;
- size = size/1024;
- ptr = str;
- strcpy(str, " mem=");
- ptr += strlen(str);
- ultoa(size, ptr);
- strcat(str, "K@");
- ptr = str + strlen(str);
- ultoa(addr, ptr);
- strcat(str, "K");
- len = strlen(str);
- cmdlen = strlen(cmdline) + len;
- if (cmdlen > (COMMAND_LINE_SIZE - 1))
- die("Command line overflow\n");
- strcat(cmdline, str);
-
- return 0;
-}
-
/* Adds the elfcorehdr= command line parameter to command line. */
static int cmdline_add_elfcorehdr(char *cmdline, unsigned long addr)
{
@@ -397,8 +370,6 @@ int load_crashdump_segments(struct kexec_info *info, char* mod_cmdline,
* backup segment is after elfcorehdr, so use elfcorehdr as top of
* kernel's available memory
*/
- cmdline_add_mem(mod_cmdline, crash_reserved_mem.start,
- elfcorehdr - crash_reserved_mem.start);
cmdline_add_elfcorehdr(mod_cmdline, elfcorehdr);
dbgprintf("CRASH MEMORY RANGES:\n");