mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2025-08-18 05:02:03 +00:00
irqchip/riscv-imsic: Convert to msi_create_parent_irq_domain() helper
Now that we have a concise helper to create an MSI parent domain, switch the RISC-V letter soup over to that. Signed-off-by: Marc Zyngier <maz@kernel.org> Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Signed-off-by: Nam Cao <tglx@linutronix.de> Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Link: https://lore.kernel.org/all/b906a38d443577de45923b335d80fc54c5638da0.1750860131.git.namcao@linutronix.de Link: https://lore.kernel.org/all/20241204124549.607054-6-maz@kernel.org
This commit is contained in:
parent
91650ca5ef
commit
59422904dd
@ -307,6 +307,11 @@ static const struct msi_parent_ops imsic_msi_parent_ops = {
|
||||
|
||||
int imsic_irqdomain_init(void)
|
||||
{
|
||||
struct irq_domain_info info = {
|
||||
.fwnode = imsic->fwnode,
|
||||
.ops = &imsic_base_domain_ops,
|
||||
.host_data = imsic,
|
||||
};
|
||||
struct imsic_global_config *global;
|
||||
|
||||
if (!imsic || !imsic->fwnode) {
|
||||
@ -320,16 +325,11 @@ int imsic_irqdomain_init(void)
|
||||
}
|
||||
|
||||
/* Create Base IRQ domain */
|
||||
imsic->base_domain = irq_domain_create_tree(imsic->fwnode,
|
||||
&imsic_base_domain_ops, imsic);
|
||||
imsic->base_domain = msi_create_parent_irq_domain(&info, &imsic_msi_parent_ops);
|
||||
if (!imsic->base_domain) {
|
||||
pr_err("%pfwP: failed to create IMSIC base domain\n", imsic->fwnode);
|
||||
return -ENOMEM;
|
||||
}
|
||||
imsic->base_domain->flags |= IRQ_DOMAIN_FLAG_MSI_PARENT;
|
||||
imsic->base_domain->msi_parent_ops = &imsic_msi_parent_ops;
|
||||
|
||||
irq_domain_update_bus_token(imsic->base_domain, DOMAIN_BUS_NEXUS);
|
||||
|
||||
global = &imsic->global;
|
||||
pr_info("%pfwP: hart-index-bits: %d, guest-index-bits: %d\n",
|
||||
|
Loading…
Reference in New Issue
Block a user