summaryrefslogtreecommitdiff
path: root/include/drm
diff options
context:
space:
mode:
authorLiu Ying <victor.liu@nxp.com>2017-08-29 16:58:58 +0800
committerLeonard Crestez <leonard.crestez@nxp.com>2018-08-24 12:41:33 +0300
commit8c81f6b875350472598a4161a18b508d95c8feb8 (patch)
treef7268f16b3952ba3ab27105b656513058031aa71 /include/drm
parent5d63708a4b6029283ed9aed45447e12c8207fe10 (diff)
MLK-16290 drm: Add drm_of_component_probe_with_match() helper
A component master may have both OF based and non-OF based components to be bound with. This patch adds a helper drm_of_component_probe_with_match() similar to drm_of_component_probe() so that the new helper may get an additional provided match pointer(contains match entries for non-OF based components) to support this case. Tested-by: Meng Mingming <mingming.meng@nxp.com> Signed-off-by: Liu Ying <victor.liu@nxp.com>
Diffstat (limited to 'include/drm')
-rw-r--r--include/drm/drm_of.h13
1 files changed, 13 insertions, 0 deletions
diff --git a/include/drm/drm_of.h b/include/drm/drm_of.h
index 3fd87b386ed7..de7e9e1a8d3d 100644
--- a/include/drm/drm_of.h
+++ b/include/drm/drm_of.h
@@ -3,6 +3,7 @@
#include <linux/of_graph.h>
+struct component_match;
struct component_master_ops;
struct device;
struct drm_device;
@@ -12,6 +13,10 @@ struct device_node;
#ifdef CONFIG_OF
extern uint32_t drm_of_find_possible_crtcs(struct drm_device *dev,
struct device_node *port);
+extern int drm_of_component_probe_with_match(struct device *dev,
+ struct component_match *match,
+ int (*compare_of)(struct device *, void *),
+ const struct component_master_ops *m_ops);
extern int drm_of_component_probe(struct device *dev,
int (*compare_of)(struct device *, void *),
const struct component_master_ops *m_ops);
@@ -25,6 +30,14 @@ static inline uint32_t drm_of_find_possible_crtcs(struct drm_device *dev,
return 0;
}
+static int drm_of_component_probe_with_match(struct device *dev,
+ struct component_match *match,
+ int (*compare_of)(struct device *, void *),
+ const struct component_master_ops *m_ops)
+{
+ return -EINVAL;
+}
+
static inline int
drm_of_component_probe(struct device *dev,
int (*compare_of)(struct device *, void *),