diff options
| author | Ingo Molnar <mingo@elte.hu> | 2008-06-25 06:32:01 -0400 |
|---|---|---|
| committer | Ingo Molnar <mingo@elte.hu> | 2008-06-25 06:32:01 -0400 |
| commit | da7878d75b8520c9ae00d27dfbbce546a7bfdfbb (patch) | |
| tree | 547fd497a80818a60ac36831377d5df97868173c /include/linux/sched.h | |
| parent | 0e50a4c6ab94ffe7e5515b86b5df9e5abc8c6b13 (diff) | |
| parent | 543cf4cb3fe6f6cae3651ba918b9c56200b257d0 (diff) | |
Merge branch 'linus' into x86/pebs
Diffstat (limited to 'include/linux/sched.h')
| -rw-r--r-- | include/linux/sched.h | 16 |
1 files changed, 15 insertions, 1 deletions
diff --git a/include/linux/sched.h b/include/linux/sched.h index 5395a6176f4b..c5d3f847ca8d 100644 --- a/include/linux/sched.h +++ b/include/linux/sched.h | |||
| @@ -766,7 +766,6 @@ struct sched_domain { | |||
| 766 | struct sched_domain *child; /* bottom domain must be null terminated */ | 766 | struct sched_domain *child; /* bottom domain must be null terminated */ |
| 767 | struct sched_group *groups; /* the balancing groups of the domain */ | 767 | struct sched_group *groups; /* the balancing groups of the domain */ |
| 768 | cpumask_t span; /* span of all CPUs in this domain */ | 768 | cpumask_t span; /* span of all CPUs in this domain */ |
| 769 | int first_cpu; /* cache of the first cpu in this domain */ | ||
| 770 | unsigned long min_interval; /* Minimum balance interval ms */ | 769 | unsigned long min_interval; /* Minimum balance interval ms */ |
| 771 | unsigned long max_interval; /* Maximum balance interval ms */ | 770 | unsigned long max_interval; /* Maximum balance interval ms */ |
| 772 | unsigned int busy_factor; /* less balancing by factor if busy */ | 771 | unsigned int busy_factor; /* less balancing by factor if busy */ |
| @@ -1848,7 +1847,9 @@ extern void exit_thread(void); | |||
| 1848 | extern void exit_files(struct task_struct *); | 1847 | extern void exit_files(struct task_struct *); |
| 1849 | extern void __cleanup_signal(struct signal_struct *); | 1848 | extern void __cleanup_signal(struct signal_struct *); |
| 1850 | extern void __cleanup_sighand(struct sighand_struct *); | 1849 | extern void __cleanup_sighand(struct sighand_struct *); |
| 1850 | |||
| 1851 | extern void exit_itimers(struct signal_struct *); | 1851 | extern void exit_itimers(struct signal_struct *); |
| 1852 | extern void flush_itimer_signals(void); | ||
| 1852 | 1853 | ||
| 1853 | extern NORET_TYPE void do_group_exit(int); | 1854 | extern NORET_TYPE void do_group_exit(int); |
| 1854 | 1855 | ||
| @@ -2025,6 +2026,19 @@ static inline int fatal_signal_pending(struct task_struct *p) | |||
| 2025 | return signal_pending(p) && __fatal_signal_pending(p); | 2026 | return signal_pending(p) && __fatal_signal_pending(p); |
| 2026 | } | 2027 | } |
| 2027 | 2028 | ||
| 2029 | static inline int signal_pending_state(long state, struct task_struct *p) | ||
| 2030 | { | ||
| 2031 | if (!(state & (TASK_INTERRUPTIBLE | TASK_WAKEKILL))) | ||
| 2032 | return 0; | ||
| 2033 | if (!signal_pending(p)) | ||
| 2034 | return 0; | ||
| 2035 | |||
| 2036 | if (state & (__TASK_STOPPED | __TASK_TRACED)) | ||
| 2037 | return 0; | ||
| 2038 | |||
| 2039 | return (state & TASK_INTERRUPTIBLE) || __fatal_signal_pending(p); | ||
| 2040 | } | ||
| 2041 | |||
| 2028 | static inline int need_resched(void) | 2042 | static inline int need_resched(void) |
| 2029 | { | 2043 | { |
| 2030 | return unlikely(test_thread_flag(TIF_NEED_RESCHED)); | 2044 | return unlikely(test_thread_flag(TIF_NEED_RESCHED)); |
