diff options
| author | Russell King <rmk@arm.linux.org.uk> | 2002-10-18 00:36:19 -0700 |
|---|---|---|
| committer | Linus Torvalds <torvalds@home.transmeta.com> | 2002-10-18 00:36:19 -0700 |
| commit | 891c9d56f56230d12ff73f7899604a019f67e8d9 (patch) | |
| tree | 90b9fc40528feae2e0b7c8d096980153edb1670f /include/linux | |
| parent | 367c46394099d2cd79ef899bc85337d158dcb5b5 (diff) | |
[PATCH] set_task_state() UP memory barriers
This fixes the UP set_task_state and set_current_state in 2.5.43 to
ensure that we don't re-order loads around the store for setting
task->state.
This patch is from Nicolas Pitre, nico@cam.org
(As a side note - 2.4.10 also contains the same problem, but 2.2
contain the memory barrier.)
Diffstat (limited to 'include/linux')
| -rw-r--r-- | include/linux/sched.h | 10 |
1 files changed, 0 insertions, 10 deletions
diff --git a/include/linux/sched.h b/include/linux/sched.h index 764a3ebf3c24..b5e63d8ade25 100644 --- a/include/linux/sched.h +++ b/include/linux/sched.h @@ -106,23 +106,13 @@ extern unsigned long nr_uninterruptible(void); #define __set_task_state(tsk, state_value) \ do { (tsk)->state = (state_value); } while (0) -#ifdef CONFIG_SMP #define set_task_state(tsk, state_value) \ set_mb((tsk)->state, (state_value)) -#else -#define set_task_state(tsk, state_value) \ - __set_task_state((tsk), (state_value)) -#endif #define __set_current_state(state_value) \ do { current->state = (state_value); } while (0) -#ifdef CONFIG_SMP #define set_current_state(state_value) \ set_mb(current->state, (state_value)) -#else -#define set_current_state(state_value) \ - __set_current_state(state_value) -#endif /* * Scheduling policies |
