diff options
author | Yinghai Lu <Yinghai.Lu@Sun.COM> | 2008-02-22 20:07:16 -0500 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2008-04-17 11:40:49 -0400 |
commit | 3def3d6ddf43dbe20c00c3cbc38dfacc8586998f (patch) | |
tree | 0d9b56966bc5c525d9d3a1be66e8ccd9d476e589 /arch/x86/kernel/setup_64.c | |
parent | 700efc1b9f6afe34caae231b87d129ad8ffb559f (diff) |
x86: clean up e820_reserve_resources on 64-bit
e820_resource_resources could use insert_resource instead of request_resource
also move code_resource, data_resource, bss_resource, and crashk_res
out of e820_reserve_resources.
Signed-off-by: Yinghai Lu <yinghai.lu@sun.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'arch/x86/kernel/setup_64.c')
-rw-r--r-- | arch/x86/kernel/setup_64.c | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/arch/x86/kernel/setup_64.c b/arch/x86/kernel/setup_64.c index 187f084b949..e3cb3ea96ca 100644 --- a/arch/x86/kernel/setup_64.c +++ b/arch/x86/kernel/setup_64.c | |||
@@ -248,6 +248,7 @@ static void __init reserve_crashkernel(void) | |||
248 | (unsigned long)(total_mem >> 20)); | 248 | (unsigned long)(total_mem >> 20)); |
249 | crashk_res.start = crash_base; | 249 | crashk_res.start = crash_base; |
250 | crashk_res.end = crash_base + crash_size - 1; | 250 | crashk_res.end = crash_base + crash_size - 1; |
251 | insert_resource(&iomem_resource, &crashk_res); | ||
251 | } | 252 | } |
252 | } | 253 | } |
253 | #else | 254 | #else |
@@ -322,6 +323,11 @@ void __init setup_arch(char **cmdline_p) | |||
322 | 323 | ||
323 | finish_e820_parsing(); | 324 | finish_e820_parsing(); |
324 | 325 | ||
326 | /* after parse_early_param, so could debug it */ | ||
327 | insert_resource(&iomem_resource, &code_resource); | ||
328 | insert_resource(&iomem_resource, &data_resource); | ||
329 | insert_resource(&iomem_resource, &bss_resource); | ||
330 | |||
325 | early_gart_iommu_check(); | 331 | early_gart_iommu_check(); |
326 | 332 | ||
327 | e820_register_active_regions(0, 0, -1UL); | 333 | e820_register_active_regions(0, 0, -1UL); |
@@ -454,7 +460,7 @@ void __init setup_arch(char **cmdline_p) | |||
454 | /* | 460 | /* |
455 | * We trust e820 completely. No explicit ROM probing in memory. | 461 | * We trust e820 completely. No explicit ROM probing in memory. |
456 | */ | 462 | */ |
457 | e820_reserve_resources(&code_resource, &data_resource, &bss_resource); | 463 | e820_reserve_resources(); |
458 | e820_mark_nosave_regions(); | 464 | e820_mark_nosave_regions(); |
459 | 465 | ||
460 | /* request I/O space for devices used on all i[345]86 PCs */ | 466 | /* request I/O space for devices used on all i[345]86 PCs */ |