Skip to content

Commit a3e1c3b

Browse files
lian-boingomolnar
authored andcommitted
x86/crash: Correct the address boundary of function parameters
Let's carefully handle the boundary of the function parameter to make sure that the arguments passed doesn't exceed the address range. Signed-off-by: Lianbo Jiang <lijiang@redhat.com> Signed-off-by: Ingo Molnar <mingo@kernel.org> Acked-by: Dave Young <dyoung@redhat.com> Link: https://lore.kernel.org/r/20200804044933.1973-2-lijiang@redhat.com
1 parent 4c7bfa3 commit a3e1c3b

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

arch/x86/kernel/crash.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -230,7 +230,7 @@ static int elf_header_exclude_ranges(struct crash_mem *cmem)
230230
int ret = 0;
231231

232232
/* Exclude the low 1M because it is always reserved */
233-
ret = crash_exclude_mem_range(cmem, 0, 1<<20);
233+
ret = crash_exclude_mem_range(cmem, 0, (1<<20)-1);
234234
if (ret)
235235
return ret;
236236

0 commit comments

Comments
 (0)