Skip to content

Commit a1e5cd9

Browse files
author
Marc Zyngier
committed
ARM: Bulk conversion to generic_handle_domain_irq()
Wherever possible, replace constructs that match either generic_handle_irq(irq_find_mapping()) or generic_handle_irq(irq_linear_revmap()) to a single call to generic_handle_domain_irq(). Acked-by: Krzysztof Kozlowski <[email protected]> Signed-off-by: Marc Zyngier <[email protected]>
1 parent 3b0ccce commit a1e5cd9

File tree

3 files changed

+6
-17
lines changed

3 files changed

+6
-17
lines changed

arch/arm/common/sa1111.c

Lines changed: 2 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -196,14 +196,6 @@ static int sa1111_map_irq(struct sa1111 *sachip, irq_hw_number_t hwirq)
196196
return irq_create_mapping(sachip->irqdomain, hwirq);
197197
}
198198

199-
static void sa1111_handle_irqdomain(struct irq_domain *irqdomain, int irq)
200-
{
201-
struct irq_desc *d = irq_to_desc(irq_linear_revmap(irqdomain, irq));
202-
203-
if (d)
204-
generic_handle_irq_desc(d);
205-
}
206-
207199
/*
208200
* SA1111 interrupt support. Since clearing an IRQ while there are
209201
* active IRQs causes the interrupt output to pulse, the upper levels
@@ -234,11 +226,11 @@ static void sa1111_irq_handler(struct irq_desc *desc)
234226

235227
for (i = 0; stat0; i++, stat0 >>= 1)
236228
if (stat0 & 1)
237-
sa1111_handle_irqdomain(irqdomain, i);
229+
generic_handle_domain_irq(irqdomain, i);
238230

239231
for (i = 32; stat1; i++, stat1 >>= 1)
240232
if (stat1 & 1)
241-
sa1111_handle_irqdomain(irqdomain, i);
233+
generic_handle_domain_irq(irqdomain, i);
242234

243235
/* For level-based interrupts */
244236
desc->irq_data.chip->irq_unmask(&desc->irq_data);

arch/arm/mach-pxa/pxa_cplds_irqs.c

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -39,10 +39,8 @@ static irqreturn_t cplds_irq_handler(int in_irq, void *d)
3939

4040
do {
4141
pending = readl(fpga->base + FPGA_IRQ_SET_CLR) & fpga->irq_mask;
42-
for_each_set_bit(bit, &pending, CPLDS_NB_IRQ) {
43-
generic_handle_irq(irq_find_mapping(fpga->irqdomain,
44-
bit));
45-
}
42+
for_each_set_bit(bit, &pending, CPLDS_NB_IRQ)
43+
generic_handle_domain_irq(fpga->irqdomain, bit);
4644
} while (pending);
4745

4846
return IRQ_HANDLED;

arch/arm/mach-s3c/irq-s3c24xx.c

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -298,7 +298,7 @@ static void s3c_irq_demux(struct irq_desc *desc)
298298
struct s3c_irq_data *irq_data = irq_desc_get_chip_data(desc);
299299
struct s3c_irq_intc *intc = irq_data->intc;
300300
struct s3c_irq_intc *sub_intc = irq_data->sub_intc;
301-
unsigned int n, offset, irq;
301+
unsigned int n, offset;
302302
unsigned long src, msk;
303303

304304
/* we're using individual domains for the non-dt case
@@ -318,8 +318,7 @@ static void s3c_irq_demux(struct irq_desc *desc)
318318
while (src) {
319319
n = __ffs(src);
320320
src &= ~(1 << n);
321-
irq = irq_find_mapping(sub_intc->domain, offset + n);
322-
generic_handle_irq(irq);
321+
generic_handle_domain_irq(sub_intc->domain, offset + n);
323322
}
324323

325324
chained_irq_exit(chip, desc);

0 commit comments

Comments
 (0)