Thread (30 messages) 30 messages, 7 authors, 1d ago

Re: [PATCH v2 10/19] pmdomain: imx: use platform_device_set_of_node()

From: Frank Li <hidden>
Date: 2026-06-30 15:27:52
Also in: dri-devel, driver-core, imx, intel-xe, linux-arm-msm, linux-devicetree, linux-i2c, linux-iommu, linux-mips, linux-pm, linux-sound, linux-usb, lkml, netdev, platform-driver-x86

On Mon, Jun 29, 2026 at 11:12:33AM +0200, Bartosz Golaszewski wrote:
Ahead of reworking the reference counting logic for platform devices,
encapsulate the assignment of the OF node for dynamically allocated
platform devices with the provided helper.

Signed-off-by: Bartosz Golaszewski <redacted>
---
Reviewed-by: Frank Li <Frank.Li@nxp.com>
quoted hunk ↗ jump to hunk
 drivers/pmdomain/imx/gpc.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/drivers/pmdomain/imx/gpc.c b/drivers/pmdomain/imx/gpc.c
index 42e50c9b4fb9ffb96a20a462d4eb5168942a893c..abca5f449a226fbae4213926e1395c413160c950 100644
--- a/drivers/pmdomain/imx/gpc.c
+++ b/drivers/pmdomain/imx/gpc.c
@@ -487,8 +487,7 @@ static int imx_gpc_probe(struct platform_device *pdev)
                        domain->ipg_rate_mhz = ipg_rate_mhz;

                        pd_pdev->dev.parent = &pdev->dev;
-                       pd_pdev->dev.of_node = of_node_get(np);
-                       pd_pdev->dev.fwnode = of_fwnode_handle(np);
+                       platform_device_set_of_node(pd_pdev, np);

                        ret = platform_device_add(pd_pdev);
                        if (ret) {

--
2.47.3
  
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help