summaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorRobin Holt <holt@sgi.com>2010-05-11 14:06:46 -0700
committerGreg Kroah-Hartman <gregkh@suse.de>2010-05-26 14:32:04 -0700
commitb759d0992e1fdcf2a76ebef37289e787b375fa28 (patch)
treebcd613d0a5dee3ccbe9e83c27e3efdff7d9cb8b9 /include
parent23e7ebc2b334b2a200983e8e48289634f0b0bf5f (diff)
downloadkernel-crypto-b759d0992e1fdcf2a76ebef37289e787b375fa28.tar.gz
kernel-crypto-b759d0992e1fdcf2a76ebef37289e787b375fa28.tar.xz
kernel-crypto-b759d0992e1fdcf2a76ebef37289e787b375fa28.zip
revert "procfs: provide stack information for threads" and its fixup commits
commit 34441427aab4bdb3069a4ffcda69a99357abcb2e upstream. Originally, commit d899bf7b ("procfs: provide stack information for threads") attempted to introduce a new feature for showing where the threadstack was located and how many pages are being utilized by the stack. Commit c44972f1 ("procfs: disable per-task stack usage on NOMMU") was applied to fix the NO_MMU case. Commit 89240ba0 ("x86, fs: Fix x86 procfs stack information for threads on 64-bit") was applied to fix a bug in ia32 executables being loaded. Commit 9ebd4eba7 ("procfs: fix /proc/<pid>/stat stack pointer for kernel threads") was applied to fix a bug which had kernel threads printing a userland stack address. Commit 1306d603f ('proc: partially revert "procfs: provide stack information for threads"') was then applied to revert the stack pages being used to solve a significant performance regression. This patch nearly undoes the effect of all these patches. The reason for reverting these is it provides an unusable value in field 28. For x86_64, a fork will result in the task->stack_start value being updated to the current user top of stack and not the stack start address. This unpredictability of the stack_start value makes it worthless. That includes the intended use of showing how much stack space a thread has. Other architectures will get different values. As an example, ia64 gets 0. The do_fork() and copy_process() functions appear to treat the stack_start and stack_size parameters as architecture specific. I only partially reverted c44972f1 ("procfs: disable per-task stack usage on NOMMU") . If I had completely reverted it, I would have had to change mm/Makefile only build pagewalk.o when CONFIG_PROC_PAGE_MONITOR is configured. Since I could not test the builds without significant effort, I decided to not change mm/Makefile. I only partially reverted 89240ba0 ("x86, fs: Fix x86 procfs stack information for threads on 64-bit") . I left the KSTK_ESP() change in place as that seemed worthwhile. Signed-off-by: Robin Holt <holt@sgi.com> Cc: Stefani Seibold <stefani@seibold.net> Cc: KOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com> Cc: Michal Simek <monstr@monstr.eu> Cc: Ingo Molnar <mingo@elte.hu> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'include')
-rw-r--r--include/linux/sched.h1
1 files changed, 0 insertions, 1 deletions
diff --git a/include/linux/sched.h b/include/linux/sched.h
index 1f5fa53b46b..db821a40882 100644
--- a/include/linux/sched.h
+++ b/include/linux/sched.h
@@ -1560,7 +1560,6 @@ struct task_struct {
/* bitmask of trace recursion */
unsigned long trace_recursion;
#endif /* CONFIG_TRACING */
- unsigned long stack_start;
#ifdef CONFIG_CGROUP_MEM_RES_CTLR /* memcg uses this to do batch job */
struct memcg_batch_info {
int do_batch; /* incremented when batch uncharge started */