diff options
| author | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2007-08-18 12:38:56 -0400 |
|---|---|---|
| committer | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2007-08-18 12:38:56 -0400 |
| commit | ed72df448250a6da72b65e7881eb63c5ded3475f (patch) | |
| tree | cff147d103f1578380b0c3c324630d9c75945fb3 /arch/ia64/mm/fault.c | |
| parent | 505683675cf0ed903765f160ad633f77ab90a9d4 (diff) | |
| parent | 118142080a75fc1ce599c73b7894a71b4813828e (diff) | |
Merge branch 'release' of git://git.kernel.org/pub/scm/linux/kernel/git/aegl/linux-2.6
* 'release' of git://git.kernel.org/pub/scm/linux/kernel/git/aegl/linux-2.6:
Cross-compilation between e.g. i386 -> 64bit could break -> work around it
[IA64] Enable early console for Ski simulator
[IA64] forbid ptrace changes psr.ri to 3
[IA64] Failure to grow RBS
[IA64] Fix processor_get_freq
[IA64] SGI Altix : fix a force_interrupt bug on altix
[IA64] Update arch/ia64/configs/* s/SLAB/SLUB/
[IA64] get back PT_IA_64_UNWIND program header
[IA64] need NOTES in vmlinux.lds.S
[IA64] make unwinder stop at last frame of the bootloader
[IA64] Clean up CPE handler registration
[IA64] Include Kconfig.preempt
[IA64] SN2 needs platform specific irq_to_vector() function.
[IA64] Use atomic64_read to read an atomic64_t.
[IA64] disable irq's and check need_resched before safe_halt
Diffstat (limited to 'arch/ia64/mm/fault.c')
| -rw-r--r-- | arch/ia64/mm/fault.c | 14 |
1 files changed, 11 insertions, 3 deletions
diff --git a/arch/ia64/mm/fault.c b/arch/ia64/mm/fault.c index 73ccb6010c05..9150ffaff9e8 100644 --- a/arch/ia64/mm/fault.c +++ b/arch/ia64/mm/fault.c | |||
| @@ -112,11 +112,17 @@ ia64_do_page_fault (unsigned long address, unsigned long isr, struct pt_regs *re | |||
| 112 | down_read(&mm->mmap_sem); | 112 | down_read(&mm->mmap_sem); |
| 113 | 113 | ||
| 114 | vma = find_vma_prev(mm, address, &prev_vma); | 114 | vma = find_vma_prev(mm, address, &prev_vma); |
| 115 | if (!vma) | 115 | if (!vma && !prev_vma ) |
| 116 | goto bad_area; | 116 | goto bad_area; |
| 117 | 117 | ||
| 118 | /* find_vma_prev() returns vma such that address < vma->vm_end or NULL */ | 118 | /* |
| 119 | if (address < vma->vm_start) | 119 | * find_vma_prev() returns vma such that address < vma->vm_end or NULL |
| 120 | * | ||
| 121 | * May find no vma, but could be that the last vm area is the | ||
| 122 | * register backing store that needs to expand upwards, in | ||
| 123 | * this case vma will be null, but prev_vma will ne non-null | ||
| 124 | */ | ||
| 125 | if (( !vma && prev_vma ) || (address < vma->vm_start) ) | ||
| 120 | goto check_expansion; | 126 | goto check_expansion; |
| 121 | 127 | ||
| 122 | good_area: | 128 | good_area: |
| @@ -172,6 +178,8 @@ ia64_do_page_fault (unsigned long address, unsigned long isr, struct pt_regs *re | |||
| 172 | 178 | ||
| 173 | check_expansion: | 179 | check_expansion: |
| 174 | if (!(prev_vma && (prev_vma->vm_flags & VM_GROWSUP) && (address == prev_vma->vm_end))) { | 180 | if (!(prev_vma && (prev_vma->vm_flags & VM_GROWSUP) && (address == prev_vma->vm_end))) { |
| 181 | if (!vma) | ||
| 182 | goto bad_area; | ||
| 175 | if (!(vma->vm_flags & VM_GROWSDOWN)) | 183 | if (!(vma->vm_flags & VM_GROWSDOWN)) |
| 176 | goto bad_area; | 184 | goto bad_area; |
| 177 | if (REGION_NUMBER(address) != REGION_NUMBER(vma->vm_start) | 185 | if (REGION_NUMBER(address) != REGION_NUMBER(vma->vm_start) |
