summaryrefslogtreecommitdiffstats
path: root/linux-2.6-32bit-mmap-exec-randomization.patch
diff options
context:
space:
mode:
authorJosh Boyer <jwboyer@redhat.com>2012-06-02 07:56:45 -0400
committerJosh Boyer <jwboyer@redhat.com>2012-06-02 10:44:50 -0400
commitd0633aed96aaed8d8996ecec7213ad2bf1a819df (patch)
tree189362ac06dd65b48299416667e7965c75152330 /linux-2.6-32bit-mmap-exec-randomization.patch
parent940afcbf92efc16c6b932d35041dd8ef5251ae55 (diff)
downloadkernel-d0633aed96aaed8d8996ecec7213ad2bf1a819df.tar.gz
kernel-d0633aed96aaed8d8996ecec7213ad2bf1a819df.tar.xz
kernel-d0633aed96aaed8d8996ecec7213ad2bf1a819df.zip
Linux v3.4-10115-g829f51d
Diffstat (limited to 'linux-2.6-32bit-mmap-exec-randomization.patch')
-rw-r--r--linux-2.6-32bit-mmap-exec-randomization.patch26
1 files changed, 13 insertions, 13 deletions
diff --git a/linux-2.6-32bit-mmap-exec-randomization.patch b/linux-2.6-32bit-mmap-exec-randomization.patch
index f6079841d..1c0800127 100644
--- a/linux-2.6-32bit-mmap-exec-randomization.patch
+++ b/linux-2.6-32bit-mmap-exec-randomization.patch
@@ -51,10 +51,10 @@ index 66e6d93..b80cde7 100644
ret = addr;
goto up_fail;
diff --git a/include/linux/mm.h b/include/linux/mm.h
-index 7d5c37f..92cb90d 100644
+index b36d08c..91e573d 100644
--- a/include/linux/mm.h
+++ b/include/linux/mm.h
-@@ -1389,7 +1389,13 @@ extern int install_special_mapping(struct mm_struct *mm,
+@@ -1387,7 +1387,13 @@ extern int install_special_mapping(struct mm_struct *mm,
unsigned long addr, unsigned long len,
unsigned long flags, struct page **pages);
@@ -70,7 +70,7 @@ index 7d5c37f..92cb90d 100644
extern unsigned long mmap_region(struct file *file, unsigned long addr,
unsigned long len, unsigned long flags,
diff --git a/include/linux/mm_types.h b/include/linux/mm_types.h
-index 26574c7..54a063d 100644
+index dad95bd..01a150c 100644
--- a/include/linux/mm_types.h
+++ b/include/linux/mm_types.h
@@ -294,6 +294,9 @@ struct mm_struct {
@@ -84,7 +84,7 @@ index 26574c7..54a063d 100644
#endif
unsigned long mmap_base; /* base of mmap area */
diff --git a/include/linux/sched.h b/include/linux/sched.h
-index f45c0b2..7234f1d 100644
+index f34437e..12fe177 100644
--- a/include/linux/sched.h
+++ b/include/linux/sched.h
@@ -391,6 +391,10 @@ extern void arch_pick_mmap_layout(struct mm_struct *mm);
@@ -99,7 +99,7 @@ index f45c0b2..7234f1d 100644
arch_get_unmapped_area_topdown(struct file *filp, unsigned long addr,
unsigned long len, unsigned long pgoff,
diff --git a/mm/mmap.c b/mm/mmap.c
-index e8dcfc7..4bb6ac9 100644
+index 3edfcdf..076ec09 100644
--- a/mm/mmap.c
+++ b/mm/mmap.c
@@ -31,6 +31,7 @@
@@ -110,7 +110,7 @@ index e8dcfc7..4bb6ac9 100644
#include <asm/uaccess.h>
#include <asm/cacheflush.h>
-@@ -1013,7 +1014,8 @@ static unsigned long do_mmap_pgoff(struct file *file, unsigned long addr,
+@@ -1011,7 +1012,8 @@ unsigned long do_mmap_pgoff(struct file *file, unsigned long addr,
/* Obtain the address to map to. we verify (or select) it and ensure
* that it represents a valid section of the address space.
*/
@@ -120,7 +120,7 @@ index e8dcfc7..4bb6ac9 100644
if (addr & ~PAGE_MASK)
return addr;
-@@ -1603,8 +1605,8 @@ void arch_unmap_area_topdown(struct mm_struct *mm, unsigned long addr)
+@@ -1568,8 +1570,8 @@ void arch_unmap_area_topdown(struct mm_struct *mm, unsigned long addr)
}
unsigned long
@@ -131,7 +131,7 @@ index e8dcfc7..4bb6ac9 100644
{
unsigned long (*get_area)(struct file *, unsigned long,
unsigned long, unsigned long, unsigned long);
-@@ -1617,7 +1619,11 @@ get_unmapped_area(struct file *file, unsigned long addr, unsigned long len,
+@@ -1582,7 +1584,11 @@ get_unmapped_area(struct file *file, unsigned long addr, unsigned long len,
if (len > TASK_SIZE)
return -ENOMEM;
@@ -144,9 +144,9 @@ index e8dcfc7..4bb6ac9 100644
if (file && file->f_op && file->f_op->get_unmapped_area)
get_area = file->f_op->get_unmapped_area;
addr = get_area(file, addr, len, pgoff, flags);
-@@ -1631,8 +1637,83 @@ get_unmapped_area(struct file *file, unsigned long addr, unsigned long len,
-
- return arch_rebalance_pgtables(addr, len);
+@@ -1598,8 +1604,83 @@ get_unmapped_area(struct file *file, unsigned long addr, unsigned long len,
+ error = security_mmap_addr(addr);
+ return error ? error : addr;
}
+EXPORT_SYMBOL(get_unmapped_area_prot);
+
@@ -230,10 +230,10 @@ index e8dcfc7..4bb6ac9 100644
/* Look up the first VMA which satisfies addr < vm_end, NULL if none. */
struct vm_area_struct *find_vma(struct mm_struct *mm, unsigned long addr)
diff --git a/mm/mremap.c b/mm/mremap.c
-index db8d983..3a2d940 100644
+index 21fed20..a3de1ee 100644
--- a/mm/mremap.c
+++ b/mm/mremap.c
-@@ -521,10 +521,10 @@ unsigned long do_mremap(unsigned long addr,
+@@ -519,10 +519,10 @@ SYSCALL_DEFINE5(mremap, unsigned long, addr, unsigned long, old_len,
if (vma->vm_flags & VM_MAYSHARE)
map_flags |= MAP_SHARED;