git://git.onelab.eu
/
linux-2.6.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Fedora kernel-2.6.17-1.2142_FC4 patched with stable patch-2.6.17.4-vs2.0.2-rc26.diff
[linux-2.6.git]
/
arch
/
x86_64
/
mm
/
mmap.c
diff --git
a/arch/x86_64/mm/mmap.c
b/arch/x86_64/mm/mmap.c
index
011bb4c
..
432d2aa
100644
(file)
--- a/
arch/x86_64/mm/mmap.c
+++ b/
arch/x86_64/mm/mmap.c
@@
-26,6
+26,7
@@
#include <linux/personality.h>
#include <linux/mm.h>
#include <linux/personality.h>
#include <linux/mm.h>
+#include <linux/random.h>
/*
* Top of mmap area (just below the process stack).
/*
* Top of mmap area (just below the process stack).
@@
-37,7
+38,7
@@
static inline unsigned long mmap_base(void)
{
static inline unsigned long mmap_base(void)
{
- unsigned long gap = current->rlim[RLIMIT_STACK].rlim_cur;
+ unsigned long gap = current->
signal->
rlim[RLIMIT_STACK].rlim_cur;
if (gap < MIN_GAP)
gap = MIN_GAP;
if (gap < MIN_GAP)
gap = MIN_GAP;
@@
-54,13
+55,13
@@
static inline int mmap_is_legacy(void)
*/
if (!test_thread_flag(TIF_IA32))
return 1;
*/
if (!test_thread_flag(TIF_IA32))
return 1;
-
- if (current->personality & ADDR_COMPAT_LAYOUT)
+
+ if (current->personality & ADDR_COMPAT_LAYOUT)
return 1;
return 1;
-
- if (current->rlim[RLIMIT_STACK].rlim_cur == RLIM_INFINITY)
+
+ if (current->
signal->
rlim[RLIMIT_STACK].rlim_cur == RLIM_INFINITY)
return 1;
return 1;
-
+
return sysctl_legacy_va_layout;
}
return sysctl_legacy_va_layout;
}
@@
-81,7
+82,6
@@
void arch_pick_mmap_layout(struct mm_struct *mm)
} else {
mm->mmap_base = mmap_base();
mm->get_unmapped_area = arch_get_unmapped_area_topdown;
} else {
mm->mmap_base = mmap_base();
mm->get_unmapped_area = arch_get_unmapped_area_topdown;
- mm->get_unmapped_exec_area = arch_get_unmapped_exec_area;
mm->unmap_area = arch_unmap_area_topdown;
}
}
mm->unmap_area = arch_unmap_area_topdown;
}
}