mirror of
git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2025-09-04 20:19:47 +08:00
sh: intc: switch irq_desc iteration to new active IRQ iterator.
There's no need to iterative over every single irq_desc when we can already work out which IRQs have a backing descriptor via the shiny new for_each_active_irq(). Switch to that instead. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
This commit is contained in:
parent
fb41a49d96
commit
63111a3a70
@ -403,11 +403,8 @@ static int intc_suspend(struct sys_device *dev, pm_message_t state)
|
|||||||
if (d->state.event != PM_EVENT_FREEZE)
|
if (d->state.event != PM_EVENT_FREEZE)
|
||||||
break;
|
break;
|
||||||
|
|
||||||
for_each_irq_nr(irq) {
|
for_each_active_irq(irq) {
|
||||||
desc = irq_to_desc(irq);
|
desc = irq_to_desc(irq);
|
||||||
if (!desc)
|
|
||||||
continue;
|
|
||||||
|
|
||||||
data = irq_get_irq_data(irq);
|
data = irq_get_irq_data(irq);
|
||||||
chip = irq_data_get_irq_chip(data);
|
chip = irq_data_get_irq_chip(data);
|
||||||
|
|
||||||
@ -428,11 +425,8 @@ static int intc_suspend(struct sys_device *dev, pm_message_t state)
|
|||||||
break;
|
break;
|
||||||
case PM_EVENT_SUSPEND:
|
case PM_EVENT_SUSPEND:
|
||||||
/* enable wakeup irqs belonging to this intc controller */
|
/* enable wakeup irqs belonging to this intc controller */
|
||||||
for_each_irq_nr(irq) {
|
for_each_active_irq(irq) {
|
||||||
desc = irq_to_desc(irq);
|
desc = irq_to_desc(irq);
|
||||||
if (!desc)
|
|
||||||
continue;
|
|
||||||
|
|
||||||
data = irq_get_irq_data(irq);
|
data = irq_get_irq_data(irq);
|
||||||
chip = irq_data_get_irq_chip(data);
|
chip = irq_data_get_irq_chip(data);
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user