diff options
author | Emmanuel Grumbach <emmanuel.grumbach@intel.com> | 2014-05-06 20:37:42 +0300 |
---|---|---|
committer | Emmanuel Grumbach <emmanuel.grumbach@intel.com> | 2014-05-06 20:37:42 +0300 |
commit | cebeb0f1885fa93c44be5d4e0b9b640210ff088c (patch) | |
tree | a33e4af4ddaa7a57f997ab9a2baceb48209670cd /kernel/locking/rtmutex.c | |
parent | 939ecf6b14c46e3448411a934418311b492bfee4 (diff) | |
parent | 48d11dc37977614a461bfedddc52d1c651bc279f (diff) |
Merge remote-tracking branch 'wireless-next/master' into iwlwifi-next
Diffstat (limited to 'kernel/locking/rtmutex.c')
-rw-r--r-- | kernel/locking/rtmutex.c | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/kernel/locking/rtmutex.c b/kernel/locking/rtmutex.c index 2e960a2bab81a..aa4dff04b594c 100644 --- a/kernel/locking/rtmutex.c +++ b/kernel/locking/rtmutex.c @@ -213,6 +213,18 @@ struct task_struct *rt_mutex_get_top_task(struct task_struct *task) } /* + * Called by sched_setscheduler() to check whether the priority change + * is overruled by a possible priority boosting. + */ +int rt_mutex_check_prio(struct task_struct *task, int newprio) +{ + if (!task_has_pi_waiters(task)) + return 0; + + return task_top_pi_waiter(task)->task->prio <= newprio; +} + +/* * Adjust the priority of a task, after its pi_waiters got modified. * * This can be both boosting and unboosting. task->pi_lock must be held. |