Commit 154cd387 authored by Thomas Gleixner's avatar Thomas Gleixner

genirq: Remove early_init_irq_lock_class()

early_init_irq_lock_class() is called way before anything touches the
irq descriptors. In case of SPARSE_IRQ=y this is a NOP operation
because the radix tree is empty at this point. For the SPARSE_IRQ=n
case it's sufficient to set the lock class in early_init_irq(). 
Signed-off-by: default avatarThomas Gleixner <tglx@linutronix.de>
Reviewed-by: default avatarIngo Molnar <mingo@elte.hu>
parent 3795de23
...@@ -424,14 +424,6 @@ do { \ ...@@ -424,14 +424,6 @@ do { \
#endif /* CONFIG_LOCKDEP */ #endif /* CONFIG_LOCKDEP */
#ifdef CONFIG_GENERIC_HARDIRQS
extern void early_init_irq_lock_class(void);
#else
static inline void early_init_irq_lock_class(void)
{
}
#endif
#ifdef CONFIG_TRACE_IRQFLAGS #ifdef CONFIG_TRACE_IRQFLAGS
extern void early_boot_irqs_off(void); extern void early_boot_irqs_off(void);
extern void early_boot_irqs_on(void); extern void early_boot_irqs_on(void);
......
...@@ -556,7 +556,6 @@ asmlinkage void __init start_kernel(void) ...@@ -556,7 +556,6 @@ asmlinkage void __init start_kernel(void)
local_irq_disable(); local_irq_disable();
early_boot_irqs_off(); early_boot_irqs_off();
early_init_irq_lock_class();
/* /*
* Interrupts are still disabled. Do necessary setups, then * Interrupts are still disabled. Do necessary setups, then
......
...@@ -231,6 +231,7 @@ int __init early_irq_init(void) ...@@ -231,6 +231,7 @@ int __init early_irq_init(void)
alloc_desc_masks(&desc[i], 0, true); alloc_desc_masks(&desc[i], 0, true);
init_desc_masks(&desc[i]); init_desc_masks(&desc[i]);
desc[i].kstat_irqs = kstat_irqs_all[i]; desc[i].kstat_irqs = kstat_irqs_all[i];
lockdep_set_class(&desc[i].lock, &irq_desc_lock_class);
} }
return arch_early_irq_init(); return arch_early_irq_init();
} }
...@@ -251,16 +252,6 @@ void clear_kstat_irqs(struct irq_desc *desc) ...@@ -251,16 +252,6 @@ void clear_kstat_irqs(struct irq_desc *desc)
memset(desc->kstat_irqs, 0, nr_cpu_ids * sizeof(*(desc->kstat_irqs))); memset(desc->kstat_irqs, 0, nr_cpu_ids * sizeof(*(desc->kstat_irqs)));
} }
void early_init_irq_lock_class(void)
{
struct irq_desc *desc;
int i;
for_each_irq_desc(i, desc) {
lockdep_set_class(&desc->lock, &irq_desc_lock_class);
}
}
unsigned int kstat_irqs_cpu(unsigned int irq, int cpu) unsigned int kstat_irqs_cpu(unsigned int irq, int cpu)
{ {
struct irq_desc *desc = irq_to_desc(irq); struct irq_desc *desc = irq_to_desc(irq);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment