Commit 6e17f3fc authored by Peter Zijlstra's avatar Peter Zijlstra Committed by Thomas Gleixner

sched: Rename rt_mutex_setprio to task_setprio

In RT we have multiple non-mutex users of this function. Rename it.
Signed-off-by: default avatarPeter Zijlstra <a.p.zijlstra@chello.nl>
Signed-off-by: default avatarIngo Molnar <mingo@elte.hu>
Signed-off-by: default avatarThomas Gleixner <tglx@linutronix.de>
parent 78af08d9
...@@ -1842,9 +1842,14 @@ int sched_rt_handler(struct ctl_table *table, int write, ...@@ -1842,9 +1842,14 @@ int sched_rt_handler(struct ctl_table *table, int write,
extern unsigned int sysctl_sched_compat_yield; extern unsigned int sysctl_sched_compat_yield;
extern void task_setprio(struct task_struct *p, int prio);
#ifdef CONFIG_RT_MUTEXES #ifdef CONFIG_RT_MUTEXES
extern int rt_mutex_getprio(struct task_struct *p); extern int rt_mutex_getprio(struct task_struct *p);
extern void rt_mutex_setprio(struct task_struct *p, int prio); static inline void rt_mutex_setprio(struct task_struct *p, int prio)
{
task_setprio(p, prio);
}
extern void rt_mutex_adjust_pi(struct task_struct *p); extern void rt_mutex_adjust_pi(struct task_struct *p);
#else #else
static inline int rt_mutex_getprio(struct task_struct *p) static inline int rt_mutex_getprio(struct task_struct *p)
......
...@@ -5869,19 +5869,19 @@ long __sched sleep_on_timeout(wait_queue_head_t *q, long timeout) ...@@ -5869,19 +5869,19 @@ long __sched sleep_on_timeout(wait_queue_head_t *q, long timeout)
} }
EXPORT_SYMBOL(sleep_on_timeout); EXPORT_SYMBOL(sleep_on_timeout);
#ifdef CONFIG_RT_MUTEXES
/* /*
* rt_mutex_setprio - set the current priority of a task * task_setprio - set the current priority of a task
* @p: task * @p: task
* @prio: prio value (kernel-internal form) * @prio: prio value (kernel-internal form)
* *
* This function changes the 'effective' priority of a task. It does * This function changes the 'effective' priority of a task. It does
* not touch ->normal_prio like __setscheduler(). * not touch ->normal_prio like __setscheduler().
* *
* Used by the rt_mutex code to implement priority inheritance logic. * Used by the rt_mutex code to implement priority inheritance logic
* and by rcupreempt-boost to boost priorities of tasks sleeping
* with rcu locks.
*/ */
void rt_mutex_setprio(struct task_struct *p, int prio) void task_setprio(struct task_struct *p, int prio)
{ {
unsigned long flags; unsigned long flags;
int oldprio, on_rq, running; int oldprio, on_rq, running;
...@@ -5918,8 +5918,6 @@ void rt_mutex_setprio(struct task_struct *p, int prio) ...@@ -5918,8 +5918,6 @@ void rt_mutex_setprio(struct task_struct *p, int prio)
task_rq_unlock(rq, &flags); task_rq_unlock(rq, &flags);
} }
#endif
void set_user_nice(struct task_struct *p, long nice) void set_user_nice(struct task_struct *p, long nice)
{ {
int old_prio, delta, on_rq; int old_prio, delta, on_rq;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment