Commit 9576e8d3 authored by Jiri Slaby (SUSE)'s avatar Jiri Slaby (SUSE) Committed by Linus Walleij
Browse files

pinctrl: 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: default avatarJiri Slaby (SUSE) <jirislaby@kernel.org>
Acked-by: default avatarChen-Yu Tsai <wens@sie.org>
Link: https://lore.kernel.org/20250611104348.192092-17-jirislaby@kernel.org


Signed-off-by: default avatarLinus Walleij <linus.walleij@linaro.org>
parent 5409d619
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -561,8 +561,8 @@ int mtk_eint_do_init(struct mtk_eint *eint, struct mtk_eint_pin *eint_pin)
			goto err_eint;
	}

	eint->domain = irq_domain_create_linear(of_fwnode_handle(eint->dev->of_node),
						eint->hw->ap_num, &irq_domain_simple_ops, NULL);
	eint->domain = irq_domain_create_linear(dev_fwnode(eint->dev), eint->hw->ap_num,
						&irq_domain_simple_ops, NULL);
	if (!eint->domain)
		goto err_eint;

+3 −3
Original line number Diff line number Diff line
@@ -1212,7 +1212,7 @@ static int atmel_pinctrl_probe(struct platform_device *pdev)
		dev_dbg(dev, "bank %i: irq=%d\n", i, ret);
	}

	atmel_pioctrl->irq_domain = irq_domain_create_linear(of_fwnode_handle(dev->of_node),
	atmel_pioctrl->irq_domain = irq_domain_create_linear(dev_fwnode(dev),
							     atmel_pioctrl->gpio_chip->ngpio,
							     &irq_domain_simple_ops, NULL);
	if (!atmel_pioctrl->irq_domain)
+1 −1
Original line number Diff line number Diff line
@@ -1646,7 +1646,7 @@ int sunxi_pinctrl_init_with_flags(struct platform_device *pdev,
		}
	}

	pctl->domain = irq_domain_create_linear(of_fwnode_handle(node),
	pctl->domain = irq_domain_create_linear(dev_fwnode(&pdev->dev),
						pctl->desc->irq_banks * IRQ_PER_BANK,
						&sunxi_pinctrl_irq_domain_ops, pctl);
	if (!pctl->domain) {