Commit 300c2652 authored by Andrew Morton's avatar Andrew Morton Committed by James Bottomley

[PATCH] correct vm_page_prot on stack pages

From: David Mosberger <davidm@napali.hpl.hp.com>

The patch below is needed to make it possible to map stack pages
without execution permission (as we do on ia64).
parent 2accc2e3
...@@ -406,7 +406,7 @@ int setup_arg_pages(struct linux_binprm *bprm) ...@@ -406,7 +406,7 @@ int setup_arg_pages(struct linux_binprm *bprm)
mpnt->vm_start = PAGE_MASK & (unsigned long) bprm->p; mpnt->vm_start = PAGE_MASK & (unsigned long) bprm->p;
mpnt->vm_end = STACK_TOP; mpnt->vm_end = STACK_TOP;
#endif #endif
mpnt->vm_page_prot = PAGE_COPY; mpnt->vm_page_prot = protection_map[VM_STACK_FLAGS & 0x7];
mpnt->vm_flags = VM_STACK_FLAGS; mpnt->vm_flags = VM_STACK_FLAGS;
mpnt->vm_ops = NULL; mpnt->vm_ops = NULL;
mpnt->vm_pgoff = 0; mpnt->vm_pgoff = 0;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment