diff options
author | Peter Zijlstra <a.p.zijlstra@chello.nl> | 2009-07-10 08:57:56 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2009-07-10 17:24:05 -0400 |
commit | c99e6efe1ba04561e7d93a81f0be07e37427e835 (patch) | |
tree | 8a1743463ef9676e68b9c3971f0bbeea04111bdd /arch/cris/include | |
parent | 2a6f86bc5ed4af2ff04bc927eb77789c70e53a1e (diff) |
sched: INIT_PREEMPT_COUNT
Pull the initial preempt_count value into a single
definition site.
Maintainers for: alpha, ia64 and m68k, please have a look,
your arch code is funny.
The header magic is a bit odd, but similar to the KERNEL_DS
one, CPP waits with expanding these macros until the
INIT_THREAD_INFO macro itself is expanded, which is in
arch/*/kernel/init_task.c where we've already included
sched.h so we're good.
Cc: tony.luck@intel.com
Cc: rth@twiddle.net
Cc: geert@linux-m68k.org
Signed-off-by: Peter Zijlstra <a.p.zijlstra@chello.nl>
Acked-by: Matt Mackall <mpm@selenic.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'arch/cris/include')
-rw-r--r-- | arch/cris/include/asm/thread_info.h | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/arch/cris/include/asm/thread_info.h b/arch/cris/include/asm/thread_info.h index bc5b2935ca53..c3aade36c330 100644 --- a/arch/cris/include/asm/thread_info.h +++ b/arch/cris/include/asm/thread_info.h | |||
@@ -50,8 +50,6 @@ struct thread_info { | |||
50 | 50 | ||
51 | /* | 51 | /* |
52 | * macros/functions for gaining access to the thread information structure | 52 | * macros/functions for gaining access to the thread information structure |
53 | * | ||
54 | * preempt_count needs to be 1 initially, until the scheduler is functional. | ||
55 | */ | 53 | */ |
56 | #ifndef __ASSEMBLY__ | 54 | #ifndef __ASSEMBLY__ |
57 | #define INIT_THREAD_INFO(tsk) \ | 55 | #define INIT_THREAD_INFO(tsk) \ |
@@ -60,7 +58,7 @@ struct thread_info { | |||
60 | .exec_domain = &default_exec_domain, \ | 58 | .exec_domain = &default_exec_domain, \ |
61 | .flags = 0, \ | 59 | .flags = 0, \ |
62 | .cpu = 0, \ | 60 | .cpu = 0, \ |
63 | .preempt_count = 1, \ | 61 | .preempt_count = INIT_PREEMPT_COUNT, \ |
64 | .addr_limit = KERNEL_DS, \ | 62 | .addr_limit = KERNEL_DS, \ |
65 | .restart_block = { \ | 63 | .restart_block = { \ |
66 | .fn = do_no_restart_syscall, \ | 64 | .fn = do_no_restart_syscall, \ |