lkml.org 
[lkml]   [2017]   [Sep]   [7]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH v2] sched: check user input value of sysctl_sched_time_avg
From
Date


On 2017/9/7 3:50, Luis R. Rodriguez wrote:
> On Mon, Sep 04, 2017 at 03:54:23PM +0800, Ethan Zhao wrote:
>> Peter,
>>
>>
>> On 2017/9/4 15:49, Peter Zijlstra wrote:
>>> On Sat, Sep 02, 2017 at 02:57:32PM +0800, Ethan Zhao wrote:
>>>> diff --git a/kernel/sysctl.c b/kernel/sysctl.c
>>>> index 6648fbb..609bed2 100644
>>>> --- a/kernel/sysctl.c
>>>> +++ b/kernel/sysctl.c
>>>> @@ -367,7 +367,7 @@ static int sysrq_sysctl_handler(struct ctl_table *table, int write,
>>>> .data = &sysctl_sched_time_avg,
>>>> .maxlen = sizeof(unsigned int),
>>>> .mode = 0644,
>>>> - .proc_handler = proc_dointvec,
>>>> + .proc_handler = sched_time_avg_handler,
>>> *sigh*, what's wrong with the below? Too easy?
>>  :),  seems I walked zigzag several cycles to get the right point.
> It sounds like negative values are not possible too, right? If so then
> you can use proc_douintvec_minmax().
 V4 has been sent days ago, please see v4.

 Thank,
 Ethan
>
> Luis
>

\
 
 \ /
  Last update: 2017-09-07 06:22    [W:0.378 / U:1.288 seconds]
©2003-2017 Jasper Spaans. hosted at Digital OceanAdvertise on this site