diff options
author | Ingo Molnar <mingo@elte.hu> | 2006-07-03 03:25:06 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@g5.osdl.org> | 2006-07-03 18:27:06 -0400 |
commit | 243c7621aac4ed1aa79524c9a1cecf7c05a28124 (patch) | |
tree | d8f7a1fce57c9349183bfd9ab6738a763078db85 /kernel | |
parent | 8b8f319fc7f4ab59f567d6a401a62659b3d37007 (diff) |
[PATCH] lockdep: annotate genirq
Teach special (recursive) locking code to the lock validator. Has no effect
on non-lockdep kernels.
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Arjan van de Ven <arjan@linux.intel.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'kernel')
-rw-r--r-- | kernel/irq/handle.c | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/kernel/irq/handle.c b/kernel/irq/handle.c index aeb6e391276c..a7b497ee919e 100644 --- a/kernel/irq/handle.c +++ b/kernel/irq/handle.c | |||
@@ -249,3 +249,19 @@ out: | |||
249 | return 1; | 249 | return 1; |
250 | } | 250 | } |
251 | 251 | ||
252 | #ifdef CONFIG_TRACE_IRQFLAGS | ||
253 | |||
254 | /* | ||
255 | * lockdep: we want to handle all irq_desc locks as a single lock-class: | ||
256 | */ | ||
257 | static struct lock_class_key irq_desc_lock_class; | ||
258 | |||
259 | void early_init_irq_lock_class(void) | ||
260 | { | ||
261 | int i; | ||
262 | |||
263 | for (i = 0; i < NR_IRQS; i++) | ||
264 | lockdep_set_class(&irq_desc[i].lock, &irq_desc_lock_class); | ||
265 | } | ||
266 | |||
267 | #endif | ||