diff options
author | Peter Zijlstra <a.p.zijlstra@chello.nl> | 2009-09-15 08:43:03 -0400 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2009-09-15 10:01:05 -0400 |
commit | e9c8431185d6c406887190519f6dbdd112641686 (patch) | |
tree | 3c502201451df7bbfcd653fee940fcb40bdaaeb6 /include/linux/sched.h | |
parent | 5f3edc1b1ead6d9bd45a85c551f44eff8fe76b9f (diff) |
sched: Add TASK_WAKING
We're going to want to drop rq->lock in try_to_wake_up() for a
longer period of time, however we also want to deal with concurrent
waking of the same task, which is currently handled by holding
rq->lock.
So introduce a new TASK state, namely TASK_WAKING, which indicates
someone is already waking the task (other wakers will fail p->state
& state).
We also keep preemption disabled over the whole ttwu().
Signed-off-by: Peter Zijlstra <a.p.zijlstra@chello.nl>
LKML-Reference: <new-submission>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'include/linux/sched.h')
-rw-r--r-- | include/linux/sched.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/include/linux/sched.h b/include/linux/sched.h index 5d3c9900943e..3b0ca66bd6ce 100644 --- a/include/linux/sched.h +++ b/include/linux/sched.h | |||
@@ -190,6 +190,7 @@ extern unsigned long long time_sync_thresh; | |||
190 | /* in tsk->state again */ | 190 | /* in tsk->state again */ |
191 | #define TASK_DEAD 64 | 191 | #define TASK_DEAD 64 |
192 | #define TASK_WAKEKILL 128 | 192 | #define TASK_WAKEKILL 128 |
193 | #define TASK_WAKING 256 | ||
193 | 194 | ||
194 | /* Convenience macros for the sake of set_task_state */ | 195 | /* Convenience macros for the sake of set_task_state */ |
195 | #define TASK_KILLABLE (TASK_WAKEKILL | TASK_UNINTERRUPTIBLE) | 196 | #define TASK_KILLABLE (TASK_WAKEKILL | TASK_UNINTERRUPTIBLE) |