Skip to content

Commit b018bb2

Browse files
Jiri Slaby (SUSE)maddy-kerneldev
authored andcommitted
powerpc: Use dev_fwnode()
irq_domain_create_simple() takes fwnode as the first argument. It can be extracted from the struct device using dev_fwnode() helper instead of using of_node with of_fwnode_handle(). So use the dev_fwnode() helper. Signed-off-by: Jiri Slaby (SUSE) <jirislaby@kernel.org> Acked-by: Christophe Leroy <christophe.leroy@csgroup.eu> Link: https://lore.kernel.org/all/4bc0e1ca-a523-424a-8759-59e353317fba@kernel.org/ Signed-off-by: Madhavan Srinivasan <maddy@linux.ibm.com> Link: https://patch.msgid.link/20250723062842.1831271-1-jirislaby@kernel.org
1 parent 02c1b08 commit b018bb2

2 files changed

Lines changed: 3 additions & 5 deletions

File tree

arch/powerpc/platforms/8xx/cpm1-ic.c

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -110,8 +110,7 @@ static int cpm_pic_probe(struct platform_device *pdev)
110110

111111
out_be32(&data->reg->cpic_cimr, 0);
112112

113-
data->host = irq_domain_create_linear(of_fwnode_handle(dev->of_node),
114-
64, &cpm_pic_host_ops, data);
113+
data->host = irq_domain_create_linear(dev_fwnode(dev), 64, &cpm_pic_host_ops, data);
115114
if (!data->host)
116115
return -ENODEV;
117116

arch/powerpc/sysdev/fsl_msi.c

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -412,9 +412,8 @@ static int fsl_of_msi_probe(struct platform_device *dev)
412412
}
413413
platform_set_drvdata(dev, msi);
414414

415-
msi->irqhost = irq_domain_create_linear(of_fwnode_handle(dev->dev.of_node),
416-
NR_MSI_IRQS_MAX, &fsl_msi_host_ops, msi);
417-
415+
msi->irqhost = irq_domain_create_linear(dev_fwnode(&dev->dev), NR_MSI_IRQS_MAX,
416+
&fsl_msi_host_ops, msi);
418417
if (msi->irqhost == NULL) {
419418
dev_err(&dev->dev, "No memory for MSI irqhost\n");
420419
err = -ENOMEM;

0 commit comments

Comments
 (0)