ANDROID: binder: fix up use of MAX_USER_RT_PRIO
Commite00eb41c0c("ANDROID: binder: add support for RT prio inheritance.") added the use of MAX_USER_RT_PRIO to the binder.c code, but that commit was never sent upstream. In commitae18ad281e("sched: Remove MAX_USER_RT_PRIO"), that define was taken away, so to fix up the build breakage, move the binder code to use MAX_RT_PRIO instead of the now-removed MAX_USER_RT_PRIO define. Hopefully this is correct, who knows, it's binder RT code! :) Bug: 34461621 Bug: 37293077 Bug: 120446518 Fixes:e00eb41c0c("ANDROID: binder: add support for RT prio inheritance.") Fixes:ae18ad281e("sched: Remove MAX_USER_RT_PRIO") Cc: Martijn Coenen <maco@google.com> Cc: Amit Pundir <amit.pundir@linaro.org> Cc: Alistair Strachan <astrachan@google.com> Cc: Todd Kjos <tkjos@google.com> Signed-off-by: Greg Kroah-Hartman <gregkh@google.com> Change-Id: I66b85e99697fdde462ec2d2ade5c92d5917896a3
This commit is contained in:
@@ -637,7 +637,7 @@ static int to_userspace_prio(int policy, int kernel_priority)
|
||||
if (is_fair_policy(policy))
|
||||
return PRIO_TO_NICE(kernel_priority);
|
||||
else
|
||||
return MAX_USER_RT_PRIO - 1 - kernel_priority;
|
||||
return MAX_RT_PRIO - 1 - kernel_priority;
|
||||
}
|
||||
|
||||
static int to_kernel_prio(int policy, int user_priority)
|
||||
@@ -645,7 +645,7 @@ static int to_kernel_prio(int policy, int user_priority)
|
||||
if (is_fair_policy(policy))
|
||||
return NICE_TO_PRIO(user_priority);
|
||||
else
|
||||
return MAX_USER_RT_PRIO - 1 - user_priority;
|
||||
return MAX_RT_PRIO - 1 - user_priority;
|
||||
}
|
||||
|
||||
static void binder_do_set_priority(struct task_struct *task,
|
||||
|
||||
Reference in New Issue
Block a user