[<prev] [next>] [day] [month] [year] [list]
Message-ID: <20251110124342.199216-1-robert.marko@sartura.hr>
Date: Mon, 10 Nov 2025 13:42:53 +0100
From: Robert Marko <robert.marko@...tura.hr>
To: andrew+netdev@...n.ch,
davem@...emloft.net,
edumazet@...gle.com,
kuba@...nel.org,
pabeni@...hat.com,
Steen.Hegelund@...rochip.com,
daniel.machon@...rochip.com,
UNGLinuxDriver@...rochip.com,
horatiu.vultur@...rochip.com,
rmk+kernel@...linux.org.uk,
netdev@...r.kernel.org,
linux-arm-kernel@...ts.infradead.org,
linux-kernel@...r.kernel.org
Cc: luka.perkov@...tura.hr,
Robert Marko <robert.marko@...tura.hr>
Subject: [PATCH net-next v2] net: sparx5/lan969x: populate netdev of_node
Populate of_node for the port netdevs, to make the individual ports
of_nodes available in sysfs.
Signed-off-by: Robert Marko <robert.marko@...tura.hr>
---
Changes in v2:
* Per Daniels suggestion, set it directly in sparx5_create_port()
instead of doing it in the dedicated netdev registration function.
drivers/net/ethernet/microchip/sparx5/sparx5_main.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/drivers/net/ethernet/microchip/sparx5/sparx5_main.c b/drivers/net/ethernet/microchip/sparx5/sparx5_main.c
index 40b1bfc600a7..582145713cfd 100644
--- a/drivers/net/ethernet/microchip/sparx5/sparx5_main.c
+++ b/drivers/net/ethernet/microchip/sparx5/sparx5_main.c
@@ -395,6 +395,8 @@ static int sparx5_create_port(struct sparx5 *sparx5,
spx5_port->phylink = phylink;
+ spx5_port->ndev->dev.of_node = spx5_port->of_node;
+
return 0;
}
--
2.51.1
Powered by blists - more mailing lists