]> git.karo-electronics.de Git - karo-tx-linux.git/commit
sched/core: Simplify update_rq_clock() in __schedule()
authorPeter Zijlstra <peterz@infradead.org>
Tue, 21 Feb 2017 13:40:35 +0000 (14:40 +0100)
committerIngo Molnar <mingo@kernel.org>
Thu, 16 Mar 2017 08:46:24 +0000 (09:46 +0100)
commitbce4dc80c66ad355c74e876c82ce371020754627
tree94a1afef37ef4e07aa903198bbed8f79a59d10df
parent77558e4d01ac0c7fa8cb1af4a61c2ab508d79f30
sched/core: Simplify update_rq_clock() in __schedule()

Instead of relying on deactivate_task() to call update_rq_clock() and
handling the case where it didn't happen (task_on_rq_queued),
unconditionally do update_rq_clock() and skip any further updates.

This also avoids a double update on deactivate_task() + ttwu_local().

Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Mike Galbraith <efault@gmx.de>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Thomas Gleixner <tglx@linutronix.de>
Signed-off-by: Ingo Molnar <mingo@kernel.org>
kernel/sched/core.c