Re: [PATCH v2 3/4] hung_task: Move hung_task sysctl interface to hung_task.c

2020-05-16 Thread Xiaoming Ni
On 2020/5/17 10:43, Kees Cook wrote: On Sat, May 16, 2020 at 04:55:14PM +0800, Xiaoming Ni wrote: +/* + * This is needed for proc_doulongvec_minmax of sysctl_hung_task_timeout_secs + * and hung_task_check_interval_secs + */ +static unsigned long hung_task_timeout_max = (LONG_MAX / HZ); Please

Re: [PATCH v2 3/4] hung_task: Move hung_task sysctl interface to hung_task.c

2020-05-16 Thread Kees Cook
On Sat, May 16, 2020 at 04:55:14PM +0800, Xiaoming Ni wrote: > +/* > + * This is needed for proc_doulongvec_minmax of sysctl_hung_task_timeout_secs > + * and hung_task_check_interval_secs > + */ > +static unsigned long hung_task_timeout_max = (LONG_MAX / HZ); Please make this const. With that

[PATCH v2 3/4] hung_task: Move hung_task sysctl interface to hung_task.c

2020-05-16 Thread Xiaoming Ni
Move hung_task sysctl interface to hung_task.c. Use register_sysctl() to register the sysctl interface to avoid merge conflicts when different features modify sysctl.c at the same time. Signed-off-by: Xiaoming Ni --- include/linux/sched/sysctl.h | 8 +- kernel/hung_task.c | 63