generic: sparse irqs: use irq_desc() together with dyn_array, instead of irq_desc[]
add CONFIG_HAVE_SPARSE_IRQ to for use condensed array. Get rid of irq_desc[] array assumptions. Preallocate 32 irq_desc, and irq_desc() will try to get more. ( No change in functionality is expected anywhere, except the odd build failure where we missed a code site or where a crossing commit itroduces new irq_desc[] usage. ) v2: according to Eric, change get_irq_desc() to irq_desc() Signed-off-by: Yinghai Lu <yhlu.kernel@gmail.com> Signed-off-by: Ingo Molnar <mingo@elte.hu>
这个提交包含在:
@@ -92,11 +92,12 @@ static int misrouted_irq(int irq)
|
||||
int ok = 0;
|
||||
|
||||
for (i = 1; i < nr_irqs; i++) {
|
||||
struct irq_desc *desc = irq_desc + i;
|
||||
struct irq_desc *desc;
|
||||
|
||||
if (i == irq) /* Already tried */
|
||||
continue;
|
||||
|
||||
desc = irq_to_desc(i);
|
||||
if (try_one_irq(i, desc))
|
||||
ok = 1;
|
||||
}
|
||||
@@ -108,7 +109,7 @@ static void poll_spurious_irqs(unsigned long dummy)
|
||||
{
|
||||
int i;
|
||||
for (i = 1; i < nr_irqs; i++) {
|
||||
struct irq_desc *desc = irq_desc + i;
|
||||
struct irq_desc *desc = irq_to_desc(i);
|
||||
unsigned int status;
|
||||
|
||||
/* Racy but it doesn't matter */
|
||||
|
在新工单中引用
屏蔽一个用户