aboutsummaryrefslogtreecommitdiffstats
path: root/kernel
diff options
context:
space:
mode:
authorMathieu Desnoyers <mathieu.desnoyers@polymtl.ca>2007-02-10 04:43:43 -0500
committerLinus Torvalds <torvalds@woody.linux-foundation.org>2007-02-11 13:51:20 -0500
commitdc29a3657b52ac687970d81d7194cf4238702124 (patch)
tree1c0844c2a87468935875763f537303b2652498ca /kernel
parent38135614ddef4de16d5cdf03c2717e88b97dd2ab (diff)
[PATCH] kernel/time/clocksource.c needs struct task_struct on m68k
kernel/time/clocksource.c needs struct task_struct on m68k. Because it uses spin_unlock_irq(), which, on m68k, uses hardirq_count(), which uses preempt_count(), which needs to dereference struct task_struct, we have to include sched.h. Because it would cause a loop inclusion, we cannot include sched.h in any other of asm-m68k/system.h, linux/thread_info.h, linux/hardirq.h, which leaves this ugly include in a C file as the only simple solution. Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@polymtl.ca> Cc: Ingo Molnar <mingo@elte.hu> Cc: Roman Zippel <zippel@linux-m68k.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: <stable@kernel.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'kernel')
-rw-r--r--kernel/time/clocksource.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/kernel/time/clocksource.c b/kernel/time/clocksource.c
index 22504afc0d34..d9ef176c4e09 100644
--- a/kernel/time/clocksource.c
+++ b/kernel/time/clocksource.c
@@ -28,6 +28,7 @@
28#include <linux/sysdev.h> 28#include <linux/sysdev.h>
29#include <linux/init.h> 29#include <linux/init.h>
30#include <linux/module.h> 30#include <linux/module.h>
31#include <linux/sched.h> /* for spin_unlock_irq() using preempt_count() m68k */
31 32
32/* XXX - Would like a better way for initializing curr_clocksource */ 33/* XXX - Would like a better way for initializing curr_clocksource */
33extern struct clocksource clocksource_jiffies; 34extern struct clocksource clocksource_jiffies;