From: Rik van Riel Date: Mon, 27 Jan 2014 22:03:46 +0000 (-0500) Subject: sched/numa: Do statistics calculation using local variables only X-Git-Tag: v3.15-rc1~116^2~59 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=35664fd41e1c8cc4f0b89f6a51db5af39ba50640;p=pandora-kernel.git sched/numa: Do statistics calculation using local variables only The current code in task_numa_placement calculates the difference between the old and the new value, but also temporarily stores half of the old value in the per-process variables. The NUMA balancing code looks at those per-process variables, and having other tasks temporarily see halved statistics could lead to unwanted numa migrations. This can be avoided by doing all the math in local variables. This change also simplifies the code a little. Signed-off-by: Rik van Riel Acked-by: Mel Gorman Signed-off-by: Peter Zijlstra Cc: Chegu Vinod Link: http://lkml.kernel.org/r/1390860228-21539-8-git-send-email-riel@redhat.com Signed-off-by: Ingo Molnar --- Reading git-diff-tree failed