aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux
diff options
context:
space:
mode:
Diffstat (limited to 'include/linux')
-rw-r--r--include/linux/cpu.h2
-rw-r--r--include/linux/sched.h3
2 files changed, 4 insertions, 1 deletions
diff --git a/include/linux/cpu.h b/include/linux/cpu.h
index b886dc17f2f3..ac0efae38072 100644
--- a/include/linux/cpu.h
+++ b/include/linux/cpu.h
@@ -245,6 +245,8 @@ void arch_cpu_idle_dead(void);
245int cpu_report_state(int cpu); 245int cpu_report_state(int cpu);
246int cpu_check_up_prepare(int cpu); 246int cpu_check_up_prepare(int cpu);
247void cpu_set_state_online(int cpu); 247void cpu_set_state_online(int cpu);
248void play_idle(unsigned long duration_ms);
249
248#ifdef CONFIG_HOTPLUG_CPU 250#ifdef CONFIG_HOTPLUG_CPU
249bool cpu_wait_death(unsigned int cpu, int seconds); 251bool cpu_wait_death(unsigned int cpu, int seconds);
250bool cpu_report_death(void); 252bool cpu_report_death(void);
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 */
2610static inline bool is_idle_task(const struct task_struct *p) 2611static 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}
2614extern struct task_struct *curr_task(int cpu); 2615extern struct task_struct *curr_task(int cpu);
2615extern void ia64_set_curr_task(int cpu, struct task_struct *p); 2616extern void ia64_set_curr_task(int cpu, struct task_struct *p);