aboutsummaryrefslogtreecommitdiffstats
path: root/kernel/sched
diff options
context:
space:
mode:
authorManuel Schölling <manuel.schoelling@gmx.de>2014-05-22 13:45:23 -0400
committerIngo Molnar <mingo@kernel.org>2014-06-05 05:52:02 -0400
commit2538d960d0c74cdc639f05723e04a67aed1efdf9 (patch)
tree05132dfa4b4caf1c4067a09cd96557d2956a5ecc /kernel/sched
parented61bbc69c773465782476c7e5869fa5607fa73a (diff)
sched/fair: Use time_after() in record_wakee()
To be future-proof and for better readability the time comparisons are modified to use time_after() instead of plain, error-prone math. Signed-off-by: Manuel Schölling <manuel.schoelling@gmx.de> Signed-off-by: Peter Zijlstra <peterz@infradead.org> Cc: Linus Torvalds <torvalds@linux-foundation.org> Link: http://lkml.kernel.org/r/1400780723-24626-1-git-send-email-manuel.schoelling@gmx.de Signed-off-by: Ingo Molnar <mingo@kernel.org>
Diffstat (limited to 'kernel/sched')
-rw-r--r--kernel/sched/fair.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/kernel/sched/fair.c b/kernel/sched/fair.c
index 7a0c000b6005..c63dde984956 100644
--- a/kernel/sched/fair.c
+++ b/kernel/sched/fair.c
@@ -4066,7 +4066,7 @@ static void record_wakee(struct task_struct *p)
4066 * about the boundary, really active task won't care 4066 * about the boundary, really active task won't care
4067 * about the loss. 4067 * about the loss.
4068 */ 4068 */
4069 if (jiffies > current->wakee_flip_decay_ts + HZ) { 4069 if (time_after(jiffies, current->wakee_flip_decay_ts + HZ)) {
4070 current->wakee_flips >>= 1; 4070 current->wakee_flips >>= 1;
4071 current->wakee_flip_decay_ts = jiffies; 4071 current->wakee_flip_decay_ts = jiffies;
4072 } 4072 }