Skip to content

Commit 53b90c0

Browse files
suryasaimadhuIngo Molnar
authored andcommitted
kexec/crash: Say which char is the unrecognized
It is helpful when the crashkernel cmdline parsing routines actually say which character is the unrecognized one. Make them do so. Signed-off-by: Borislav Petkov <[email protected]> Reviewed-by: Dave Young <[email protected]> Reviewed-by: Joerg Roedel <[email protected]> Cc: Andrew Morton <[email protected]> Cc: Andy Lutomirski <[email protected]> Cc: Baoquan He <[email protected]> Cc: H. Peter Anvin <[email protected]> Cc: Jiri Kosina <[email protected]> Cc: Juergen Gross <[email protected]> Cc: Linus Torvalds <[email protected]> Cc: Mark Salter <[email protected]> Cc: Peter Zijlstra <[email protected]> Cc: Thomas Gleixner <[email protected]> Cc: Vivek Goyal <[email protected]> Cc: WANG Chao <[email protected]> Cc: [email protected] Link: http://lkml.kernel.org/r/[email protected] Signed-off-by: Ingo Molnar <[email protected]>
1 parent 6f37605 commit 53b90c0

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

kernel/kexec_core.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1149,7 +1149,7 @@ static int __init parse_crashkernel_simple(char *cmdline,
11491149
if (*cur == '@')
11501150
*crash_base = memparse(cur+1, &cur);
11511151
else if (*cur != ' ' && *cur != '\0') {
1152-
pr_warn("crashkernel: unrecognized char\n");
1152+
pr_warn("crashkernel: unrecognized char: %c\n", *cur);
11531153
return -EINVAL;
11541154
}
11551155

@@ -1186,12 +1186,12 @@ static int __init parse_crashkernel_suffix(char *cmdline,
11861186

11871187
/* check with suffix */
11881188
if (strncmp(cur, suffix, strlen(suffix))) {
1189-
pr_warn("crashkernel: unrecognized char\n");
1189+
pr_warn("crashkernel: unrecognized char: %c\n", *cur);
11901190
return -EINVAL;
11911191
}
11921192
cur += strlen(suffix);
11931193
if (*cur != ' ' && *cur != '\0') {
1194-
pr_warn("crashkernel: unrecognized char\n");
1194+
pr_warn("crashkernel: unrecognized char: %c\n", *cur);
11951195
return -EINVAL;
11961196
}
11971197

0 commit comments

Comments
 (0)