diff options
author | Clark Williams <williams@redhat.com> | 2013-02-07 10:47:04 -0500 |
---|---|---|
committer | Ingo Molnar <mingo@kernel.org> | 2013-02-07 14:51:07 -0500 |
commit | ce0dbbbb30aee6a835511d5be446462388ba9eee (patch) | |
tree | c3d4d6f64a0fe7eec9283f4413d111a8d37d7053 /include | |
parent | cf4aebc292fac7f34f8345664320e9d4a42ca76c (diff) |
sched/rt: Add a tuning knob to allow changing SCHED_RR timeslice
Add a /proc/sys/kernel scheduler knob named
sched_rr_timeslice_ms that allows global changing of the
SCHED_RR timeslice value. User visable value is in milliseconds
but is stored as jiffies. Setting to 0 (zero) resets to the
default (currently 100ms).
Signed-off-by: Clark Williams <williams@redhat.com>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Steven Rostedt <rostedt@goodmis.org>
Link: http://lkml.kernel.org/r/20130207094704.13751796@riff.lan
Signed-off-by: Ingo Molnar <mingo@kernel.org>
Diffstat (limited to 'include')
-rw-r--r-- | include/linux/sched/sysctl.h | 15 |
1 files changed, 14 insertions, 1 deletions
diff --git a/include/linux/sched/sysctl.h b/include/linux/sched/sysctl.h index bac914e458ca..d2bb0ae979d0 100644 --- a/include/linux/sched/sysctl.h +++ b/include/linux/sched/sysctl.h | |||
@@ -73,6 +73,13 @@ static inline unsigned int get_sysctl_timer_migration(void) | |||
73 | return 1; | 73 | return 1; |
74 | } | 74 | } |
75 | #endif | 75 | #endif |
76 | |||
77 | /* | ||
78 | * control realtime throttling: | ||
79 | * | ||
80 | * /proc/sys/kernel/sched_rt_period_us | ||
81 | * /proc/sys/kernel/sched_rt_runtime_us | ||
82 | */ | ||
76 | extern unsigned int sysctl_sched_rt_period; | 83 | extern unsigned int sysctl_sched_rt_period; |
77 | extern int sysctl_sched_rt_runtime; | 84 | extern int sysctl_sched_rt_runtime; |
78 | 85 | ||
@@ -90,7 +97,13 @@ extern unsigned int sysctl_sched_autogroup_enabled; | |||
90 | */ | 97 | */ |
91 | #define RR_TIMESLICE (100 * HZ / 1000) | 98 | #define RR_TIMESLICE (100 * HZ / 1000) |
92 | 99 | ||
93 | int sched_rt_handler(struct ctl_table *table, int write, | 100 | extern int sched_rr_timeslice; |
101 | |||
102 | extern int sched_rr_handler(struct ctl_table *table, int write, | ||
103 | void __user *buffer, size_t *lenp, | ||
104 | loff_t *ppos); | ||
105 | |||
106 | extern int sched_rt_handler(struct ctl_table *table, int write, | ||
94 | void __user *buffer, size_t *lenp, | 107 | void __user *buffer, size_t *lenp, |
95 | loff_t *ppos); | 108 | loff_t *ppos); |
96 | 109 | ||