diff options
| author | 2015-05-18 13:52:44 -0700 | |
|---|---|---|
| committer | 2015-05-18 13:52:44 -0700 | |
| commit | 936a0cd52aa5d024c583e36e2f21bf6ec2e527e4 (patch) | |
| tree | 01cffc11361be7d671b71ba86463f6649b39d552 /fs/exec.c | |
| parent | staging: slicoss: fix occasionally writing out only half of a dma address (diff) | |
| parent | Linux 4.1-rc4 (diff) | |
Merge 4.1-rc4 into staging-next
We want the fixes in here for testing and merge issues.
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'fs/exec.c')
| -rw-r--r-- | fs/exec.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/fs/exec.c b/fs/exec.c index 49a1c61433b7..1977c2a553ac 100644 --- a/fs/exec.c +++ b/fs/exec.c @@ -659,6 +659,9 @@ int setup_arg_pages(struct linux_binprm *bprm, if (stack_base > STACK_SIZE_MAX) stack_base = STACK_SIZE_MAX; + /* Add space for stack randomization. */ + stack_base += (STACK_RND_MASK << PAGE_SHIFT); + /* Make sure we didn't let the argument array grow too large. */ if (vma->vm_end - vma->vm_start > stack_base) return -ENOMEM; |
