lkml.org 
[lkml]   [2016]   [Feb]   [5]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH] prctl: Add PR_SET_TIMERSLACK_PID for setting timer slack of an arbitrary thread.
From
Date
On 2/5/2016 4:51 PM, John Stultz wrote:
> On Fri, Feb 5, 2016 at 2:35 PM, John Stultz <john.stultz@linaro.org> wrote:
>> On Fri, Feb 5, 2016 at 12:50 PM, Andrew Morton
>> <akpm@linux-foundation.org> wrote:
>>> On Fri, 5 Feb 2016 12:44:04 -0800 Kees Cook <keescook@chromium.org> wrote:
>>>> Could this be exposed as a writable /proc entry instead? Like the oom_* stuff?
>>>
>>> /proc/<pid>/timer_slack_ns, guarded by ptrace_may_access(), documented
>>> under Documentation/? Yup, that would work. It's there for all
>>> architectures from day one and there is precedent. It's not as nice,
>>> but /proc nasties will always be with us.
>>
>> Ok. I'll start working on that.
>
> Arjan/Thomas: One curious thing I noticed here while writing some
> documentation. The timer_slack_ns value in the task struct is a
> unsigned long.
>
> So this means PR_SET_TIMERSLACK limits the maximum slack on 32 bit
> machines to ~4 seconds. Where on 64bit machines it can be quite a bit
> longer (unreasonably long, really :).

originally when we created timerslack, 4 seconds was an eternity and good enough for everyone
by a mile... (assumption was practical upper limit being in the 15 msec range)
and most of the RT guys would only tolerate a little bit of it

is there any real/practial use of going longer than 4 seconds? if there
is then yeah fixing it makes sense.
if it's just theoretical... shrug... 32 bit systems have a bunch of
other limits/differences a well.

\
 
 \ /
  Last update: 2016-02-06 04:01    [W:0.184 / U:0.180 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site