diff options
| author | Linus Torvalds <torvalds@linux-foundation.org> | 2010-05-19 14:37:22 -0400 |
|---|---|---|
| committer | Linus Torvalds <torvalds@linux-foundation.org> | 2010-05-19 14:37:22 -0400 |
| commit | 1d3c6ff44ad4b5f113602e153026a338f0f9b3ff (patch) | |
| tree | 1e1f2932634fc6d0e4acfe68496c1c727b83a13e /arch/arm/mm/init.c | |
| parent | 7c7cbaf5b82c418cd3b1dcf718f71d0e6057e639 (diff) | |
| parent | 717e7c2672e37253a4d3aa70e4716b5b0a658761 (diff) | |
Merge branch 'devel' of master.kernel.org:/home/rmk/linux-2.6-arm
* 'devel' of master.kernel.org:/home/rmk/linux-2.6-arm: (224 commits)
ARM: remove 'select GENERIC_TIME'
ARM: 6136/1: ARCH_REQUIRE_GPIOLIB selects GENERIC_GPIO
ARM: 6074/1: oprofile: convert from sysdev to platform device
ARM: 6073/1: oprofile: remove old files and update KConfig
ARM: 6072/1: oprofile: use perf-events framework as backend
ARM: 6071/1: perf-events: allow modules to query the number of hardware counters
ARM: 6070/1: perf-events: add support for xscale PMUs
ARM: 6069/1: perf-events: use numeric ID to identify PMU
ARM: 6064/1: pmu: register IRQs at runtime
ARM: Optionally allow ARMv6 to use 'normal, bufferable' memory for DMA
ARM: 6134/1: Handle instruction cache maintenance fault properly
ARM: nwfpe: allow debugging output to be configured at runtime
ARM: rename mach_cpu_disable() to platform_cpu_disable()
ARM: 6132/1: PL330: Add common core driver
ARM: 6094/1: Extend cache-l2x0 to support the 16-way PL310
ARM: Move memory mapping into mmu.c
ARM: Ensure meminfo is sorted prior to sanity_check_meminfo
ARM: Remove useless linux/bootmem.h includes
ARM: convert /proc/cpu/aligment to seq_file
arm: use asm-generic/scatterlist.h
...
Diffstat (limited to 'arch/arm/mm/init.c')
| -rw-r--r-- | arch/arm/mm/init.c | 34 |
1 files changed, 0 insertions, 34 deletions
diff --git a/arch/arm/mm/init.c b/arch/arm/mm/init.c index 0ed29bfeba1c..1ba6cf5a2c02 100644 --- a/arch/arm/mm/init.c +++ b/arch/arm/mm/init.c | |||
| @@ -15,7 +15,6 @@ | |||
| 15 | #include <linux/mman.h> | 15 | #include <linux/mman.h> |
| 16 | #include <linux/nodemask.h> | 16 | #include <linux/nodemask.h> |
| 17 | #include <linux/initrd.h> | 17 | #include <linux/initrd.h> |
| 18 | #include <linux/sort.h> | ||
| 19 | #include <linux/highmem.h> | 18 | #include <linux/highmem.h> |
| 20 | #include <linux/gfp.h> | 19 | #include <linux/gfp.h> |
| 21 | 20 | ||
| @@ -224,20 +223,6 @@ static int __init check_initrd(struct meminfo *mi) | |||
| 224 | return initrd_node; | 223 | return initrd_node; |
| 225 | } | 224 | } |
| 226 | 225 | ||
| 227 | static inline void map_memory_bank(struct membank *bank) | ||
| 228 | { | ||
| 229 | #ifdef CONFIG_MMU | ||
| 230 | struct map_desc map; | ||
| 231 | |||
| 232 | map.pfn = bank_pfn_start(bank); | ||
| 233 | map.virtual = __phys_to_virt(bank_phys_start(bank)); | ||
| 234 | map.length = bank_phys_size(bank); | ||
| 235 | map.type = MT_MEMORY; | ||
| 236 | |||
| 237 | create_mapping(&map); | ||
| 238 | #endif | ||
| 239 | } | ||
| 240 | |||
| 241 | static void __init bootmem_init_node(int node, struct meminfo *mi, | 226 | static void __init bootmem_init_node(int node, struct meminfo *mi, |
| 242 | unsigned long start_pfn, unsigned long end_pfn) | 227 | unsigned long start_pfn, unsigned long end_pfn) |
| 243 | { | 228 | { |
| @@ -247,16 +232,6 @@ static void __init bootmem_init_node(int node, struct meminfo *mi, | |||
| 247 | int i; | 232 | int i; |
| 248 | 233 | ||
| 249 | /* | 234 | /* |
| 250 | * Map the memory banks for this node. | ||
| 251 | */ | ||
| 252 | for_each_nodebank(i, mi, node) { | ||
| 253 | struct membank *bank = &mi->bank[i]; | ||
| 254 | |||
| 255 | if (!bank->highmem) | ||
| 256 | map_memory_bank(bank); | ||
| 257 | } | ||
| 258 | |||
| 259 | /* | ||
| 260 | * Allocate the bootmem bitmap page. | 235 | * Allocate the bootmem bitmap page. |
| 261 | */ | 236 | */ |
| 262 | boot_pages = bootmem_bootmap_pages(end_pfn - start_pfn); | 237 | boot_pages = bootmem_bootmap_pages(end_pfn - start_pfn); |
| @@ -385,21 +360,12 @@ static void arm_memory_present(struct meminfo *mi, int node) | |||
| 385 | } | 360 | } |
| 386 | #endif | 361 | #endif |
| 387 | 362 | ||
| 388 | static int __init meminfo_cmp(const void *_a, const void *_b) | ||
| 389 | { | ||
| 390 | const struct membank *a = _a, *b = _b; | ||
| 391 | long cmp = bank_pfn_start(a) - bank_pfn_start(b); | ||
| 392 | return cmp < 0 ? -1 : cmp > 0 ? 1 : 0; | ||
| 393 | } | ||
| 394 | |||
| 395 | void __init bootmem_init(void) | 363 | void __init bootmem_init(void) |
| 396 | { | 364 | { |
| 397 | struct meminfo *mi = &meminfo; | 365 | struct meminfo *mi = &meminfo; |
| 398 | unsigned long min, max_low, max_high; | 366 | unsigned long min, max_low, max_high; |
| 399 | int node, initrd_node; | 367 | int node, initrd_node; |
| 400 | 368 | ||
| 401 | sort(&mi->bank, mi->nr_banks, sizeof(mi->bank[0]), meminfo_cmp, NULL); | ||
| 402 | |||
| 403 | /* | 369 | /* |
| 404 | * Locate which node contains the ramdisk image, if any. | 370 | * Locate which node contains the ramdisk image, if any. |
| 405 | */ | 371 | */ |
