diff options
Diffstat (limited to 'include/linux/sched.h')
-rw-r--r-- | include/linux/sched.h | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/include/linux/sched.h b/include/linux/sched.h index 348f51b0ec92..114c7fcb6af6 100644 --- a/include/linux/sched.h +++ b/include/linux/sched.h | |||
@@ -2254,6 +2254,7 @@ extern void thread_group_cputime_adjusted(struct task_struct *p, cputime_t *ut, | |||
2254 | /* | 2254 | /* |
2255 | * Per process flags | 2255 | * Per process flags |
2256 | */ | 2256 | */ |
2257 | #define PF_IDLE 0x00000002 /* I am an IDLE thread */ | ||
2257 | #define PF_EXITING 0x00000004 /* getting shut down */ | 2258 | #define PF_EXITING 0x00000004 /* getting shut down */ |
2258 | #define PF_EXITPIDONE 0x00000008 /* pi exit done on shut down */ | 2259 | #define PF_EXITPIDONE 0x00000008 /* pi exit done on shut down */ |
2259 | #define PF_VCPU 0x00000010 /* I'm a virtual CPU */ | 2260 | #define PF_VCPU 0x00000010 /* I'm a virtual CPU */ |
@@ -2609,7 +2610,7 @@ extern struct task_struct *idle_task(int cpu); | |||
2609 | */ | 2610 | */ |
2610 | static inline bool is_idle_task(const struct task_struct *p) | 2611 | static inline bool is_idle_task(const struct task_struct *p) |
2611 | { | 2612 | { |
2612 | return p->pid == 0; | 2613 | return !!(p->flags & PF_IDLE); |
2613 | } | 2614 | } |
2614 | extern struct task_struct *curr_task(int cpu); | 2615 | extern struct task_struct *curr_task(int cpu); |
2615 | extern void ia64_set_curr_task(int cpu, struct task_struct *p); | 2616 | extern void ia64_set_curr_task(int cpu, struct task_struct *p); |