Skip to content

Commit

Permalink
ARM/LPC32xx: Use irq not hwirq for __irq_set_handler_locked()
Browse files Browse the repository at this point in the history
irq_data->hwirq is not guaranteed to be the same as irq_data->irq. It
might be in that particular case, but it's wrong nevertheless.

Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Cc: Roland Stigge <stigge@antcom.de>
  • Loading branch information
Thomas Gleixner committed Jun 26, 2015
1 parent bbc9d21 commit 93b6eb7
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions arch/arm/mach-lpc32xx/irq.c
Original file line number Diff line number Diff line change
Expand Up @@ -283,25 +283,25 @@ static int lpc32xx_set_irq_type(struct irq_data *d, unsigned int type)
case IRQ_TYPE_EDGE_RISING:
/* Rising edge sensitive */
__lpc32xx_set_irq_type(d->hwirq, 1, 1);
__irq_set_handler_locked(d->hwirq, handle_edge_irq);
__irq_set_handler_locked(d->irq, handle_edge_irq);
break;

case IRQ_TYPE_EDGE_FALLING:
/* Falling edge sensitive */
__lpc32xx_set_irq_type(d->hwirq, 0, 1);
__irq_set_handler_locked(d->hwirq, handle_edge_irq);
__irq_set_handler_locked(d->irq, handle_edge_irq);
break;

case IRQ_TYPE_LEVEL_LOW:
/* Low level sensitive */
__lpc32xx_set_irq_type(d->hwirq, 0, 0);
__irq_set_handler_locked(d->hwirq, handle_level_irq);
__irq_set_handler_locked(d->irq, handle_level_irq);
break;

case IRQ_TYPE_LEVEL_HIGH:
/* High level sensitive */
__lpc32xx_set_irq_type(d->hwirq, 1, 0);
__irq_set_handler_locked(d->hwirq, handle_level_irq);
__irq_set_handler_locked(d->irq, handle_level_irq);
break;

/* Other modes are not supported */
Expand Down

0 comments on commit 93b6eb7

Please sign in to comment.