Re: Early hang with 2.6.21-rc4-rt1

From: Ingo Molnar
Date: Sun Mar 25 2007 - 04:07:49 EST



* Ingo Molnar <mingo@xxxxxxx> wrote:

> hm - on 32-bit, CRITICAL_IRQSOFF_TIMING+FUNCTION_TRACING works fine
> for me. I'll try the 64-bit kernel too.

the 64-bit kernel indeed hangs. Does the patch below fix it for you?

Ingo

Index: linux/kernel/timer.c
===================================================================
--- linux.orig/kernel/timer.c
+++ linux/kernel/timer.c
@@ -822,8 +822,23 @@ EXPORT_SYMBOL(xtime);
/* XXX - all of this timekeeping code should be later moved to time.c */
#include <linux/clocksource.h>

+/*
+ * Dummy clocksource just in case someone tries to use the
+ * clocksource infrastructure before timekeeping_init() is
+ * called:
+ */
+static notrace cycle_t read_boot(void)
+{
+ return 0;
+}
+
+static __initdata struct clocksource clocksource_boot = {
+ .name = "boot",
+ .read = read_boot,
+};
+
/* pointer to current clocksource: */
-static __read_mostly struct clocksource *clock;
+static __read_mostly struct clocksource *clock = &clocksource_boot;

#ifdef CONFIG_GENERIC_TIME
/**
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/