Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

net: 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>
Link: https://patch.msgid.link/20250611104348.192092-15-jirislaby@kernel.org
Signed-off-by: Jakub Kicinski <kuba@kernel.org>

authored by

Jiri Slaby (SUSE) and committed by
Jakub Kicinski
6d4e01d2 31b92821

+9 -14
+1 -2
drivers/net/dsa/microchip/ksz_common.c
··· 2786 2786 kirq->dev = dev; 2787 2787 kirq->masked = ~0; 2788 2788 2789 - kirq->domain = irq_domain_create_simple(of_fwnode_handle(dev->dev->of_node), 2790 - kirq->nirqs, 0, 2789 + kirq->domain = irq_domain_create_simple(dev_fwnode(dev->dev), kirq->nirqs, 0, 2791 2790 &ksz_irq_domain_ops, kirq); 2792 2791 if (!kirq->domain) 2793 2792 return -ENOMEM;
+2 -2
drivers/net/dsa/microchip/ksz_ptp.c
··· 1130 1130 1131 1131 init_completion(&port->tstamp_msg_comp); 1132 1132 1133 - ptpirq->domain = irq_domain_create_linear(of_fwnode_handle(dev->dev->of_node), 1134 - ptpirq->nirqs, &ksz_ptp_irq_domain_ops, ptpirq); 1133 + ptpirq->domain = irq_domain_create_linear(dev_fwnode(dev->dev), ptpirq->nirqs, 1134 + &ksz_ptp_irq_domain_ops, ptpirq); 1135 1135 if (!ptpirq->domain) 1136 1136 return -ENOMEM; 1137 1137
+2 -4
drivers/net/dsa/mv88e6xxx/global2.c
··· 1154 1154 if (err) 1155 1155 return err; 1156 1156 1157 - chip->g2_irq.domain = irq_domain_create_simple(of_fwnode_handle(chip->dev->of_node), 1158 - 16, 0, 1159 - &mv88e6xxx_g2_irq_domain_ops, 1160 - chip); 1157 + chip->g2_irq.domain = irq_domain_create_simple(dev_fwnode(chip->dev), 16, 0, 1158 + &mv88e6xxx_g2_irq_domain_ops, chip); 1161 1159 if (!chip->g2_irq.domain) 1162 1160 return -ENOMEM; 1163 1161
+2 -2
drivers/net/dsa/qca/ar9331.c
··· 821 821 return ret; 822 822 } 823 823 824 - priv->irqdomain = irq_domain_create_linear(of_fwnode_handle(np), 1, 825 - &ar9331_sw_irqdomain_ops, priv); 824 + priv->irqdomain = irq_domain_create_linear(dev_fwnode(dev), 1, &ar9331_sw_irqdomain_ops, 825 + priv); 826 826 if (!priv->irqdomain) { 827 827 dev_err(dev, "failed to create IRQ domain\n"); 828 828 return -EINVAL;
+2 -4
drivers/net/usb/lan78xx.c
··· 2448 2448 dev->domain_data.irqchip = &lan78xx_irqchip; 2449 2449 dev->domain_data.irq_handler = handle_simple_irq; 2450 2450 2451 - irqdomain = irq_domain_create_simple(of_fwnode_handle(dev->udev->dev.parent->of_node), 2452 - MAX_INT_EP, 0, 2453 - &chip_domain_ops, 2454 - &dev->domain_data); 2451 + irqdomain = irq_domain_create_simple(dev_fwnode(dev->udev->dev.parent), MAX_INT_EP, 0, 2452 + &chip_domain_ops, &dev->domain_data); 2455 2453 if (irqdomain) { 2456 2454 /* create mapping for PHY interrupt */ 2457 2455 irqmap = irq_create_mapping(irqdomain, INT_EP_PHY);