[<prev] [next>] [day] [month] [year] [list]
Message-ID: <tip-94d25649812b7d7055c162c7d910e94d3d213d34@git.kernel.org>
Date: Thu, 9 Jul 2009 12:04:08 GMT
From: tip-bot for Thomas Gleixner <tglx@...utronix.de>
To: linux-tip-commits@...r.kernel.org
Cc: linux-kernel@...r.kernel.org, hpa@...or.com, mingo@...hat.com,
tglx@...utronix.de
Subject: [tip:timers/urgent] hrtimer: migration: always subtract base->offset
Commit-ID: 94d25649812b7d7055c162c7d910e94d3d213d34
Gitweb: http://git.kernel.org/tip/94d25649812b7d7055c162c7d910e94d3d213d34
Author: Thomas Gleixner <tglx@...utronix.de>
AuthorDate: Thu, 9 Jul 2009 12:49:34 +0200
Committer: Thomas Gleixner <tglx@...utronix.de>
CommitDate: Thu, 9 Jul 2009 13:58:06 +0200
hrtimer: migration: always subtract base->offset
The new timer migration code treats the !HIGHRES case special when
calculating the CLOCK_MONOTONIC based expiry time to validate whether
a timer should be enqueued on a different CPU or not.
This is wrong as a CLOCK_REALTIME based timer expiry value needs to be
converted to CLOCK_MONOTONIC in any case.
Cc: Arun Bharadwaj <arun@...ux.vnet.ibm.com
LKML-Reference: <new-submission>
Signed-off-by: Thomas Gleixner <tglx@...utronix.de>
---
kernel/hrtimer.c | 7 +------
1 files changed, 1 insertions(+), 6 deletions(-)
diff --git a/kernel/hrtimer.c b/kernel/hrtimer.c
index 9002958..0d43451 100644
--- a/kernel/hrtimer.c
+++ b/kernel/hrtimer.c
@@ -236,13 +236,8 @@ again:
/* Optimized away for NOHZ=n SMP=n */
if (cpu == preferred_cpu) {
/* Calculate clock monotonic expiry time */
-#ifdef CONFIG_HIGH_RES_TIMERS
ktime_t expires = ktime_sub(hrtimer_get_expires(timer),
- new_base->offset);
-#else
- ktime_t expires = hrtimer_get_expires(timer);
-#endif
-
+ new_base->offset);
/*
* Get the next event on target cpu from the
* clock events layer.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists