1 /* SPDX-License-Identifier: GPL-2.0 */
2 #ifndef _LINUX_SCHED_SYSCTL_H
3 #define _LINUX_SCHED_SYSCTL_H
5 #include <linux/types.h>
9 #ifdef CONFIG_DETECT_HUNG_TASK
10 extern int sysctl_hung_task_check_count
;
11 extern unsigned int sysctl_hung_task_panic
;
12 extern unsigned long sysctl_hung_task_timeout_secs
;
13 extern int sysctl_hung_task_warnings
;
14 extern int proc_dohung_task_timeout_secs(struct ctl_table
*table
, int write
,
16 size_t *lenp
, loff_t
*ppos
);
18 /* Avoid need for ifdefs elsewhere in the code */
19 enum { sysctl_hung_task_timeout_secs
= 0 };
22 extern unsigned int sysctl_sched_latency
;
23 extern unsigned int sysctl_sched_min_granularity
;
24 extern unsigned int sysctl_sched_wakeup_granularity
;
25 extern unsigned int sysctl_sched_child_runs_first
;
27 enum sched_tunable_scaling
{
28 SCHED_TUNABLESCALING_NONE
,
29 SCHED_TUNABLESCALING_LOG
,
30 SCHED_TUNABLESCALING_LINEAR
,
31 SCHED_TUNABLESCALING_END
,
33 extern enum sched_tunable_scaling sysctl_sched_tunable_scaling
;
35 extern unsigned int sysctl_numa_balancing_scan_delay
;
36 extern unsigned int sysctl_numa_balancing_scan_period_min
;
37 extern unsigned int sysctl_numa_balancing_scan_period_max
;
38 extern unsigned int sysctl_numa_balancing_scan_size
;
40 #ifdef CONFIG_SCHED_DEBUG
41 extern __read_mostly
unsigned int sysctl_sched_migration_cost
;
42 extern __read_mostly
unsigned int sysctl_sched_nr_migrate
;
43 extern __read_mostly
unsigned int sysctl_sched_time_avg
;
45 int sched_proc_update_handler(struct ctl_table
*table
, int write
,
46 void __user
*buffer
, size_t *length
,
51 * control realtime throttling:
53 * /proc/sys/kernel/sched_rt_period_us
54 * /proc/sys/kernel/sched_rt_runtime_us
56 extern unsigned int sysctl_sched_rt_period
;
57 extern int sysctl_sched_rt_runtime
;
59 #ifdef CONFIG_CFS_BANDWIDTH
60 extern unsigned int sysctl_sched_cfs_bandwidth_slice
;
63 #ifdef CONFIG_SCHED_AUTOGROUP
64 extern unsigned int sysctl_sched_autogroup_enabled
;
67 extern int sysctl_sched_rr_timeslice
;
68 extern int sched_rr_timeslice
;
70 extern int sched_rr_handler(struct ctl_table
*table
, int write
,
71 void __user
*buffer
, size_t *lenp
,
74 extern int sched_rt_handler(struct ctl_table
*table
, int write
,
75 void __user
*buffer
, size_t *lenp
,
78 extern int sysctl_numa_balancing(struct ctl_table
*table
, int write
,
79 void __user
*buffer
, size_t *lenp
,
82 extern int sysctl_schedstats(struct ctl_table
*table
, int write
,
83 void __user
*buffer
, size_t *lenp
,
86 #endif /* _LINUX_SCHED_SYSCTL_H */