aboutsummaryrefslogtreecommitdiffstats
path: root/kernel/irq
diff options
context:
space:
mode:
Diffstat (limited to 'kernel/irq')
-rw-r--r--kernel/irq/handle.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/kernel/irq/handle.c b/kernel/irq/handle.c
index c20db0be917..48299a8a22f 100644
--- a/kernel/irq/handle.c
+++ b/kernel/irq/handle.c
@@ -213,6 +213,7 @@ struct irq_desc irq_desc[NR_IRQS] __cacheline_aligned_in_smp = {
213 } 213 }
214}; 214};
215 215
216static unsigned int kstat_irqs_all[NR_IRQS][NR_CPUS];
216int __init early_irq_init(void) 217int __init early_irq_init(void)
217{ 218{
218 struct irq_desc *desc; 219 struct irq_desc *desc;
@@ -222,8 +223,10 @@ int __init early_irq_init(void)
222 desc = irq_desc; 223 desc = irq_desc;
223 count = ARRAY_SIZE(irq_desc); 224 count = ARRAY_SIZE(irq_desc);
224 225
225 for (i = 0; i < count; i++) 226 for (i = 0; i < count; i++) {
226 desc[i].irq = i; 227 desc[i].irq = i;
228 desc[i].kstat_irqs = kstat_irqs_all[i];
229 }
227 230
228 return arch_early_irq_init(); 231 return arch_early_irq_init();
229} 232}
@@ -451,12 +454,10 @@ void early_init_irq_lock_class(void)
451 } 454 }
452} 455}
453 456
454#ifdef CONFIG_SPARSE_IRQ
455unsigned int kstat_irqs_cpu(unsigned int irq, int cpu) 457unsigned int kstat_irqs_cpu(unsigned int irq, int cpu)
456{ 458{
457 struct irq_desc *desc = irq_to_desc(irq); 459 struct irq_desc *desc = irq_to_desc(irq);
458 return desc ? desc->kstat_irqs[cpu] : 0; 460 return desc ? desc->kstat_irqs[cpu] : 0;
459} 461}
460#endif
461EXPORT_SYMBOL(kstat_irqs_cpu); 462EXPORT_SYMBOL(kstat_irqs_cpu);
462 463