aboutsummaryrefslogtreecommitdiffstats
path: root/kernel/irq
diff options
context:
space:
mode:
Diffstat (limited to 'kernel/irq')
-rw-r--r--kernel/irq/spurious.c17
1 files changed, 11 insertions, 6 deletions
diff --git a/kernel/irq/spurious.c b/kernel/irq/spurious.c
index b5d906002e1d..ec5a4bef3054 100644
--- a/kernel/irq/spurious.c
+++ b/kernel/irq/spurious.c
@@ -90,14 +90,15 @@ static int misrouted_irq(int irq)
90{ 90{
91 int i; 91 int i;
92 int ok = 0; 92 int ok = 0;
93 struct irq_desc *desc;
93 94
94 for (i = 1; i < nr_irqs; i++) { 95 for_each_irq_desc(i, desc) {
95 struct irq_desc *desc; 96 if (!i)
97 continue;
96 98
97 if (i == irq) /* Already tried */ 99 if (i == irq) /* Already tried */
98 continue; 100 continue;
99 101
100 desc = irq_to_desc(i);
101 if (try_one_irq(i, desc)) 102 if (try_one_irq(i, desc))
102 ok = 1; 103 ok = 1;
103 } 104 }
@@ -108,10 +109,14 @@ static int misrouted_irq(int irq)
108static void poll_spurious_irqs(unsigned long dummy) 109static void poll_spurious_irqs(unsigned long dummy)
109{ 110{
110 int i; 111 int i;
111 for (i = 1; i < nr_irqs; i++) { 112 struct irq_desc *desc;
112 struct irq_desc *desc = irq_to_desc(i); 113
114 for_each_irq_desc(i, desc) {
113 unsigned int status; 115 unsigned int status;
114 116
117 if (!i)
118 continue;
119
115 /* Racy but it doesn't matter */ 120 /* Racy but it doesn't matter */
116 status = desc->status; 121 status = desc->status;
117 barrier(); 122 barrier();
@@ -278,7 +283,7 @@ static int __init irqfixup_setup(char *str)
278 283
279__setup("irqfixup", irqfixup_setup); 284__setup("irqfixup", irqfixup_setup);
280module_param(irqfixup, int, 0644); 285module_param(irqfixup, int, 0644);
281MODULE_PARM_DESC("irqfixup", "0: No fixup, 1: irqfixup mode 2: irqpoll mode"); 286MODULE_PARM_DESC("irqfixup", "0: No fixup, 1: irqfixup mode, 2: irqpoll mode");
282 287
283static int __init irqpoll_setup(char *str) 288static int __init irqpoll_setup(char *str)
284{ 289{