irqdomain: Introduce is_fwnode_irqchip helper

Since there will be several places checking if fwnode.type
is equal FWNODE_IRQCHIP, this patch adds a convenient function
for this purpose.

Acked-by: Marc Zyngier <[email protected]>
Signed-off-by: Suravee Suthikulpanit <[email protected]>
Signed-off-by: Marc Zyngier <[email protected]>
This commit is contained in:
Suravee Suthikulpanit 2015-12-10 08:55:28 -08:00 • committed by Marc Zyngier
commit 75aba7b0e9
3 changed files with 7 additions and 2 deletions

View file

@ -972,7 +972,7 @@ static int gic_irq_domain_translate(struct irq_domain *d,
return 0;
}
if (fwspec->fwnode->type == FWNODE_IRQCHIP) {
if (is_fwnode_irqchip(fwspec->fwnode)) {
if(fwspec->param_count != 2)
return -EINVAL;