irq, fs/proc: replace loop with nr_irqs for proc/stat
Replace another nr_irqs loop to avoid the allocation of all sparse irq entries - use for_each_irq_desc instead. v2: make sure arch without GENERIC_HARDIRQS works too Signed-off-by: Yinghai Lu <yhlu.kernel@gmail.com> Signed-off-by: Ingo Molnar <mingo@elte.hu>
This commit is contained in:
@ -17,6 +17,11 @@
|
||||
|
||||
extern int nr_irqs;
|
||||
|
||||
#ifndef CONFIG_GENERIC_HARDIRQS
|
||||
#define for_each_irq_desc(irq, desc) \
|
||||
for (irq = 0; irq < nr_irqs; irq++)
|
||||
#endif
|
||||
|
||||
/*
|
||||
* These correspond to the IORESOURCE_IRQ_* defines in
|
||||
* linux/ioport.h to select the interrupt line behaviour. When
|
||||
|
Reference in New Issue
Block a user