Re: [PATCH] driver core: Don't try to create links if they are not needed

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

 




On 23/10/2024 14:58, Nícolas F. R. A. Prado wrote:

...

I'm guessing a similar change to what Saravana suggested for the
of_dp_aux_populate_bus() helper is needed here:

diff --git a/drivers/phy/tegra/xusb.c b/drivers/phy/tegra/xusb.c
index cfdb54b6070a..0a2096085971 100644
--- a/drivers/phy/tegra/xusb.c
+++ b/drivers/phy/tegra/xusb.c
@@ -543,7 +543,7 @@ static int tegra_xusb_port_init(struct tegra_xusb_port *port,

         device_initialize(&port->dev);
         port->dev.type = &tegra_xusb_port_type;
-       port->dev.of_node = of_node_get(np);
+       device_set_node(&port->dev, of_fwnode_handle(of_node_get(np)));
         port->dev.parent = padctl->dev;

         err = dev_set_name(&port->dev, "%s-%u", name, index);


As a side note, I wonder if it would be possible to detect these mistakes... But
I'm guessing there are legitimate situations where there's no fwnode.


Yes! That does indeed fix the issue.

Saravana, let me know if you can send a patch? I would but I can't say I understand that actual issue.

Jon

--
nvpublic




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

  Powered by Linux