Skip to contentSkip to conversation

gpu: ipu-v3: Stop overwriting pdev->dev.of_node of child devices

PATCH In review Philipp Zabel 2 participants 2 messages Feb 16, 2017

Subsystems (2)
lore
Share & tools
lore

Philipp Zabel

author maintainer
#0 lore raw

PATCH 1/1 gpu: ipu-v3: Stop overwriting pdev->dev.of_node of child devices

Setting dev->of_node changes the modalias and breaks module autoloading. Since there is an of_node field in the platform data passed to child devices, we don't even need this anymore.

---
 drivers/gpu/ipu-v3/ipu-common.c | 6 ------
 1 file changed, 6 deletions(-)
drivers/gpu/ipu-v3/ipu-common.c +0 -6
index 97218af4fe75c..8368e6f766ee5 100644
@@ -1238,12 +1238,6 @@ static int ipu_add_client_devices(struct ipu_soc *ipu, unsigned long ipu_base)
 			platform_device_put(pdev);
 			goto err_register;
 		}
-
-		/*
-		 * Set of_node only after calling platform_device_add. Otherwise
-		 * the platform:imx-ipuv3-crtc modalias won't be used.
-		 */
-		pdev->dev.of_node = of_node;
 	}
 
 	return 0;
Signature · 6 lines
2.11.0

_______________________________________________
dri-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel
Acked-by on v1 1/1
#1 lore raw
Quoted 18 lines · Philipp Zabel

Setting dev->of_node changes the modalias and breaks module autoloading. Since there is an of_node field in the platform data passed to child devices, we don't even need this anymore.

---
 drivers/gpu/ipu-v3/ipu-common.c | 6 ------
 1 file changed, 6 deletions(-)
drivers/gpu/ipu-v3/ipu-common.c +0 -0
index 97218af4fe75c..8368e6f766ee5 100644
@@ -1238,12 +1238,6 @@ static int ipu_add_client_devices(struct ipu_soc *ipu, unsigned long ipu_base)
 			platform_device_put(pdev);
 			goto err_register;

drivers/gpu/ipu-v3/ipu-common.c static int ipu_add_client_devices(struct ipu_soc *ipu, unsigned long ipu_base) · line 1243

Quoted 10 lines
drivers/gpu/ipu-v3/ipu-common.c +0 -6
 		}
-
-		/*
-		 * Set of_node only after calling platform_device_add. Otherwise
-		 * the platform:imx-ipuv3-crtc modalias won't be used.
-		 */
-		pdev->dev.of_node = of_node;
 	}
 
 	return 0;

_______________________________________________
dri-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel