[PATCH 21/22] drm/tilcdc: Use of_device_match()

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

 




From: Thierry Reding <treding@xxxxxxxxxx>

Use the common implementation instead of the driver-private variant.

Signed-off-by: Thierry Reding <treding@xxxxxxxxxx>
---
 drivers/gpu/drm/tilcdc/tilcdc_external.c | 8 ++------
 1 file changed, 2 insertions(+), 6 deletions(-)

diff --git a/drivers/gpu/drm/tilcdc/tilcdc_external.c b/drivers/gpu/drm/tilcdc/tilcdc_external.c
index 7e11b5ecdd4a..78196a90d7ba 100644
--- a/drivers/gpu/drm/tilcdc/tilcdc_external.c
+++ b/drivers/gpu/drm/tilcdc/tilcdc_external.c
@@ -9,6 +9,7 @@
  */
 
 #include <linux/component.h>
+#include <linux/of_device.h>
 #include <linux/of_graph.h>
 
 #include "tilcdc_drv.h"
@@ -130,11 +131,6 @@ void tilcdc_remove_external_encoders(struct drm_device *dev)
 						 priv->connector_funcs[i]);
 }
 
-static int dev_match_of(struct device *dev, void *data)
-{
-	return dev->of_node == data;
-}
-
 static void dev_release_of(struct device *dev, void *data)
 {
 	of_node_put(data);
@@ -158,7 +154,7 @@ int tilcdc_get_external_components(struct device *dev,
 		dev_dbg(dev, "Subdevice node '%s' found\n", node->name);
 		if (match)
 			component_match_add_release(dev, match, dev_release_of,
-						    dev_match_of, node);
+						    of_device_match, node);
 		count++;
 	}
 
-- 
2.8.3

--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Device Tree Compilter]     [Device Tree Spec]     [Linux Driver Backports]     [Video for Linux]     [Linux USB Devel]     [Linux PCI Devel]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Yosemite Backpacking]
  Powered by Linux