aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux
diff options
context:
space:
mode:
Diffstat (limited to 'include/linux')
-rw-r--r--include/linux/sched.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/include/linux/sched.h b/include/linux/sched.h
index f4d969e85612..eb2ae68804aa 100644
--- a/include/linux/sched.h
+++ b/include/linux/sched.h
@@ -1725,6 +1725,12 @@ static inline int has_group_leader_pid(struct task_struct *p)
1725 return p->pid == p->tgid; 1725 return p->pid == p->tgid;
1726} 1726}
1727 1727
1728static inline
1729int same_thread_group(struct task_struct *p1, struct task_struct *p2)
1730{
1731 return p1->tgid == p2->tgid;
1732}
1733
1728static inline struct task_struct *next_thread(const struct task_struct *p) 1734static inline struct task_struct *next_thread(const struct task_struct *p)
1729{ 1735{
1730 return list_entry(rcu_dereference(p->thread_group.next), 1736 return list_entry(rcu_dereference(p->thread_group.next),