summaryrefslogtreecommitdiff
path: root/arch/blackfin/include/asm/processor.h
diff options
context:
space:
mode:
authorSonic Zhang <sonic.zhang@analog.com>2009-01-07 23:14:38 +0800
committerBryan Wu <cooloney@kernel.org>2009-01-07 23:14:38 +0800
commitcc92b870a779500f444419f27bf73c6c7660ff9c (patch)
treeb82430fe2c0aaa72ea4ebdbc21fb1f2ce8cca7c2 /arch/blackfin/include/asm/processor.h
parent459249aa2d9ae02f49479a2096e5372ccc29c9be (diff)
Blackfin arch: disable pthread stack check for SMP at runtime
Signed-off-by: Sonic Zhang <sonic.zhang@analog.com> Signed-off-by: Bryan Wu <cooloney@kernel.org>
Diffstat (limited to 'arch/blackfin/include/asm/processor.h')
-rw-r--r--arch/blackfin/include/asm/processor.h11
1 files changed, 11 insertions, 0 deletions
diff --git a/arch/blackfin/include/asm/processor.h b/arch/blackfin/include/asm/processor.h
index 83d57a85b14f..0eece23b41c7 100644
--- a/arch/blackfin/include/asm/processor.h
+++ b/arch/blackfin/include/asm/processor.h
@@ -65,6 +65,7 @@ struct thread_struct {
* pass the data segment into user programs if it exists,
* it can't hurt anything as far as I can tell
*/
+#ifndef CONFIG_SMP
#define start_thread(_regs, _pc, _usp) \
do { \
set_fs(USER_DS); \
@@ -78,6 +79,16 @@ do { \
sizeof(*L1_SCRATCH_TASK_INFO)); \
wrusp(_usp); \
} while(0)
+#else
+#define start_thread(_regs, _pc, _usp) \
+do { \
+ set_fs(USER_DS); \
+ (_regs)->pc = (_pc); \
+ if (current->mm) \
+ (_regs)->p5 = current->mm->start_data; \
+ wrusp(_usp); \
+} while (0)
+#endif
/* Forward declaration, a strange C thing */
struct task_struct;