From: Andy Shevchenko Date: Thu, 22 Aug 2024 22:56:29 +0000 (+0300) Subject: gpio: uniphier: Replace of_node_to_fwnode() with more suitable API X-Git-Tag: v6.12-rc1~156^2~25 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=9f12737342291ea5b657a79c35d24b33983668be;p=thirdparty%2Fkernel%2Flinux.git gpio: uniphier: Replace of_node_to_fwnode() with more suitable API of_node_to_fwnode() is a IRQ domain specific implementation of of_fwnode_handle(). Replace the former with more suitable API. Signed-off-by: Andy Shevchenko Link: https://lore.kernel.org/r/20240822225629.707365-1-andy.shevchenko@gmail.com Signed-off-by: Bartosz Golaszewski --- diff --git a/drivers/gpio/gpio-uniphier.c b/drivers/gpio/gpio-uniphier.c index 1f440707f8f4a..da99ba13e82d0 100644 --- a/drivers/gpio/gpio-uniphier.c +++ b/drivers/gpio/gpio-uniphier.c @@ -11,6 +11,7 @@ #include #include #include +#include #include #include @@ -164,7 +165,7 @@ static int uniphier_gpio_to_irq(struct gpio_chip *chip, unsigned int offset) if (offset < UNIPHIER_GPIO_IRQ_OFFSET) return -ENXIO; - fwspec.fwnode = of_node_to_fwnode(chip->parent->of_node); + fwspec.fwnode = dev_fwnode(chip->parent); fwspec.param_count = 2; fwspec.param[0] = offset - UNIPHIER_GPIO_IRQ_OFFSET; /* @@ -404,7 +405,7 @@ static int uniphier_gpio_probe(struct platform_device *pdev) priv->domain = irq_domain_create_hierarchy( parent_domain, 0, UNIPHIER_GPIO_IRQ_MAX_NUM, - of_node_to_fwnode(dev->of_node), + dev_fwnode(dev), &uniphier_gpio_irq_domain_ops, priv); if (!priv->domain) return -ENOMEM;