Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 49baeb07 authored by Maxime Ripard's avatar Maxime Ripard
Browse files

drm/sun4i: Ignore the generic connectors for components



The generic connectors such as hdmi-connector doesn't have any driver in,
so if they are added to the component list, we will be waiting forever for
a non-existing driver to probe.

Add a list of the connectors we want to ignore when building our component
list.

Reviewed-by: default avatarChen-Yu Tsai <wens@csie.org>
Signed-off-by: default avatarMaxime Ripard <maxime.ripard@free-electrons.com>
parent b8317a3d
Loading
Loading
Loading
Loading
+12 −0
Original line number Diff line number Diff line
@@ -166,6 +166,11 @@ static const struct component_master_ops sun4i_drv_master_ops = {
	.unbind	= sun4i_drv_unbind,
};

static bool sun4i_drv_node_is_connector(struct device_node *node)
{
	return of_device_is_compatible(node, "hdmi-connector");
}

static bool sun4i_drv_node_is_frontend(struct device_node *node)
{
	return of_device_is_compatible(node, "allwinner,sun5i-a13-display-frontend") ||
@@ -207,6 +212,13 @@ static int sun4i_drv_add_endpoints(struct device *dev,
	    !of_device_is_available(node))
		return 0;

	/*
	 * The connectors will be the last nodes in our pipeline, we
	 * can just bail out.
	 */
	if (sun4i_drv_node_is_connector(node))
		return 0;

	if (!sun4i_drv_node_is_frontend(node)) {
		/* Add current component */
		DRM_DEBUG_DRIVER("Adding component %s\n",