public inbox for linux-gpio@vger.kernel.org
 help / color / mirror / Atom feed
* "gpio-line-names" property - issue with commit 9427ecbed46cc
@ 2017-12-14 11:54 Christophe LEROY
  2017-12-14 13:37 ` Linus Walleij
  0 siblings, 1 reply; 6+ messages in thread
From: Christophe LEROY @ 2017-12-14 11:54 UTC (permalink / raw)
  To: Mika Westerberg; +Cc: Linus Walleij, linux-gpio

Hello Mika,

In your commit 9427ecbed46cc, you have modified the way the 
"gpio-line-names" DT property is handled.

It seems that after that commit, many drivers fail to retrieve that 
property. After investigation it seems to be because the driver does not 
assign a parent to the gpio_chip.

Why is it necessary now to set a parent to the GPIO chip whereas it was 
not necessary before ? In gpio_chip_add_data(), we have:


	if (chip->parent) {
		gdev->dev.parent = chip->parent;
		gdev->dev.of_node = chip->parent->of_node;
	}

#ifdef CONFIG_OF_GPIO
	/* If the gpiochip has an assigned OF node this takes precedence */
	if (chip->of_node)
		gdev->dev.of_node = chip->of_node;
#endif



Therefore, as far as a chip->of_node is defined, shouldn't it be 
possible to retrieve "gpio-line-names" property as before without parent ?

Is there an easy modification that can be done to your new function 
devprop_gpiochip_set_names() in order to have the GPIO drivers work as 
before ?

Regards
Christophe

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2017-12-15 13:13 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-12-14 11:54 "gpio-line-names" property - issue with commit 9427ecbed46cc Christophe LEROY
2017-12-14 13:37 ` Linus Walleij
2017-12-15 10:08   ` Mika Westerberg
2017-12-15 12:31     ` Linus Walleij
2017-12-15 12:39       ` Mika Westerberg
2017-12-15 13:13         ` Christophe LEROY

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox