diff options
author | John Stultz <[email protected]> | 2016-03-17 14:20:54 -0700 |
---|---|---|
committer | Linus Torvalds <[email protected]> | 2016-03-17 15:09:34 -0700 |
commit | 5de23d435e88996b1efe0e2cebe242074ce67c9e (patch) | |
tree | 05a4398e63bdb5f2151dfff33894c5f5b4061822 /kernel/async.c | |
parent | da8b44d5a9f8bf26da637b7336508ca534d6b319 (diff) |
proc: add /proc/<pid>/timerslack_ns interface
This patch provides a proc/PID/timerslack_ns interface which exposes a
task's timerslack value in nanoseconds and allows it to be changed.
This allows power/performance management software to set timer slack for
other threads according to its policy for the thread (such as when the
thread is designated foreground vs. background activity)
If the value written is non-zero, slack is set to that value. Otherwise
sets it to the default for the thread.
This interface checks that the calling task has permissions to to use
PTRACE_MODE_ATTACH_FSCREDS on the target task, so that we can ensure
arbitrary apps do not change the timer slack for other apps.
Signed-off-by: John Stultz <[email protected]>
Acked-by: Kees Cook <[email protected]>
Cc: Arjan van de Ven <[email protected]>
Cc: Thomas Gleixner <[email protected]>
Cc: Oren Laadan <[email protected]>
Cc: Ruchi Kandoi <[email protected]>
Cc: Rom Lemarchand <[email protected]>
Cc: Android Kernel Team <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
Diffstat (limited to 'kernel/async.c')
0 files changed, 0 insertions, 0 deletions