summaryrefslogtreecommitdiff
path: root/include/asm-arm/thread_info.h
diff options
context:
space:
mode:
authorRussell King <rmk@dyn-67.arm.linux.org.uk>2005-05-05 16:11:00 +0400
committerRussell King <rmk@dyn-67.arm.linux.org.uk>2005-05-05 16:11:00 +0400
commit4f7a18124c1a44858fb74a1c4234015009952959 (patch)
tree978f55875b776c83ebcfed24737784ac098d1a4e /include/asm-arm/thread_info.h
parent897f5ab2cd733a77a2279268262919caa8154b9d (diff)
downloadlinux-4f7a18124c1a44858fb74a1c4234015009952959.tar.xz
[PATCH] ARM: Fix kernel stack offset calculations
Various places in the ARM kernel implicitly assumed that kernel stacks are always 8K due to hard coded constants. Replace these constants with definitions. Correct the allowable range of kernel stack pointer values within the allocation. Arrange for the entire kernel stack to be zeroed, not just the upper 4K if CONFIG_DEBUG_STACK_USAGE is set. Signed-off-by: Russell King <rmk@arm.linux.org.uk>
Diffstat (limited to 'include/asm-arm/thread_info.h')
-rw-r--r--include/asm-arm/thread_info.h6
1 files changed, 4 insertions, 2 deletions
diff --git a/include/asm-arm/thread_info.h b/include/asm-arm/thread_info.h
index a61618fb433c..66c585c50cf9 100644
--- a/include/asm-arm/thread_info.h
+++ b/include/asm-arm/thread_info.h
@@ -14,6 +14,10 @@
#include <asm/fpstate.h>
+#define THREAD_SIZE_ORDER 1
+#define THREAD_SIZE 8192
+#define THREAD_START_SP (THREAD_SIZE - 8)
+
#ifndef __ASSEMBLY__
struct task_struct;
@@ -77,8 +81,6 @@ struct thread_info {
#define init_thread_info (init_thread_union.thread_info)
#define init_stack (init_thread_union.stack)
-#define THREAD_SIZE 8192
-
/*
* how to get the thread information struct from C
*/