]> git.baikalelectronics.ru Git - kernel.git/commit
sched/rt: Show the 'sched_rr_timeslice' SCHED_RR timeslice tuning knob in milliseconds
authorShile Zhang <shile.zhang@nokia.com>
Sat, 28 Jan 2017 14:00:49 +0000 (22:00 +0800)
committerIngo Molnar <mingo@kernel.org>
Wed, 1 Feb 2017 10:01:30 +0000 (11:01 +0100)
commit446ecd737a155751e556e28be775926b8d3e3300
treea524a4c9758a3dbc8c7156cfa410a6d7dfddca5e
parentf2d225348a23dd24d2b8e958ad6627bd96ce6cac
sched/rt: Show the 'sched_rr_timeslice' SCHED_RR timeslice tuning knob in milliseconds

We added the 'sched_rr_timeslice_ms' SCHED_RR tuning knob in this commit:

  0482148443b5 ("sched/rt: Add a tuning knob to allow changing SCHED_RR timeslice")

... which name suggests to users that it's in milliseconds, while in reality
it's being set in milliseconds but the result is shown in jiffies.

This is obviously confusing when HZ is not 1000, it makes it appear like the
value set failed, such as HZ=100:

  root# echo 100 > /proc/sys/kernel/sched_rr_timeslice_ms
  root# cat /proc/sys/kernel/sched_rr_timeslice_ms
  10

Fix this to be milliseconds all around.

Signed-off-by: Shile Zhang <shile.zhang@nokia.com>
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Mike Galbraith <efault@gmx.de>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Thomas Gleixner <tglx@linutronix.de>
Link: http://lkml.kernel.org/r/1485612049-20923-1-git-send-email-shile.zhang@nokia.com
Signed-off-by: Ingo Molnar <mingo@kernel.org>
include/linux/sched/sysctl.h
kernel/sched/core.c
kernel/sched/rt.c
kernel/sysctl.c