aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2008-12-14 15:46:01 -0800
committerLinus Torvalds <torvalds@linux-foundation.org>2008-12-14 16:23:17 -0800
commitca7e716c7833aeaeb8fedd6d004c5f5d5e14d325 (patch)
tree70a7846a35d880ee3efe3d664d71d3711af64a7d
parent5279585ff2bedc8180da5bdf8aa3ff1736466de2 (diff)
downloadkernel_samsung_espresso10-ca7e716c7833aeaeb8fedd6d004c5f5d5e14d325.zip
kernel_samsung_espresso10-ca7e716c7833aeaeb8fedd6d004c5f5d5e14d325.tar.gz
kernel_samsung_espresso10-ca7e716c7833aeaeb8fedd6d004c5f5d5e14d325.tar.bz2
Revert "sched_clock: prevent scd->clock from moving backwards"
This reverts commit 5b7dba4ff834259a5623e03a565748704a8fe449, which caused a regression in hibernate, reported by and bisected by Fabio Comolli. This revert fixes http://bugzilla.kernel.org/show_bug.cgi?id=12155 http://bugzilla.kernel.org/show_bug.cgi?id=12149 Bisected-by: Fabio Comolli <fabio.comolli@gmail.com> Requested-by: Rafael J. Wysocki <rjw@sisk.pl> Acked-by: Dave Kleikamp <shaggy@linux.vnet.ibm.com> Cc: Peter Zijlstra <a.p.zijlstra@chello.nl> Cc: Ingo Molnar <mingo@elte.hu> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
-rw-r--r--kernel/sched_clock.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/kernel/sched_clock.c b/kernel/sched_clock.c
index 8178724..e8ab096 100644
--- a/kernel/sched_clock.c
+++ b/kernel/sched_clock.c
@@ -118,13 +118,13 @@ static u64 __update_sched_clock(struct sched_clock_data *scd, u64 now)
/*
* scd->clock = clamp(scd->tick_gtod + delta,
- * max(scd->tick_gtod, scd->clock),
- * max(scd->clock, scd->tick_gtod + TICK_NSEC));
+ * max(scd->tick_gtod, scd->clock),
+ * scd->tick_gtod + TICK_NSEC);
*/
clock = scd->tick_gtod + delta;
min_clock = wrap_max(scd->tick_gtod, scd->clock);
- max_clock = wrap_max(scd->clock, scd->tick_gtod + TICK_NSEC);
+ max_clock = scd->tick_gtod + TICK_NSEC;
clock = wrap_max(clock, min_clock);
clock = wrap_min(clock, max_clock);