summaryrefslogtreecommitdiff
path: root/kernel-devel/kexec-and-crash-kernel/crashkernel_patches/kexec_fix_arm_braindamage.diff
blob: 877f5ea55dfdbdd9860217489bf87a8a3061ba3f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
Index: kexec-tools-2.0.3/kexec/arch/arm/crashdump-arm.c
===================================================================
--- kexec-tools-2.0.3.orig/kexec/arch/arm/crashdump-arm.c	2011-10-03 00:56:38.000000000 +0200
+++ kexec-tools-2.0.3/kexec/arch/arm/crashdump-arm.c	2013-07-06 17:26:13.410309437 +0200
@@ -204,12 +204,12 @@
  * @cmdline. Note that @cmdline must be at least %COMMAND_LINE_SIZE bytes long
  * (including %NUL).
  */
-static void cmdline_add_mem(char *cmdline, unsigned long size)
+static void cmdline_add_mem(char *cmdline, unsigned long size, unsigned long offset)
 {
 	char buf[COMMAND_LINE_SIZE];
 	int buflen;
 
-	buflen = snprintf(buf, sizeof(buf), "%s mem=%ldK", cmdline, size >> 10);
+	buflen = snprintf(buf, sizeof(buf), "%s mem=%ldK@0x%X", cmdline, size >> 10, offset);
 	if (buflen < 0)
 		die("Failed to construct mem= command line parameter\n");
 	if (buflen >= sizeof(buf))
@@ -301,7 +301,7 @@
 	 * prevents the dump capture kernel from using any other memory regions
 	 * which belong to the primary kernel.
 	 */
-	cmdline_add_mem(mod_cmdline, elfcorehdr - crash_reserved_mem.start);
+	cmdline_add_mem(mod_cmdline, elfcorehdr - crash_reserved_mem.start, crash_reserved_mem.start);
 
 	dump_memory_ranges();
 	dbgprintf("kernel command line: \"%s\"\n", mod_cmdline);