diff options
author | Ingo Molnar <mingo@elte.hu> | 2008-10-11 18:50:45 +0200 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2008-10-11 18:50:45 +0200 |
commit | 5b16a2212f1840b63d6cc476b26ff9349dab185e (patch) | |
tree | 1fc6fbc12ff101f6067edd00242475290b364684 /kernel | |
parent | Merge branch 'rcu-v28-for-linus' of git://git.kernel.org/pub/scm/linux/kernel... (diff) | |
parent | sched_clock: prevent scd->clock from moving backwards (diff) | |
download | linux-5b16a2212f1840b63d6cc476b26ff9349dab185e.tar.xz linux-5b16a2212f1840b63d6cc476b26ff9349dab185e.zip |
Merge branch 'sched/clock' into sched/urgent
Diffstat (limited to 'kernel')
-rw-r--r-- | kernel/sched_clock.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/kernel/sched_clock.c b/kernel/sched_clock.c index e8ab096ddfe3..81787248b60f 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), - * scd->tick_gtod + TICK_NSEC); + * max(scd->tick_gtod, scd->clock), + * max(scd->clock, scd->tick_gtod + TICK_NSEC)); */ clock = scd->tick_gtod + delta; min_clock = wrap_max(scd->tick_gtod, scd->clock); - max_clock = scd->tick_gtod + TICK_NSEC; + max_clock = wrap_max(scd->clock, scd->tick_gtod + TICK_NSEC); clock = wrap_max(clock, min_clock); clock = wrap_min(clock, max_clock); |