Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 201503
b: refs/heads/master
c: cc92c28
h: refs/heads/master
i:
  201501: ca39bd2
  201499: 98565ad
  201495: 3037631
  201487: 27b2dbb
  201471: a90e296
v: v3
  • Loading branch information
Nicolas Pitre committed Jun 15, 2010
1 parent e1399bf commit 4eb3dad
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 990cb8acf23cab19a2930f1ed5e7dc108f89079b
refs/heads/master: cc92c28b2db5b406657ecc05235d4ca4e222ae34
4 changes: 4 additions & 0 deletions trunk/arch/arm/mm/mmap.c
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
#include <linux/shm.h>
#include <linux/sched.h>
#include <linux/io.h>
#include <linux/random.h>
#include <asm/cputype.h>
#include <asm/system.h>

Expand Down Expand Up @@ -80,6 +81,9 @@ arch_get_unmapped_area(struct file *filp, unsigned long addr,
start_addr = addr = TASK_UNMAPPED_BASE;
mm->cached_hole_size = 0;
}
/* 8 bits of randomness in 20 address space bits */
if (current->flags & PF_RANDOMIZE)
addr += (get_random_int() % (1 << 8)) << PAGE_SHIFT;

full_search:
if (do_align)
Expand Down

0 comments on commit 4eb3dad

Please sign in to comment.