Bug 446060 - kernel: sched_fair.c simplify sched_slice()
Summary: kernel: sched_fair.c simplify sched_slice()
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Security Response
Classification: Other
Component: vulnerability
Version: unspecified
Hardware: All
OS: Linux
low
low
Target Milestone: ---
Assignee: Red Hat Product Security
QA Contact:
URL:
Whiteboard:
Depends On: 447501
Blocks:
TreeView+ depends on / blocked
 
Reported: 2008-05-12 14:12 UTC by Jan Lieskovsky
Modified: 2019-09-29 12:24 UTC (History)
4 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2010-12-22 16:36:52 UTC
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHSA-2008:0585 0 normal SHIPPED_LIVE Important: kernel security and bug fix update 2008-08-26 19:56:57 UTC

Description Jan Lieskovsky 2008-05-12 14:12:46 UTC
Description of problem:

The problem is in sched_slice() called by sys_sched_rr_get_interval():
time_slice = NS_TO_JIFFIES(sched_slice(cfs_rq_of(se), se));
sched_slice() will use 'cfs_rq->load.weight' as the base for a
division, which is zero for process 1.

Version-Release number of selected component (if applicable):
Linux kernel 2.6.24 up to 2.6.25.2.

Additional info:

This issue not present on RHEL kernels (sched_slice first appeared
in 2.6.24). Filling only against the Fedora kernels.


The problem itself was fixed by Ingo with this commit (I think):
http://git.kernel.org/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commitdiff;h=6a6029b8cefe0ca7e82f27f3904dbedba3de4e06
by using a different function on March 15. (2.6.25 rc phase sometime)

The code was changed back (and so broken again) to a version of the old version
6 weeks later by Peter in
http://git.kernel.org/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commitdiff;h=ac884dec6d4a7df252150af875cffddf8f1d9c15
and fixed afterwards in:
http://git.kernel.org/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commitdiff;h=8f1bc385cfbab474db6c27b5af1e439614f3025c
on a April 19 merge by Linus. (2.6.26 merge window)


Proposed upstream patch:

http://git.kernel.org/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commitdiff;h=6a6029b8cefe0ca7e82f27f3904dbedba3de4e06

Comment 7 Vincent Danen 2010-12-22 16:36:52 UTC
This was addressed via:

MRG: http://rhn.redhat.com/errata/RHSA-2008-0585.html


Note You need to log in before you can comment on or make changes to this bug.