diff options
author | Tim Murray <timmurray@google.com> | 2015-09-18 13:18:49 -0700 |
---|---|---|
committer | Tim Murray <timmurray@google.com> | 2015-09-18 13:18:49 -0700 |
commit | cba6ad7449bf8027bf045c9a60ff0821e84f3726 (patch) | |
tree | 515c4b26e2aea252f35f7a39a7dd44fe6a40c347 /rootdir | |
parent | 93807d472d7c3745cae539af881aefbf5e211d5f (diff) | |
download | system_core-cba6ad7449bf8027bf045c9a60ff0821e84f3726.zip system_core-cba6ad7449bf8027bf045c9a60ff0821e84f3726.tar.gz system_core-cba6ad7449bf8027bf045c9a60ff0821e84f3726.tar.bz2 |
add system-background cpuset
add a new cpuset for system services that should not run on
larger cores
bug 24144797
Change-Id: I21a54f0d6b46b3b8bd8c4564b8685c88cfc4a57d
Diffstat (limited to 'rootdir')
-rw-r--r-- | rootdir/init.rc | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/rootdir/init.rc b/rootdir/init.rc index 2b1a97c..8ea72e8 100644 --- a/rootdir/init.rc +++ b/rootdir/init.rc @@ -143,14 +143,20 @@ on init mkdir /dev/cpuset/foreground mkdir /dev/cpuset/foreground/boost mkdir /dev/cpuset/background + # system-background is for system tasks that should only run on + # little cores, not on bigs + # to be used only by init, so don't change the permissions + mkdir /dev/cpuset/system-background # this ensures that the cpusets are present and usable, but the device's # init.rc must actually set the correct cpus write /dev/cpuset/foreground/cpus 0 write /dev/cpuset/foreground/boost/cpus 0 write /dev/cpuset/background/cpus 0 + write /dev/cpuset/system-background/cpus 0 write /dev/cpuset/foreground/mems 0 write /dev/cpuset/foreground/boost/mems 0 write /dev/cpuset/background/mems 0 + write /dev/cpuset/system-background/mems 0 chown system system /dev/cpuset chown system system /dev/cpuset/foreground chown system system /dev/cpuset/foreground/boost @@ -548,9 +554,11 @@ service logd /system/bin/logd socket logdr seqpacket 0666 logd logd socket logdw dgram 0222 logd logd group root system + writepid /dev/cpuset/system-background/tasks service logd-reinit /system/bin/logd --reinit oneshot + writepid /dev/cpuset/system-background/tasks disabled service healthd /sbin/healthd @@ -585,6 +593,7 @@ service lmkd /system/bin/lmkd class core critical socket lmkd seqpacket 0660 system system + writepid /dev/cpuset/system-background/tasks service servicemanager /system/bin/servicemanager class core @@ -614,9 +623,11 @@ service netd /system/bin/netd service debuggerd /system/bin/debuggerd class main + writepid /dev/cpuset/system-background/tasks service debuggerd64 /system/bin/debuggerd64 class main + writepid /dev/cpuset/system-background/tasks service ril-daemon /system/bin/rild class main @@ -631,6 +642,7 @@ service surfaceflinger /system/bin/surfaceflinger user system group graphics drmrpc onrestart restart zygote + writepid /dev/cpuset/system-background/tasks service drm /system/bin/drmserver class main @@ -725,6 +737,7 @@ service perfprofd /system/xbin/perfprofd class late_start user root oneshot + writepid /dev/cpuset/system-background/tasks on property:persist.logd.logpersistd=logcatd # all exec/services are called with umask(077), so no gain beyond 0700 @@ -739,3 +752,4 @@ service logcatd /system/bin/logcat -b all -v threadtime -v usec -v printable -D # logd for write to /data/misc/logd, log group for read from log daemon user logd group log + writepid /dev/cpuset/system-background/tasks |