From 5dcff8f2b19a53abe7c632a22f455df396554afe Mon Sep 17 00:00:00 2001 From: Tim Murray Date: Mon, 11 Jul 2016 13:57:31 -0700 Subject: [PATCH] Add support for background stune group. bug 29512132 Change-Id: If8144bfee0fb30cf11f2bb26494ca5e83c11d4d7 --- libcutils/sched_policy.c | 2 +- rootdir/init.rc | 4 ++++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/libcutils/sched_policy.c b/libcutils/sched_policy.c index c097a1215..05a20481d 100644 --- a/libcutils/sched_policy.c +++ b/libcutils/sched_policy.c @@ -145,7 +145,7 @@ static void __initialize(void) { ta_schedboost_fd = open(filename, O_WRONLY | O_CLOEXEC); filename = "/dev/stune/foreground/tasks"; fg_schedboost_fd = open(filename, O_WRONLY | O_CLOEXEC); - filename = "/dev/stune/tasks"; + filename = "/dev/stune/background/tasks"; bg_schedboost_fd = open(filename, O_WRONLY | O_CLOEXEC); #endif } diff --git a/rootdir/init.rc b/rootdir/init.rc index 32970e434..97bfe6b9a 100644 --- a/rootdir/init.rc +++ b/rootdir/init.rc @@ -50,15 +50,19 @@ on init mkdir /dev/stune mount cgroup none /dev/stune schedtune mkdir /dev/stune/foreground + mkdir /dev/stune/background mkdir /dev/stune/top-app chown system system /dev/stune chown system system /dev/stune/foreground + chown system system /dev/stune/background chown system system /dev/stune/top-app chown system system /dev/stune/tasks chown system system /dev/stune/foreground/tasks + chown system system /dev/stune/background/tasks chown system system /dev/stune/top-app/tasks chmod 0664 /dev/stune/tasks chmod 0664 /dev/stune/foreground/tasks + chmod 0664 /dev/stune/background/tasks chmod 0664 /dev/stune/top-app/tasks # Mount staging areas for devices managed by vold