Skip to content
  • Con Kolivas's avatar
    [PATCH] sched: correct smp_nice_bias · 6dd4a85b
    Con Kolivas authored
    
    
    The priority biasing was off by mutliplying the total load by the total
    priority bias and this ruins the ratio of loads between runqueues. This
    patch should correct the ratios of loads between runqueues to be proportional
    to overall load. -2nd attempt.
    
    From: Dave Kleikamp <shaggy@austin.ibm.com>
    
      This patch fixes a divide-by-zero error that I hit on a two-way i386
      machine.  rq->nr_running is tested to be non-zero, but may change by the
      time it is used in the division.  Saving the value to a local variable
      ensures that the same value that is checked is used in the division.
    
    Signed-off-by: default avatarCon Kolivas <kernel@kolivas.org>
    Signed-off-by: default avatarDave Kleikamp <shaggy@austin.ibm.com>
    Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
    Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
    6dd4a85b