summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorThomas Gleixner <tglx@linutronix.de>2011-07-17 20:46:52 +0200
committerClark Williams <williams@redhat.com>2011-12-28 16:25:38 -0600
commit54123486c1324195a6516b11f579aa48734d32db (patch)
treec1de35d4c7b43d6555fd361da78b2c340aa1c0da /include
parente10e6bfbc3b8827c4c0aef38e7cb979b8a23fd1f (diff)
sched-no-work-when-pi-blocked.patch
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Diffstat (limited to 'include')
-rw-r--r--include/linux/sched.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/include/linux/sched.h b/include/linux/sched.h
index 6adc0244802f..2d5e0ecc7c82 100644
--- a/include/linux/sched.h
+++ b/include/linux/sched.h
@@ -2091,12 +2091,20 @@ extern unsigned int sysctl_sched_cfs_bandwidth_slice;
extern int rt_mutex_getprio(struct task_struct *p);
extern void rt_mutex_setprio(struct task_struct *p, int prio);
extern void rt_mutex_adjust_pi(struct task_struct *p);
+static inline bool tsk_is_pi_blocked(struct task_struct *tsk)
+{
+ return tsk->pi_blocked_on != NULL;
+}
#else
static inline int rt_mutex_getprio(struct task_struct *p)
{
return p->normal_prio;
}
# define rt_mutex_adjust_pi(p) do { } while (0)
+static inline bool tsk_is_pi_blocked(struct task_struct *tsk)
+{
+ return false;
+}
#endif
extern bool yield_to(struct task_struct *p, bool preempt);