Commit 8a8d6bbe authored by Andy Shevchenko's avatar Andy Shevchenko Committed by Linus Walleij
Browse files

pinctrl: Get rid of duplicate of_node assignment in the drivers



GPIO library does copy the of_node from the parent device of
the GPIO chip, there is no need to repeat this in the individual
drivers. Remove these assignment all at once.

For the details one may look into the of_gpio_dev_init() implementation.

Signed-off-by: default avatarAndy Shevchenko <andriy.shevchenko@linux.intel.com>
Link: https://lore.kernel.org/r/20211214125855.33207-1-andriy.shevchenko@linux.intel.com


Signed-off-by: default avatarLinus Walleij <linus.walleij@linaro.org>
parent 8df89a7c
Loading
Loading
Loading
Loading
+0 −1
Original line number Diff line number Diff line
@@ -874,7 +874,6 @@ static int owl_gpio_init(struct owl_pinctrl *pctrl)
	chip->label = dev_name(pctrl->dev);
	chip->parent = pctrl->dev;
	chip->owner = THIS_MODULE;
	chip->of_node = pctrl->dev->of_node;

	pctrl->irq_chip.name = chip->of_node->name;
	pctrl->irq_chip.irq_ack = owl_gpio_irq_ack;
+0 −1
Original line number Diff line number Diff line
@@ -1228,7 +1228,6 @@ static int bcm2835_pinctrl_probe(struct platform_device *pdev)

	pc->gpio_chip = *pdata->gpio_chip;
	pc->gpio_chip.parent = dev;
	pc->gpio_chip.of_node = np;

	for (i = 0; i < BCM2835_NUM_BANKS; i++) {
		unsigned long events;
+0 −1
Original line number Diff line number Diff line
@@ -836,7 +836,6 @@ static int iproc_gpio_probe(struct platform_device *pdev)
	chip->num_banks = (ngpios + NGPIOS_PER_BANK - 1) / NGPIOS_PER_BANK;
	gc->label = dev_name(dev);
	gc->parent = dev;
	gc->of_node = dev->of_node;
	gc->request = iproc_gpio_request;
	gc->free = iproc_gpio_free;
	gc->direction_input = iproc_gpio_direction_input;
+0 −1
Original line number Diff line number Diff line
@@ -648,7 +648,6 @@ static int nsp_gpio_probe(struct platform_device *pdev)
	gc->ngpio = val;
	gc->label = dev_name(dev);
	gc->parent = dev;
	gc->of_node = dev->of_node;
	gc->request = gpiochip_generic_request;
	gc->free = gpiochip_generic_free;
	gc->direction_input = nsp_gpio_direction_input;
+0 −3
Original line number Diff line number Diff line
@@ -1161,9 +1161,6 @@ static int lochnagar_pin_probe(struct platform_device *pdev)
	priv->gpio_chip.can_sleep = true;
	priv->gpio_chip.parent = dev;
	priv->gpio_chip.base = -1;
#ifdef CONFIG_OF_GPIO
	priv->gpio_chip.of_node = dev->of_node;
#endif

	switch (lochnagar->type) {
	case LOCHNAGAR1:
Loading