From: Andy Shevchenko Date: Thu, 2 Dec 2021 20:58:55 +0000 (+0200) Subject: can: mcp251x: mcp251x_gpio_setup(): Get rid of duplicate of_node assignment X-Git-Url: http://git.maquefel.me/?a=commitdiff_plain;h=68fa39ea9124c9794b31016650e4464ebc40ae1d;p=linux.git can: mcp251x: mcp251x_gpio_setup(): 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. Link: https://lore.kernel.org/all/20211202205855.76946-1-andriy.shevchenko@linux.intel.com Signed-off-by: Andy Shevchenko Signed-off-by: Marc Kleine-Budde --- diff --git a/drivers/net/can/spi/mcp251x.c b/drivers/net/can/spi/mcp251x.c index 0579ab74f728a..0cec808e87277 100644 --- a/drivers/net/can/spi/mcp251x.c +++ b/drivers/net/can/spi/mcp251x.c @@ -600,9 +600,6 @@ static int mcp251x_gpio_setup(struct mcp251x_priv *priv) gpio->ngpio = ARRAY_SIZE(mcp251x_gpio_names); gpio->names = mcp251x_gpio_names; gpio->can_sleep = true; -#ifdef CONFIG_OF_GPIO - gpio->of_node = priv->spi->dev.of_node; -#endif return devm_gpiochip_add_data(&priv->spi->dev, gpio, priv); }