aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/kernel/process.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/arm/kernel/process.c')
-rw-r--r--arch/arm/kernel/process.c21
1 files changed, 21 insertions, 0 deletions
diff --git a/arch/arm/kernel/process.c b/arch/arm/kernel/process.c
index 3af34bf4f4df..e76fcaadce03 100644
--- a/arch/arm/kernel/process.c
+++ b/arch/arm/kernel/process.c
@@ -482,3 +482,24 @@ unsigned long arch_randomize_brk(struct mm_struct *mm)
482 unsigned long range_end = mm->brk + 0x02000000; 482 unsigned long range_end = mm->brk + 0x02000000;
483 return randomize_range(mm->brk, range_end, 0) ? : mm->brk; 483 return randomize_range(mm->brk, range_end, 0) ? : mm->brk;
484} 484}
485
486/*
487 * The vectors page is always readable from user space for the
488 * atomic helpers and the signal restart code. Let's declare a mapping
489 * for it so it is visible through ptrace and /proc/<pid>/mem.
490 */
491
492int vectors_user_mapping(void)
493{
494 struct mm_struct *mm = current->mm;
495 return install_special_mapping(mm, 0xffff0000, PAGE_SIZE,
496 VM_READ | VM_EXEC |
497 VM_MAYREAD | VM_MAYEXEC |
498 VM_ALWAYSDUMP | VM_RESERVED,
499 NULL);
500}
501
502const char *arch_vma_name(struct vm_area_struct *vma)
503{
504 return (vma->vm_start == 0xffff0000) ? "[vectors]" : NULL;
505}