diff options
author | Yinghai Lu <yhlu.kernel@gmail.com> | 2008-06-15 21:58:51 -0400 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2008-07-08 04:37:01 -0400 |
commit | d0be6bdea103b8d04c8a3495538b7c0011ae4129 (patch) | |
tree | b2f40f629457feda4e20eb145ed6e4b676f6effd /arch/x86/kernel | |
parent | 6df8809bbd1b48cc6d428df7372ed749c8711641 (diff) |
x86: rename two e820 related functions
rename update_memory_range to e820_update_range
rename add_memory_region to e820_add_region
to make it more clear that they are about e820 map operations.
Signed-off-by: Yinghai Lu <yhlu.kernel@gmail.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'arch/x86/kernel')
-rw-r--r-- | arch/x86/kernel/aperture_64.c | 2 | ||||
-rw-r--r-- | arch/x86/kernel/cpu/mtrr/main.c | 2 | ||||
-rw-r--r-- | arch/x86/kernel/e820.c | 16 | ||||
-rw-r--r-- | arch/x86/kernel/efi.c | 2 |
4 files changed, 11 insertions, 11 deletions
diff --git a/arch/x86/kernel/aperture_64.c b/arch/x86/kernel/aperture_64.c index 479926d9e004..66b140932b23 100644 --- a/arch/x86/kernel/aperture_64.c +++ b/arch/x86/kernel/aperture_64.c | |||
@@ -292,7 +292,7 @@ void __init early_gart_iommu_check(void) | |||
292 | E820_RAM)) { | 292 | E820_RAM)) { |
293 | /* reserved it, so we can resuse it in second kernel */ | 293 | /* reserved it, so we can resuse it in second kernel */ |
294 | printk(KERN_INFO "update e820 for GART\n"); | 294 | printk(KERN_INFO "update e820 for GART\n"); |
295 | add_memory_region(aper_base, aper_size, E820_RESERVED); | 295 | e820_add_region(aper_base, aper_size, E820_RESERVED); |
296 | update_e820(); | 296 | update_e820(); |
297 | } | 297 | } |
298 | return; | 298 | return; |
diff --git a/arch/x86/kernel/cpu/mtrr/main.c b/arch/x86/kernel/cpu/mtrr/main.c index 0642201784e0..105afe12beb0 100644 --- a/arch/x86/kernel/cpu/mtrr/main.c +++ b/arch/x86/kernel/cpu/mtrr/main.c | |||
@@ -1440,7 +1440,7 @@ static u64 __init real_trim_memory(unsigned long start_pfn, | |||
1440 | trim_size <<= PAGE_SHIFT; | 1440 | trim_size <<= PAGE_SHIFT; |
1441 | trim_size -= trim_start; | 1441 | trim_size -= trim_start; |
1442 | 1442 | ||
1443 | return update_memory_range(trim_start, trim_size, E820_RAM, | 1443 | return e820_update_range(trim_start, trim_size, E820_RAM, |
1444 | E820_RESERVED); | 1444 | E820_RESERVED); |
1445 | } | 1445 | } |
1446 | /** | 1446 | /** |
diff --git a/arch/x86/kernel/e820.c b/arch/x86/kernel/e820.c index 774063f11be0..5051ce744b4e 100644 --- a/arch/x86/kernel/e820.c +++ b/arch/x86/kernel/e820.c | |||
@@ -94,7 +94,7 @@ int __init e820_all_mapped(u64 start, u64 end, unsigned type) | |||
94 | /* | 94 | /* |
95 | * Add a memory region to the kernel e820 map. | 95 | * Add a memory region to the kernel e820 map. |
96 | */ | 96 | */ |
97 | void __init add_memory_region(u64 start, u64 size, int type) | 97 | void __init e820_add_region(u64 start, u64 size, int type) |
98 | { | 98 | { |
99 | int x = e820.nr_map; | 99 | int x = e820.nr_map; |
100 | 100 | ||
@@ -384,12 +384,12 @@ int __init copy_e820_map(struct e820entry *biosmap, int nr_map) | |||
384 | if (start > end) | 384 | if (start > end) |
385 | return -1; | 385 | return -1; |
386 | 386 | ||
387 | add_memory_region(start, size, type); | 387 | e820_add_region(start, size, type); |
388 | } while (biosmap++, --nr_map); | 388 | } while (biosmap++, --nr_map); |
389 | return 0; | 389 | return 0; |
390 | } | 390 | } |
391 | 391 | ||
392 | u64 __init update_memory_range(u64 start, u64 size, unsigned old_type, | 392 | u64 __init e820_update_range(u64 start, u64 size, unsigned old_type, |
393 | unsigned new_type) | 393 | unsigned new_type) |
394 | { | 394 | { |
395 | int i; | 395 | int i; |
@@ -414,7 +414,7 @@ u64 __init update_memory_range(u64 start, u64 size, unsigned old_type, | |||
414 | final_end = min(start + size, ei->addr + ei->size); | 414 | final_end = min(start + size, ei->addr + ei->size); |
415 | if (final_start >= final_end) | 415 | if (final_start >= final_end) |
416 | continue; | 416 | continue; |
417 | add_memory_region(final_start, final_end - final_start, | 417 | e820_add_region(final_start, final_end - final_start, |
418 | new_type); | 418 | new_type); |
419 | real_updated_size += final_end - final_start; | 419 | real_updated_size += final_end - final_start; |
420 | } | 420 | } |
@@ -774,7 +774,7 @@ u64 __init early_reserve_e820(u64 startt, u64 sizet, u64 align) | |||
774 | return 0; | 774 | return 0; |
775 | 775 | ||
776 | addr = round_down(start + size - sizet, align); | 776 | addr = round_down(start + size - sizet, align); |
777 | update_memory_range(addr, sizet, E820_RAM, E820_RESERVED); | 777 | e820_update_range(addr, sizet, E820_RAM, E820_RESERVED); |
778 | printk(KERN_INFO "update e820 for early_reserve_e820\n"); | 778 | printk(KERN_INFO "update e820 for early_reserve_e820\n"); |
779 | update_e820(); | 779 | update_e820(); |
780 | 780 | ||
@@ -949,13 +949,13 @@ static int __init parse_memmap_opt(char *p) | |||
949 | userdef = 1; | 949 | userdef = 1; |
950 | if (*p == '@') { | 950 | if (*p == '@') { |
951 | start_at = memparse(p+1, &p); | 951 | start_at = memparse(p+1, &p); |
952 | add_memory_region(start_at, mem_size, E820_RAM); | 952 | e820_add_region(start_at, mem_size, E820_RAM); |
953 | } else if (*p == '#') { | 953 | } else if (*p == '#') { |
954 | start_at = memparse(p+1, &p); | 954 | start_at = memparse(p+1, &p); |
955 | add_memory_region(start_at, mem_size, E820_ACPI); | 955 | e820_add_region(start_at, mem_size, E820_ACPI); |
956 | } else if (*p == '$') { | 956 | } else if (*p == '$') { |
957 | start_at = memparse(p+1, &p); | 957 | start_at = memparse(p+1, &p); |
958 | add_memory_region(start_at, mem_size, E820_RESERVED); | 958 | e820_add_region(start_at, mem_size, E820_RESERVED); |
959 | } else { | 959 | } else { |
960 | end_user_pfn = (mem_size >> PAGE_SHIFT); | 960 | end_user_pfn = (mem_size >> PAGE_SHIFT); |
961 | } | 961 | } |
diff --git a/arch/x86/kernel/efi.c b/arch/x86/kernel/efi.c index d5c7fcdd1861..473c89fe5073 100644 --- a/arch/x86/kernel/efi.c +++ b/arch/x86/kernel/efi.c | |||
@@ -233,7 +233,7 @@ static void __init add_efi_memmap(void) | |||
233 | e820_type = E820_RAM; | 233 | e820_type = E820_RAM; |
234 | else | 234 | else |
235 | e820_type = E820_RESERVED; | 235 | e820_type = E820_RESERVED; |
236 | add_memory_region(start, size, e820_type); | 236 | e820_add_region(start, size, e820_type); |
237 | } | 237 | } |
238 | sanitize_e820_map(e820.map, ARRAY_SIZE(e820.map), &e820.nr_map); | 238 | sanitize_e820_map(e820.map, ARRAY_SIZE(e820.map), &e820.nr_map); |
239 | } | 239 | } |