Re: names for root swnodes in INT33FE driver and others

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Andy,

On 7/18/22 22:17, Andy Shevchenko wrote:
> HI!
> 
> During the discussion of some DSA rework [1] I just realized that
> names for root swnodes are not required and moreover should be unique
> in the system. Looking into the INT33FE driver I'm now asking myself
> why we are still using names there (except just convenience for us)?
> 
> Note, theoretically it might be possible that one can somehow connect
> another i2c device to those Cherry Trail machines (let's say via
> USB-to-I2C adapter). And somehow try to register swnode from maybe
> out-of-tree driver, however it's not an issue to the official kernel.
> 
> That said, maybe better just to remove them where we don't rely on their names?

For some nodes the name is important, e.g. drivers/usb/typec/class.c does:

	altmodes_node = device_get_named_child_node(&port->dev, "altmodes");

And AFAIK the connector node also must be called "connector"

I guess we could drop the names for the nodes which are directly attached
to "chips", rather then being specific child nodes of these chips, but
the names being present there does not seem harmful and this might be
useful for debugging.

Regards,

Hans


> 
> [1]: https://lore.kernel.org/all/YtWzWdkFVMg0Hyvf@xxxxxxxxxxxxxxxxxx/
> 




[Index of Archives]     [Linux Kernel Development]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux