On Thu, 2007-08-23 at 14:05 -0700, john stultz wrote:
Ok, since no one screamed too badly about this one, and it does fix this
issue, I'm sending it out for reals.
I think Bob's patch which addresses duplicate clocksources should go in,
but this one is a little more forceful in keeping the wrong hpet
clocksource from possibly being selected.
Andrew, would you mind picking this up?
thanks
-john
The ia64 hpet clocksource was implemented in generic code, and is not
yet ready to replace the i386 and x86_64 implementations. This results
in multiple hpet clocksources being registered, and if the ia64 one is
chosen on x86_64 some users have experienced hangs.
This patch only allows the generic implementation to be used on ia64,
until the duplicate i386 and x86_64 versions can be merged in and
tested.
Signed-off-by: John Stultz <johnstul@us.ibm.com>
diff --git a/drivers/char/hpet.c b/drivers/char/hpet.c
index 77bf4aa..c782d8c 100644
--- a/drivers/char/hpet.c
+++ b/drivers/char/hpet.c
@@ -78,7 +78,17 @@ static struct clocksource clocksource_hpet = {
.shift = 10,
.flags = CLOCK_SOURCE_IS_CONTINUOUS,
};
+
+/* XXX - FIXME: i386, x86_64 and ia64 all have separate
+ * hpet clocksource implementations. They should be merged
+ * and this would be a good place for it.
+ * Right now this is ia64 only.
+ */
+#ifdef CONFIG_IA64
static struct clocksource *hpet_clocksource;
+#else /* this isn't generic enough to use for everyone yet */
+static struct clocksource *hpet_clocksource = (struct clocksource*)0xdead;
+#endif
/* A lock for concurrent access by app and isr hpet activity. */
static DEFINE_SPINLOCK(hpet_lock);
-