]> asedeno.scripts.mit.edu Git - linux.git/commitdiff
sched/fair: Clean up load_balance() condition
authorValentin Schneider <valentin.schneider@arm.com>
Wed, 26 Sep 2018 15:12:06 +0000 (16:12 +0100)
committerIngo Molnar <mingo@kernel.org>
Sat, 3 Nov 2018 23:59:22 +0000 (00:59 +0100)
The alignment of the condition is off, clean that up.

Also, logical operators have lower precedence than bitwise/relational
operators, so remove one layer of parentheses to make the condition a
bit simpler to follow.

Signed-off-by: Valentin Schneider <valentin.schneider@arm.com>
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Cc: Dietmar.Eggemann@arm.com
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: patrick.bellasi@arm.com
Cc: vincent.guittot@linaro.org
Link: http://lkml.kernel.org/r/1537974727-30788-1-git-send-email-valentin.schneider@arm.com
Signed-off-by: Ingo Molnar <mingo@kernel.org>
kernel/sched/fair.c

index ee271bb661cc923dfa67ae5d5c45a18c71df7cb1..4e298931a7151a8f1e799b4fe1940673de6903ea 100644 (file)
@@ -8877,9 +8877,9 @@ static int load_balance(int this_cpu, struct rq *this_rq,
 
 out_one_pinned:
        /* tune up the balancing interval */
-       if (((env.flags & LBF_ALL_PINNED) &&
-                       sd->balance_interval < MAX_PINNED_INTERVAL) ||
-                       (sd->balance_interval < sd->max_interval))
+       if ((env.flags & LBF_ALL_PINNED &&
+            sd->balance_interval < MAX_PINNED_INTERVAL) ||
+           sd->balance_interval < sd->max_interval)
                sd->balance_interval *= 2;
 
        ld_moved = 0;