The Linux Kernel Mailing List
 help / color / mirror / Atom feed
From: Liviu Dudau <liviu.dudau@arm.com>
To: Luo Liu <Luo.Liu@cixtech.com>
Cc: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>,
	Maxime Ripard <mripard@kernel.org>,
	Thomas Zimmermann <tzimmermann@suse.de>,
	Russell King <linux@armlinux.org.uk>,
	dri-devel@lists.freedesktop.org,
	Ayan Halder <Ayan.Halder@arm.com>,
	Andrzej Hajda <andrzej.hajda@intel.com>,
	Neil Armstrong <neil.armstrong@linaro.org>,
	Robert Foss <rfoss@kernel.org>,
	Laurent Pinchart <laurent.pinchart@ideasonboard.com>,
	Jonas Karlman <jonas@kwiboo.se>,
	Jernej Skrabec <jernej.skrabec@gmail.com>,
	Kory Maincent <kory.maincent@bootlin.com>,
	Luca Ceresoli <luca.ceresoli@bootlin.com>,
	David Airlie <airlied@gmail.com>, Simona Vetter <simona@ffwll.ch>,
	linux-kernel@vger.kernel.org, cix-kernel-upstream@cixtech.com,
	Wuyi.Shen@cixtech.com
Subject: Re: [PATCH v4 1/4] drm/komeda: Use the bridge connector
Date: Mon, 30 Nov 2026 13:23:04 +0000	[thread overview]
Message-ID: <aw14uGb2u1oPJKTQ@e142607> (raw)
In-Reply-To: <20261130025520.766762-1-Luo.Liu@cixtech.com>

On Mon, Nov 30, 2026 at 10:55:17AM +0800, Luo Liu wrote:
> Bridges following the new DRM bridge model no longer create a connector
> themselves: the display driver has to attach them with
> DRM_BRIDGE_ATTACH_NO_CONNECTOR and create one connector for the whole
> chain with drm_bridge_connector_init().
> 
> Convert komeda to that model, so it keeps working with bridges that
> have moved to the new one. The bridges komeda binds to in mainline
> support connector-less attach, so boards using them are unaffected.
> 
> Select DRM_BRIDGE_CONNECTOR for drm_bridge_connector_init() and
> DRM_DISPLAY_HELPER, as the bridge connector is only visible when the
> display helper is enabled.
> 
> Signed-off-by: Luo Liu <Luo.Liu@cixtech.com>

Reviewed-by: Liviu Dudau <liviu.dudau@arm.com>

Best regards,
Liviu

> ---
>  drivers/gpu/drm/arm/display/Kconfig            |  2 ++
>  .../gpu/drm/arm/display/komeda/komeda_crtc.c   | 18 +++++++++++++++---
>  2 files changed, 17 insertions(+), 3 deletions(-)
> 
> diff --git a/drivers/gpu/drm/arm/display/Kconfig b/drivers/gpu/drm/arm/display/Kconfig
> index 415c10a6374b..d88fdd3808be 100644
> --- a/drivers/gpu/drm/arm/display/Kconfig
> +++ b/drivers/gpu/drm/arm/display/Kconfig
> @@ -6,6 +6,8 @@ config DRM_KOMEDA
>  	select DRM_CLIENT_SELECTION
>  	select DRM_KMS_HELPER
>  	select DRM_GEM_DMA_HELPER
> +	select DRM_DISPLAY_HELPER
> +	select DRM_BRIDGE_CONNECTOR
>  	select VIDEOMODE_HELPERS
>  	help
>  	  Choose this option if you want to compile the ARM Komeda display
> diff --git a/drivers/gpu/drm/arm/display/komeda/komeda_crtc.c b/drivers/gpu/drm/arm/display/komeda/komeda_crtc.c
> index 0fd069fc3386..3d5f06e085fa 100644
> --- a/drivers/gpu/drm/arm/display/komeda/komeda_crtc.c
> +++ b/drivers/gpu/drm/arm/display/komeda/komeda_crtc.c
> @@ -15,6 +15,7 @@
>  #include <drm/drm_print.h>
>  #include <drm/drm_vblank.h>
>  #include <drm/drm_bridge.h>
> +#include <drm/drm_bridge_connector.h>
>  #include <drm/drm_panel.h>
>  
>  #include "komeda_dev.h"
> @@ -617,6 +618,7 @@ static int komeda_attach_bridge(struct device *dev,
>  				struct drm_encoder *encoder)
>  {
>  	struct drm_device *drm = encoder->dev;
> +	struct drm_connector *connector;
>  	struct drm_bridge *bridge;
>  	int err;
>  
> @@ -626,12 +628,22 @@ static int komeda_attach_bridge(struct device *dev,
>  		return dev_err_probe(dev, PTR_ERR(bridge), "remote bridge not found for pipe: %s\n",
>  				     of_node_full_name(pipe->of_node));
>  
> -	err = drm_bridge_attach(encoder, bridge, NULL, 0);
> -	if (err)
> +	err = drm_bridge_attach(encoder, bridge, NULL,
> +				DRM_BRIDGE_ATTACH_NO_CONNECTOR);
> +	if (err) {
>  		drm_err(drm, "bridge_attach() failed for pipe: %s\n",
>  			of_node_full_name(pipe->of_node));
> +		return err;
> +	}
>  
> -	return err;
> +	connector = drm_bridge_connector_init(drm, encoder);
> +	if (IS_ERR(connector)) {
> +		drm_err(drm, "bridge connector init failed for pipe: %s\n",
> +			of_node_full_name(pipe->of_node));
> +		return PTR_ERR(connector);
> +	}
> +
> +	return 0;
>  }
>  
>  static const struct drm_encoder_funcs komeda_encoder_funcs = {
> -- 
> 2.25.1
> 

-- 
====================
| I would like to |
| fix the world,  |
| but they're not |
| giving me the   |
 \ source code!  /
  ---------------
    ¯\_(ツ)_/¯

      parent reply	other threads:[~2026-11-30 13:23 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-11-30  2:55 [PATCH v4 1/4] drm/komeda: Use the bridge connector Luo Liu
2026-11-30  2:55 ` [PATCH v4 2/4] drm/komeda: Use drmm_mode_config_init() Luo Liu
2026-11-30 13:25   ` Liviu Dudau
2026-11-30  2:55 ` [PATCH v4 3/4] drm/komeda: Free the IRQ before clearing dev_private Luo Liu
2026-11-30 13:27   ` Liviu Dudau
2026-11-30  2:55 ` [PATCH v4 4/4] drm/bridge: tda998x: fix DRM_BRIDGE_ATTACH_NO_CONNECTOR support Luo Liu
2026-11-30  9:53 ` [PATCH v4 1/4] drm/komeda: Use the bridge connector Kory Maincent
2026-11-30 11:45   ` 回复: " Luo Liu
2026-11-30 13:23 ` Liviu Dudau [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=aw14uGb2u1oPJKTQ@e142607 \
    --to=liviu.dudau@arm.com \
    --cc=Ayan.Halder@arm.com \
    --cc=Luo.Liu@cixtech.com \
    --cc=Wuyi.Shen@cixtech.com \
    --cc=airlied@gmail.com \
    --cc=andrzej.hajda@intel.com \
    --cc=cix-kernel-upstream@cixtech.com \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=jernej.skrabec@gmail.com \
    --cc=jonas@kwiboo.se \
    --cc=kory.maincent@bootlin.com \
    --cc=laurent.pinchart@ideasonboard.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux@armlinux.org.uk \
    --cc=luca.ceresoli@bootlin.com \
    --cc=maarten.lankhorst@linux.intel.com \
    --cc=mripard@kernel.org \
    --cc=neil.armstrong@linaro.org \
    --cc=rfoss@kernel.org \
    --cc=simona@ffwll.ch \
    --cc=tzimmermann@suse.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox