• P
    sched: Fix switch_from_fair() · da7a735e
    Peter Zijlstra 提交于
    When a task is taken out of the fair class we must ensure the vruntime
    is properly normalized because when we put it back in it will assume
    to be normalized.
    
    The case that goes wrong is when changing away from the fair class
    while sleeping. Sleeping tasks have non-normalized vruntime in order
    to make sleeper-fairness work. So treat the switch away from fair as a
    wakeup and preserve the relative vruntime.
    
    Also update sysrq-n to call the ->switch_{to,from} methods.
    Reported-by: NOnkalo Samu <samu.p.onkalo@nokia.com>
    Signed-off-by: NPeter Zijlstra <a.p.zijlstra@chello.nl>
    LKML-Reference: <new-submission>
    Signed-off-by: NIngo Molnar <mingo@elte.hu>
    da7a735e
sched.c 226.7 KB