Snap for 7995257 from a2c0b86ad0
to sc-d2-release
Change-Id: Id7613acc197a4c4ecb63dde40018e90311c81fa2
This commit is contained in:
commit
e8ca1f8b0e
|
@ -317,10 +317,7 @@ int androidSetThreadPriority(pid_t tid, int pri)
|
|||
if (pri >= ANDROID_PRIORITY_BACKGROUND) {
|
||||
rc = SetTaskProfiles(tid, {"SCHED_SP_SYSTEM"}, true) ? 0 : -1;
|
||||
} else if (curr_pri >= ANDROID_PRIORITY_BACKGROUND) {
|
||||
SchedPolicy policy = SP_FOREGROUND;
|
||||
// Change to the sched policy group of the process.
|
||||
get_sched_policy(getpid(), &policy);
|
||||
rc = SetTaskProfiles(tid, {get_sched_policy_profile_name(policy)}, true) ? 0 : -1;
|
||||
rc = SetTaskProfiles(tid, {"SCHED_SP_FOREGROUND"}, true) ? 0 : -1;
|
||||
}
|
||||
|
||||
if (rc) {
|
||||
|
|
Loading…
Reference in New Issue