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

leds: tca6507: Get rid of duplicate of_node assignment

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 assignment here.

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

Call graph:
--> tca6507_probe_gpios()
--> gpiochip_add_data()
--> gpiochip_add_data_with_key()
--> of_gpio_dev_init()

Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Signed-off-by: Pavel Machek <pavel@ucw.cz>

authored by

Andy Shevchenko and committed by
Pavel Machek
27d1a621 b7f1ac9b

-3
-3
drivers/leds/leds-tca6507.c
··· 641 641 tca->gpio.direction_output = tca6507_gpio_direction_output; 642 642 tca->gpio.set = tca6507_gpio_set_value; 643 643 tca->gpio.parent = dev; 644 - #ifdef CONFIG_OF_GPIO 645 - tca->gpio.of_node = of_node_get(dev_of_node(dev)); 646 - #endif 647 644 err = gpiochip_add_data(&tca->gpio, tca); 648 645 if (err) { 649 646 tca->gpio.ngpio = 0;