Skip to content

Commit

Permalink
um: Use proper accessors in show_interrupts()
Browse files Browse the repository at this point in the history
Signed-off-by: Thomas Gleixner <[email protected]>
Cc: Jeff Dike <[email protected]>
Cc: Andrew Morton <[email protected]>
LKML-Reference: <[email protected]>
  • Loading branch information
KAGA-KOKO committed Feb 14, 2011
1 parent 1d119aa commit d5b4eea
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions arch/um/kernel/irq.c
Original file line number Diff line number Diff line change
Expand Up @@ -35,8 +35,10 @@ int show_interrupts(struct seq_file *p, void *v)
}

if (i < NR_IRQS) {
raw_spin_lock_irqsave(&irq_desc[i].lock, flags);
action = irq_desc[i].action;
struct irq_desc *desc = irq_to_desc(i);

raw_spin_lock_irqsave(&desc->lock, flags);
action = desc->action;
if (!action)
goto skip;
seq_printf(p, "%3d: ",i);
Expand All @@ -46,15 +48,15 @@ int show_interrupts(struct seq_file *p, void *v)
for_each_online_cpu(j)
seq_printf(p, "%10u ", kstat_irqs_cpu(i, j));
#endif
seq_printf(p, " %14s", irq_desc[i].chip->name);
seq_printf(p, " %14s", get_irq_desc_chip(desc)->name);
seq_printf(p, " %s", action->name);

for (action=action->next; action; action = action->next)
seq_printf(p, ", %s", action->name);

seq_putc(p, '\n');
skip:
raw_spin_unlock_irqrestore(&irq_desc[i].lock, flags);
raw_spin_unlock_irqrestore(&desc->lock, flags);
} else if (i == NR_IRQS)
seq_putc(p, '\n');

Expand Down

0 comments on commit d5b4eea

Please sign in to comment.