Skip to content

Commit 6c88923

Browse files
jhovoldMarc Zyngier
authored andcommitted
irqchip/alpine-msi: Use irq_domain_add_hierarchy()
Use the irq_domain_add_hierarchy() helper to create the hierarchical domain, which both serves as documentation and avoids poking at irqdomain internals. Reviewed-by: Philippe Mathieu-Daudé <[email protected]> Tested-by: Hsin-Yi Wang <[email protected]> Tested-by: Mark-PK Tsai <[email protected]> Signed-off-by: Johan Hovold <[email protected]> Signed-off-by: Marc Zyngier <[email protected]> Link: https://lore.kernel.org/r/[email protected]
1 parent a14e7fd commit 6c88923

File tree

1 file changed

+3
-5
lines changed

1 file changed

+3
-5
lines changed

drivers/irqchip/irq-alpine-msi.c

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -204,16 +204,14 @@ static int alpine_msix_init_domains(struct alpine_msix_data *priv,
204204
return -ENXIO;
205205
}
206206

207-
middle_domain = irq_domain_add_tree(NULL,
208-
&alpine_msix_middle_domain_ops,
209-
priv);
207+
middle_domain = irq_domain_add_hierarchy(gic_domain, 0, 0, NULL,
208+
&alpine_msix_middle_domain_ops,
209+
priv);
210210
if (!middle_domain) {
211211
pr_err("Failed to create the MSIX middle domain\n");
212212
return -ENOMEM;
213213
}
214214

215-
middle_domain->parent = gic_domain;
216-
217215
msi_domain = pci_msi_create_irq_domain(of_node_to_fwnode(node),
218216
&alpine_msix_domain_info,
219217
middle_domain);

0 commit comments

Comments
 (0)