diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2016-10-22 18:39:10 +0200 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2016-10-22 18:39:10 +0200 |
commit | 86c5bf7101991608483c93e7954b93acdc85ea57 (patch) | |
tree | c66010150a6cc66df6ab0339f08cee3d623d78c7 /mm/util.c | |
parent | Merge branch 'irq-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/ker... (diff) | |
parent | mm: Change vm_is_stack_for_task() to vm_is_stack_for_current() (diff) | |
download | linux-86c5bf7101991608483c93e7954b93acdc85ea57.tar.xz linux-86c5bf7101991608483c93e7954b93acdc85ea57.zip |
Merge branch 'mm-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip
Pull vmap stack fixes from Ingo Molnar:
"This is fallout from CONFIG_HAVE_ARCH_VMAP_STACK=y on x86: stack
accesses that used to be just somewhat questionable are now totally
buggy.
These changes try to do it without breaking the ABI: the fields are
left there, they are just reporting zero, or reporting narrower
information (the maps file change)"
* 'mm-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
mm: Change vm_is_stack_for_task() to vm_is_stack_for_current()
fs/proc: Stop trying to report thread stacks
fs/proc: Stop reporting eip and esp in /proc/PID/stat
mm/numa: Remove duplicated include from mprotect.c
Diffstat (limited to 'mm/util.c')
-rw-r--r-- | mm/util.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/mm/util.c b/mm/util.c index 952cbe7ad7b7..1a41553db866 100644 --- a/mm/util.c +++ b/mm/util.c @@ -230,8 +230,10 @@ void __vma_link_list(struct mm_struct *mm, struct vm_area_struct *vma, } /* Check if the vma is being used as a stack by this task */ -int vma_is_stack_for_task(struct vm_area_struct *vma, struct task_struct *t) +int vma_is_stack_for_current(struct vm_area_struct *vma) { + struct task_struct * __maybe_unused t = current; + return (vma->vm_start <= KSTK_ESP(t) && vma->vm_end >= KSTK_ESP(t)); } |