aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndrzej Hajda <a.hajda@samsung.com>2014-03-28 07:52:37 -0400
committerInki Dae <daeinki@gmail.com>2014-04-04 08:24:47 -0400
commite49640da76b5e143b809720bff8f35ad5f2d8cc6 (patch)
tree05d7201781b2de3dbff2ef8225e7d783f16f07c6
parent1d96d4a6772ba8f5614a6d8de8baf6d090a9de0b (diff)
drm/mipi_dsi: create dsi devices only for nodes with reg property
MIPI DSI host node can contain child nodes which are not DSI devices. Checking for existence of reg property can be used to distinguish such nodes. Signed-off-by: Andrzej Hajda <a.hajda@samsung.com> Signed-off-by: Inki Dae <inki.dae@samsung.com>
-rw-r--r--drivers/gpu/drm/drm_mipi_dsi.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/drivers/gpu/drm/drm_mipi_dsi.c b/drivers/gpu/drm/drm_mipi_dsi.c
index b155ee2ffa17..09821f46d768 100644
--- a/drivers/gpu/drm/drm_mipi_dsi.c
+++ b/drivers/gpu/drm/drm_mipi_dsi.c
@@ -142,8 +142,12 @@ int mipi_dsi_host_register(struct mipi_dsi_host *host)
142{ 142{
143 struct device_node *node; 143 struct device_node *node;
144 144
145 for_each_available_child_of_node(host->dev->of_node, node) 145 for_each_available_child_of_node(host->dev->of_node, node) {
146 /* skip nodes without reg property */
147 if (!of_find_property(node, "reg", NULL))
148 continue;
146 of_mipi_dsi_device_add(host, node); 149 of_mipi_dsi_device_add(host, node);
150 }
147 151
148 return 0; 152 return 0;
149} 153}