Skip to content

Commit

Permalink
Replace writepid with task_profiles command for cgroup migration
Browse files Browse the repository at this point in the history
writepid command usage to join a cgroup has been deprecated in favor
of a more flexible approach using task_profiles. This way cgroup path
is not hardcoded and cgroup changes can be easily made. Replace
writepid with task_profiles command to migrate between cgroups.

Bug: 191283136
Test: build and boot
Signed-off-by: Suren Baghdasaryan <surenb@google.com>
Change-Id: I249ecc45a001a69d73b06b77154f9b6e5f9964d9
  • Loading branch information
surenbaghdasaryan authored and afterallafk committed Mar 17, 2022
1 parent 2ff8bb5 commit 23feaeb
Show file tree
Hide file tree
Showing 18 changed files with 18 additions and 18 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,6 @@ service vendor.face-hal-1-0-default /vendor/bin/hw/android.hardware.biometrics.f
class late_start
user system
group system
writepid /dev/cpuset/foreground/tasks
task_profiles ProcessCapacityHigh
capabilities SYS_NICE
rlimit rtprio 10 10
Original file line number Diff line number Diff line change
Expand Up @@ -5,4 +5,4 @@ service vendor.fps_hal /vendor/bin/hw/android.hardware.biometrics.fingerprint@2.
class late_start
user system
group system input uhid
writepid /dev/cpuset/system-background/tasks
task_profiles ServiceCapacityLow
2 changes: 1 addition & 1 deletion cas/1.0/default/android.hardware.cas@1.0-service-lazy.rc
Original file line number Diff line number Diff line change
Expand Up @@ -6,4 +6,4 @@ service vendor.cas-hal-1-0 /vendor/bin/hw/android.hardware.cas@1.0-service-lazy
user media
group mediadrm drmrpc
ioprio rt 4
writepid /dev/cpuset/foreground/tasks
task_profiles ProcessCapacityHigh
2 changes: 1 addition & 1 deletion cas/1.0/default/android.hardware.cas@1.0-service.rc
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@ service vendor.cas-hal-1-0 /vendor/bin/hw/android.hardware.cas@1.0-service
user media
group mediadrm drmrpc
ioprio rt 4
writepid /dev/cpuset/foreground/tasks
task_profiles ProcessCapacityHigh
2 changes: 1 addition & 1 deletion cas/1.1/default/android.hardware.cas@1.1-service-lazy.rc
Original file line number Diff line number Diff line change
Expand Up @@ -7,4 +7,4 @@ service vendor.cas-hal-1-1 /vendor/bin/hw/android.hardware.cas@1.1-service-lazy
user media
group mediadrm drmrpc
ioprio rt 4
writepid /dev/cpuset/foreground/tasks
task_profiles ProcessCapacityHigh
2 changes: 1 addition & 1 deletion cas/1.1/default/android.hardware.cas@1.1-service.rc
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@ service vendor.cas-hal-1-1 /vendor/bin/hw/android.hardware.cas@1.1-service
user media
group mediadrm drmrpc
ioprio rt 4
writepid /dev/cpuset/foreground/tasks
task_profiles ProcessCapacityHigh
2 changes: 1 addition & 1 deletion cas/1.2/default/android.hardware.cas@1.2-service-lazy.rc
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,4 @@ service vendor.cas-hal-1-2 /vendor/bin/hw/android.hardware.cas@1.2-service-lazy
user media
group mediadrm drmrpc
ioprio rt 4
writepid /dev/cpuset/foreground/tasks
task_profiles ProcessCapacityHigh
2 changes: 1 addition & 1 deletion cas/1.2/default/android.hardware.cas@1.2-service.rc
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@ service vendor.cas-hal-1-2 /vendor/bin/hw/android.hardware.cas@1.2-service
user media
group mediadrm drmrpc
ioprio rt 4
writepid /dev/cpuset/foreground/tasks
task_profiles ProcessCapacityHigh
2 changes: 1 addition & 1 deletion drm/1.0/default/android.hardware.drm@1.0-service-lazy.rc
Original file line number Diff line number Diff line change
Expand Up @@ -7,4 +7,4 @@ service vendor.drm-hal-1-0 /vendor/bin/hw/android.hardware.drm@1.0-service-lazy
user media
group mediadrm drmrpc
ioprio rt 4
writepid /dev/cpuset/foreground/tasks
task_profiles ProcessCapacityHigh
2 changes: 1 addition & 1 deletion drm/1.0/default/android.hardware.drm@1.0-service.rc
Original file line number Diff line number Diff line change
Expand Up @@ -5,4 +5,4 @@ service vendor.drm-hal-1-0 /vendor/bin/hw/android.hardware.drm@1.0-service
user media
group mediadrm drmrpc
ioprio rt 4
writepid /dev/cpuset/foreground/tasks
task_profiles ProcessCapacityHigh
Original file line number Diff line number Diff line change
Expand Up @@ -5,4 +5,4 @@ service vendor.hwcomposer-2-1 /vendor/bin/hw/android.hardware.graphics.composer@
group graphics drmrpc
capabilities SYS_NICE
onrestart restart surfaceflinger
writepid /dev/cpuset/system-background/tasks
task_profiles ServiceCapacityLow
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,4 @@ service vendor.hwcomposer-2-2 /vendor/bin/hw/android.hardware.graphics.composer@
group graphics drmrpc
capabilities SYS_NICE
onrestart restart surfaceflinger
writepid /dev/cpuset/system-background/tasks
task_profiles ServiceCapacityLow
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,4 @@ service vendor.hwcomposer-2-3 /vendor/bin/hw/android.hardware.graphics.composer@
group graphics drmrpc
capabilities SYS_NICE
onrestart restart surfaceflinger
writepid /dev/cpuset/system-background/tasks
task_profiles ServiceCapacityLow
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,4 @@ service vendor.hwcomposer-2-4 /vendor/bin/hw/android.hardware.graphics.composer@
group graphics drmrpc
capabilities SYS_NICE
onrestart restart surfaceflinger
writepid /dev/cpuset/system-background/tasks
task_profiles ServiceCapacityLow
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,6 @@ service vendor.sensors-hal-2-0-multihal /vendor/bin/hw/android.hardware.sensors@
class hal
user system
group system wakelock context_hub
writepid /dev/cpuset/system-background/tasks
task_profiles ServiceCapacityLow
capabilities BLOCK_SUSPEND
rlimit rtprio 10 10
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,6 @@ service vendor.sensors-hal-2-1-multihal /vendor/bin/hw/android.hardware.sensors@
class hal
user system
group system wakelock context_hub
writepid /dev/cpuset/system-background/tasks
task_profiles ServiceCapacityLow
capabilities BLOCK_SUSPEND
rlimit rtprio 10 10
Original file line number Diff line number Diff line change
Expand Up @@ -6,4 +6,4 @@ service vendor.tuner-hal-1-0 /vendor/bin/hw/android.hardware.tv.tuner@1.0-servic
user media
group mediadrm drmrpc
ioprio rt 4
writepid /dev/cpuset/foreground/tasks
task_profiles ProcessCapacityHigh
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@ service vendor.tuner-hal-1-0 /vendor/bin/hw/android.hardware.tv.tuner@1.0-servic
user media
group mediadrm drmrpc
ioprio rt 4
writepid /dev/cpuset/foreground/tasks
task_profiles ProcessCapacityHigh

0 comments on commit 23feaeb

Please sign in to comment.