diff options
| author | Linus Torvalds <torvalds@linux-foundation.org> | 2009-10-02 19:20:43 -0400 |
|---|---|---|
| committer | Linus Torvalds <torvalds@linux-foundation.org> | 2009-10-02 19:20:43 -0400 |
| commit | a037a79dceaf717409fbf42f4ad209b9c15f435c (patch) | |
| tree | c30b5b033c74ab9470e875554bded16464bbdf9b /arch/arm/mm/mmu.c | |
| parent | 90d5ffc729e92bffc0f84e2447e2e6dc280240a5 (diff) | |
| parent | d25ef8b86e6a58f5476bf6e4a8da730b335f68fa (diff) | |
Merge master.kernel.org:/home/rmk/linux-2.6-arm
* master.kernel.org:/home/rmk/linux-2.6-arm: (25 commits)
ARM: 5728/1: Proper prefetch abort handling on ARMv6 and ARMv7
ARM: 5727/1: Pass IFSR register to do_PrefetchAbort()
ARM: 5740/1: fix valid_phys_addr_range() range check
ARM: 5739/1: ARM: allow empty ATAG_CORE
ARM: 5735/1: sa1111: CodingStyle cleanups
ARM: 5738/1: Correct TCM documentation
ARM: 5734/1: arm: fix compilation of entry-common.S for older CPUs
ARM: 5733/1: fix bcmring compile error
ARM: 5732/1: remove redundant include file
ARM: 5731/2: Fix U300 generic GPIO, remove ifdefs from MMCI v3
ARM: Ensure do_cache_op takes mmap_sem
ARM: Fix __cpuexit section mismatch warnings
ARM: Don't allow highmem on SMP platforms without h/w TLB ops broadcast
ARM: includecheck fix: mach-davinci, board-dm365-evm.c
ARM: Remove unused CONFIG SA1100_H3XXX
ARM: Fix warning: unused variable 'highmem'
ARM: Fix warning: #warning syscall migrate_pages not implemented
ARM: Fix SA11x0 clocksource warning
ARM: Fix SA1100 Neponset serial section mismatch
ARM: Fix SA1100 Assabet/Neponset PCMCIA section mismatch warnings
...
Diffstat (limited to 'arch/arm/mm/mmu.c')
| -rw-r--r-- | arch/arm/mm/mmu.c | 39 |
1 files changed, 35 insertions, 4 deletions
diff --git a/arch/arm/mm/mmu.c b/arch/arm/mm/mmu.c index 4426ee67ceca..02243eeccf50 100644 --- a/arch/arm/mm/mmu.c +++ b/arch/arm/mm/mmu.c | |||
| @@ -21,6 +21,7 @@ | |||
| 21 | #include <asm/cachetype.h> | 21 | #include <asm/cachetype.h> |
| 22 | #include <asm/setup.h> | 22 | #include <asm/setup.h> |
| 23 | #include <asm/sizes.h> | 23 | #include <asm/sizes.h> |
| 24 | #include <asm/smp_plat.h> | ||
| 24 | #include <asm/tlb.h> | 25 | #include <asm/tlb.h> |
| 25 | #include <asm/highmem.h> | 26 | #include <asm/highmem.h> |
| 26 | 27 | ||
| @@ -709,10 +710,6 @@ static void __init sanity_check_meminfo(void) | |||
| 709 | if (meminfo.nr_banks >= NR_BANKS) { | 710 | if (meminfo.nr_banks >= NR_BANKS) { |
| 710 | printk(KERN_CRIT "NR_BANKS too low, " | 711 | printk(KERN_CRIT "NR_BANKS too low, " |
| 711 | "ignoring high memory\n"); | 712 | "ignoring high memory\n"); |
| 712 | } else if (cache_is_vipt_aliasing()) { | ||
| 713 | printk(KERN_CRIT "HIGHMEM is not yet supported " | ||
| 714 | "with VIPT aliasing cache, " | ||
| 715 | "ignoring high memory\n"); | ||
| 716 | } else { | 713 | } else { |
| 717 | memmove(bank + 1, bank, | 714 | memmove(bank + 1, bank, |
| 718 | (meminfo.nr_banks - i) * sizeof(*bank)); | 715 | (meminfo.nr_banks - i) * sizeof(*bank)); |
| @@ -726,6 +723,8 @@ static void __init sanity_check_meminfo(void) | |||
| 726 | bank->size = VMALLOC_MIN - __va(bank->start); | 723 | bank->size = VMALLOC_MIN - __va(bank->start); |
| 727 | } | 724 | } |
| 728 | #else | 725 | #else |
| 726 | bank->highmem = highmem; | ||
| 727 | |||
| 729 | /* | 728 | /* |
| 730 | * Check whether this memory bank would entirely overlap | 729 | * Check whether this memory bank would entirely overlap |
| 731 | * the vmalloc area. | 730 | * the vmalloc area. |
| @@ -754,6 +753,38 @@ static void __init sanity_check_meminfo(void) | |||
| 754 | #endif | 753 | #endif |
| 755 | j++; | 754 | j++; |
| 756 | } | 755 | } |
| 756 | #ifdef CONFIG_HIGHMEM | ||
| 757 | if (highmem) { | ||
| 758 | const char *reason = NULL; | ||
| 759 | |||
| 760 | if (cache_is_vipt_aliasing()) { | ||
| 761 | /* | ||
| 762 | * Interactions between kmap and other mappings | ||
| 763 | * make highmem support with aliasing VIPT caches | ||
| 764 | * rather difficult. | ||
| 765 | */ | ||
| 766 | reason = "with VIPT aliasing cache"; | ||
| 767 | #ifdef CONFIG_SMP | ||
| 768 | } else if (tlb_ops_need_broadcast()) { | ||
| 769 | /* | ||
| 770 | * kmap_high needs to occasionally flush TLB entries, | ||
| 771 | * however, if the TLB entries need to be broadcast | ||
| 772 | * we may deadlock: | ||
| 773 | * kmap_high(irqs off)->flush_all_zero_pkmaps-> | ||
| 774 | * flush_tlb_kernel_range->smp_call_function_many | ||
| 775 | * (must not be called with irqs off) | ||
| 776 | */ | ||
| 777 | reason = "without hardware TLB ops broadcasting"; | ||
| 778 | #endif | ||
| 779 | } | ||
| 780 | if (reason) { | ||
| 781 | printk(KERN_CRIT "HIGHMEM is not supported %s, ignoring high memory\n", | ||
| 782 | reason); | ||
| 783 | while (j > 0 && meminfo.bank[j - 1].highmem) | ||
| 784 | j--; | ||
| 785 | } | ||
| 786 | } | ||
| 787 | #endif | ||
| 757 | meminfo.nr_banks = j; | 788 | meminfo.nr_banks = j; |
| 758 | } | 789 | } |
| 759 | 790 | ||
