x86: use BOOTMEM_EXCLUSIVE on 32-bit

This patch uses the BOOTMEM_EXCLUSIVE for crashkernel reservation also for
i386 and prints a error message on failure.

The patch is still for 2.6.26 since it is only bug fixing. The unification
of reserve_crashkernel() between i386 and x86_64 should be done for 2.6.27.

Signed-off-by: Bernhard Walle <bwalle@suse.de>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Cc: <stable@kernel.org>

authored by Bernhard Walle and committed by Ingo Molnar d3942cff df17b1d9

+8 -2
+8 -2
arch/x86/kernel/setup_32.c
··· 532 (unsigned long)(crash_size >> 20), 533 (unsigned long)(crash_base >> 20), 534 (unsigned long)(total_mem >> 20)); 535 crashk_res.start = crash_base; 536 crashk_res.end = crash_base + crash_size - 1; 537 - reserve_bootmem(crash_base, crash_size, 538 - BOOTMEM_DEFAULT); 539 } else 540 printk(KERN_INFO "crashkernel reservation failed - " 541 "you have to specify a base address\n");
··· 532 (unsigned long)(crash_size >> 20), 533 (unsigned long)(crash_base >> 20), 534 (unsigned long)(total_mem >> 20)); 535 + 536 + if (reserve_bootmem(crash_base, crash_size, 537 + BOOTMEM_EXCLUSIVE) < 0) { 538 + printk(KERN_INFO "crashkernel reservation " 539 + "failed - memory is in use\n"); 540 + return; 541 + } 542 + 543 crashk_res.start = crash_base; 544 crashk_res.end = crash_base + crash_size - 1; 545 } else 546 printk(KERN_INFO "crashkernel reservation failed - " 547 "you have to specify a base address\n");