1. 079be8fc6309 sched/rt: Disallow writing invalid values to sched_rt_period_us
2. c1fc6484e1fb sched/rt: sysctl_sched_rr_timeslice show default timeslice after reset
3. c7fcb99877f9 sched/rt: Fix sysctl_sched_rr_timeslice intial value
Mantic: the 3rd is already in master-next.
Jammy: stable v5.15.150 includes the three commits.
Focal: master-next has include them after update to v5.4.270
Bionic: all the three commits are needed.
[Test case]
Run LTP update 20240312 to check the log of proc_sched_rt01.
[Regression potential]
Low risk since these content are existed in upstream for a while.
Cyril Hrubis (2):
sched/rt: sysctl_sched_rr_timeslice show default timeslice after reset
sched/rt: Disallow writing invalid values to sched_rt_period_us
Given ESM kernel only accepts CVE patches, will only send patches against Mantic
[Impact]
The updated LTP has added proc_sched_rt01 testcase which can't pass
since several commits are missed from kernel side.
Test log: bin/ltp- pan -q -e -S -a 163430 -n 163430 -f /tmp/ltp- X3Nz2HWCQe/ alltests -l /dev/null -C /dev/null -T /dev/null 6.5.0-27- generic/ build/. config' 406-gcbc2d0568 rt01.c: 45: TFAIL: Expect: timeslice_ms > 0 after reset to default rt01.c: 51: TPASS: echo 0 > /proc/sys/ kernel/ sched_rt_ period_ us : EINVAL (22) rt01.c: 53: TFAIL: echo -1 > /proc/sys/ kernel/ sched_rt_ period_ us invalid retval 2: SUCCESS (0) rt01.c: 59: TPASS: echo -2 > /proc/sys/ kernel/ sched_rt_ runtime_ us : EINVAL (22) rt01.c: 72: TFAIL: echo rt_period_us+1 > /proc/sys/ kernel/ sched_rt_ runtime_ us invalid retval 1: SUCCESS (0)
INFO: Test start time: Tue Mar 12 11:52:21 UTC 2024
COMMAND: /opt/ltp/
LOG File: /dev/null
FAILED COMMAND File: /dev/null
TCONF COMMAND File: /dev/null
Running tests.......
tst_kconfig.c:87: TINFO: Parsing kernel config '/lib/modules/
tst_test.c:1741: TINFO: LTP version: 20230929-
tst_test.c:1625: TINFO: Timeout per run is 0h 00m 30s
proc_sched_
proc_sched_
proc_sched_
proc_sched_
proc_sched_
HINT: You _MAY_ be missing kernel fixes:
https:/ /git.kernel. org/pub/ scm/linux/ kernel/ git/torvalds/ linux.git/ commit/ ?id=c1fc6484e1f b /git.kernel. org/pub/ scm/linux/ kernel/ git/torvalds/ linux.git/ commit/ ?id=079be8fc630 9
https:/
[Fix]
There are 3 relevant commits from upstream.
1. 079be8fc6309 sched/rt: Disallow writing invalid values to sched_rt_period_us sched_rr_ timeslice show default timeslice after reset sched_rr_ timeslice intial value
2. c1fc6484e1fb sched/rt: sysctl_
3. c7fcb99877f9 sched/rt: Fix sysctl_
Mantic: the 3rd is already in master-next.
Jammy: stable v5.15.150 includes the three commits.
Focal: master-next has include them after update to v5.4.270
Bionic: all the three commits are needed.
[Test case]
Run LTP update 20240312 to check the log of proc_sched_rt01.
[Regression potential]
Low risk since these content are existed in upstream for a while.
Cyril Hrubis (2): sched_rr_ timeslice show default timeslice after reset
sched/rt: sysctl_
sched/rt: Disallow writing invalid values to sched_rt_period_us
kernel/sched/rt.c | 12 ++++++++----
1 file changed, 8 insertions(+), 4 deletions(-)