All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Luca Ceresoli" <luca.ceresoli@bootlin.com>
To: "Damon Ding" <damon.ding@rock-chips.com>,
	<andrzej.hajda@intel.com>, <neil.armstrong@linaro.org>,
	<rfoss@kernel.org>
Cc: <Laurent.pinchart@ideasonboard.com>, <jonas@kwiboo.se>,
	<jernej.skrabec@gmail.com>, <maarten.lankhorst@linux.intel.com>,
	<mripard@kernel.org>, <tzimmermann@suse.de>, <airlied@gmail.com>,
	<simona@ffwll.ch>, <shawnguo@kernel.org>,
	<s.hauer@pengutronix.de>, <kernel@pengutronix.de>,
	<festevam@gmail.com>, <inki.dae@samsung.com>,
	<sw0312.kim@samsung.com>, <kyungmin.park@samsung.com>,
	<krzk@kernel.org>, <alim.akhtar@samsung.com>,
	<jingoohan1@gmail.com>, <p.zabel@pengutronix.de>,
	<hjc@rock-chips.com>, <heiko@sntech.de>,
	<andy.yan@rock-chips.com>, <dmitry.baryshkov@oss.qualcomm.com>,
	<dianders@chromium.org>, <m.szyprowski@samsung.com>,
	<jani.nikula@intel.com>, <linux-kernel@vger.kernel.org>,
	<dri-devel@lists.freedesktop.org>, <imx@lists.linux.dev>,
	<linux-arm-kernel@lists.infradead.org>,
	<linux-samsung-soc@vger.kernel.org>,
	<linux-rockchip@lists.infradead.org>
Subject: Re: [PATCH v8 04/18] drm/bridge: analogix_dp: Add &analogix_dp_plat_data.next_bridge
Date: Sat, 31 Jan 2026 14:41:21 +0100	[thread overview]
Message-ID: <DG2TG4NCMKXQ.36REPVMTQ7WWD@bootlin.com> (raw)
In-Reply-To: <f644a5ab-5dd1-4f4e-b2e9-3585dec81a96@rock-chips.com>

On Wed Jan 7, 2026 at 3:36 AM CET, Damon Ding wrote:
> Hi Luca,
>
> On 1/4/2026 10:51 AM, Damon Ding wrote:
>> Hi Luca,
>>
>> On 12/31/2025 7:11 PM, Luca Ceresoli wrote:
>>> Hello Damon,
>>>
>>> On Wed Dec 17, 2025 at 10:33 AM CET, Damon Ding wrote:
>>>> In order to move the panel/bridge parsing and attachmenet to the
>>>> Analogix side, add component struct drm_bridge *next_bridge to
>>>> platform data struct analogix_dp_plat_data.
>>>>
>>>> The movement makes sense because the panel/bridge should logically
>>>> be positioned behind the Analogix bridge in the display pipeline.
>>>>
>>>> Signed-off-by: Damon Ding <damon.ding@rock-chips.com>
>>>> Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>
>>>> Tested-by: Marek Szyprowski <m.szyprowski@samsung.com>
>>>>
>>>> ---
>>>>
>>>> Changes in v4:
>>>> - Rename the &analogix_dp_plat_data.bridge to
>>>>    &analogix_dp_plat_data.next_bridge
>>>> ---
>>>>   include/drm/bridge/analogix_dp.h | 1 +
>>>>   1 file changed, 1 insertion(+)
>>>>
>>>> diff --git a/include/drm/bridge/analogix_dp.h b/include/drm/bridge/
>>>> analogix_dp.h
>>>> index cf17646c1310..582357c20640 100644
>>>> --- a/include/drm/bridge/analogix_dp.h
>>>> +++ b/include/drm/bridge/analogix_dp.h
>>>> @@ -27,6 +27,7 @@ static inline bool is_rockchip(enum
>>>> analogix_dp_devtype type)
>>>>   struct analogix_dp_plat_data {
>>>>       enum analogix_dp_devtype dev_type;
>>>>       struct drm_panel *panel;
>>>> +    struct drm_bridge *next_bridge;
>>>>       struct drm_encoder *encoder;
>>>>       struct drm_connector *connector;
>>>>       bool skip_connector;
>>>
>>> It took a while to understand why you are adding the next_bridge
>>> pointer in
>>> struct analogix_dp_plat_data instead of struct analogix_dp_device,
>>> where it
>>> would be more natural. I found an answer in patch 16: with current
>>> code you
>>> need to place next_bridge in struct analogix_dp_plat_data because it is
>>> used by user drivers to attach, and those drivers have no access to
>>> struct
>>> analogix_dp_device. However patch 16 (which looks a very good cleanup
>>> BTW)
>>> next_bridge can be moved to struct analogix_dp_device.
>>>
>>> So I'd suggest to move patch 16 before this one if it easily doable, so
>>> that you can introduce next_bridge in struct analogix_dp_device from the
>>> beginning. Should that be impossible, you can send a separate patch to
>>> move
>>> next_bridge, after patch 16.
>>>
>>>
>>
>> Thanks for your nice suggestion! After patch 16, bridge attachment is
>> unified to the Analogix side, which acts as a common bridge driver for
>> both the Rockchip and Exynos sides, so moving next_bridge there makes
>> perfect sense. I will add a separate patch to move next_bridge in v9.
>>
>>
>
> My apologies for reversing the plan to move next_bridge to the Analogix
> side in v9 -- I only considered the Rockchip side before.
>
> When I tried modifying the code based on your suggestion, I found it
> better to keep &analogix_plat_data.next_bridge as is. This is because
> the Exynos side needs to maintain compatibility with the legacy method
> of parsing panels and bridges, so the next bridge isn't always parsed by
> the common Analogix side driver.
>
> This patch series has been pending for ages, and I'm even a bit fuzzy on
> the details myself. ;-)

OK, makes sense.

Reviewed-by: Luca Ceresoli <luca.ceresoli@bootlin.com>

--
Luca Ceresoli, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com

WARNING: multiple messages have this Message-ID (diff)
From: "Luca Ceresoli" <luca.ceresoli@bootlin.com>
To: "Damon Ding" <damon.ding@rock-chips.com>,
	<andrzej.hajda@intel.com>, <neil.armstrong@linaro.org>,
	<rfoss@kernel.org>
Cc: <Laurent.pinchart@ideasonboard.com>, <jonas@kwiboo.se>,
	<jernej.skrabec@gmail.com>, <maarten.lankhorst@linux.intel.com>,
	<mripard@kernel.org>, <tzimmermann@suse.de>, <airlied@gmail.com>,
	<simona@ffwll.ch>, <shawnguo@kernel.org>,
	<s.hauer@pengutronix.de>, <kernel@pengutronix.de>,
	<festevam@gmail.com>, <inki.dae@samsung.com>,
	<sw0312.kim@samsung.com>, <kyungmin.park@samsung.com>,
	<krzk@kernel.org>, <alim.akhtar@samsung.com>,
	<jingoohan1@gmail.com>, <p.zabel@pengutronix.de>,
	<hjc@rock-chips.com>, <heiko@sntech.de>,
	<andy.yan@rock-chips.com>, <dmitry.baryshkov@oss.qualcomm.com>,
	<dianders@chromium.org>, <m.szyprowski@samsung.com>,
	<jani.nikula@intel.com>, <linux-kernel@vger.kernel.org>,
	<dri-devel@lists.freedesktop.org>, <imx@lists.linux.dev>,
	<linux-arm-kernel@lists.infradead.org>,
	<linux-samsung-soc@vger.kernel.org>,
	<linux-rockchip@lists.infradead.org>
Subject: Re: [PATCH v8 04/18] drm/bridge: analogix_dp: Add &analogix_dp_plat_data.next_bridge
Date: Sat, 31 Jan 2026 14:41:21 +0100	[thread overview]
Message-ID: <DG2TG4NCMKXQ.36REPVMTQ7WWD@bootlin.com> (raw)
In-Reply-To: <f644a5ab-5dd1-4f4e-b2e9-3585dec81a96@rock-chips.com>

On Wed Jan 7, 2026 at 3:36 AM CET, Damon Ding wrote:
> Hi Luca,
>
> On 1/4/2026 10:51 AM, Damon Ding wrote:
>> Hi Luca,
>>
>> On 12/31/2025 7:11 PM, Luca Ceresoli wrote:
>>> Hello Damon,
>>>
>>> On Wed Dec 17, 2025 at 10:33 AM CET, Damon Ding wrote:
>>>> In order to move the panel/bridge parsing and attachmenet to the
>>>> Analogix side, add component struct drm_bridge *next_bridge to
>>>> platform data struct analogix_dp_plat_data.
>>>>
>>>> The movement makes sense because the panel/bridge should logically
>>>> be positioned behind the Analogix bridge in the display pipeline.
>>>>
>>>> Signed-off-by: Damon Ding <damon.ding@rock-chips.com>
>>>> Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>
>>>> Tested-by: Marek Szyprowski <m.szyprowski@samsung.com>
>>>>
>>>> ---
>>>>
>>>> Changes in v4:
>>>> - Rename the &analogix_dp_plat_data.bridge to
>>>>    &analogix_dp_plat_data.next_bridge
>>>> ---
>>>>   include/drm/bridge/analogix_dp.h | 1 +
>>>>   1 file changed, 1 insertion(+)
>>>>
>>>> diff --git a/include/drm/bridge/analogix_dp.h b/include/drm/bridge/
>>>> analogix_dp.h
>>>> index cf17646c1310..582357c20640 100644
>>>> --- a/include/drm/bridge/analogix_dp.h
>>>> +++ b/include/drm/bridge/analogix_dp.h
>>>> @@ -27,6 +27,7 @@ static inline bool is_rockchip(enum
>>>> analogix_dp_devtype type)
>>>>   struct analogix_dp_plat_data {
>>>>       enum analogix_dp_devtype dev_type;
>>>>       struct drm_panel *panel;
>>>> +    struct drm_bridge *next_bridge;
>>>>       struct drm_encoder *encoder;
>>>>       struct drm_connector *connector;
>>>>       bool skip_connector;
>>>
>>> It took a while to understand why you are adding the next_bridge
>>> pointer in
>>> struct analogix_dp_plat_data instead of struct analogix_dp_device,
>>> where it
>>> would be more natural. I found an answer in patch 16: with current
>>> code you
>>> need to place next_bridge in struct analogix_dp_plat_data because it is
>>> used by user drivers to attach, and those drivers have no access to
>>> struct
>>> analogix_dp_device. However patch 16 (which looks a very good cleanup
>>> BTW)
>>> next_bridge can be moved to struct analogix_dp_device.
>>>
>>> So I'd suggest to move patch 16 before this one if it easily doable, so
>>> that you can introduce next_bridge in struct analogix_dp_device from the
>>> beginning. Should that be impossible, you can send a separate patch to
>>> move
>>> next_bridge, after patch 16.
>>>
>>>
>>
>> Thanks for your nice suggestion! After patch 16, bridge attachment is
>> unified to the Analogix side, which acts as a common bridge driver for
>> both the Rockchip and Exynos sides, so moving next_bridge there makes
>> perfect sense. I will add a separate patch to move next_bridge in v9.
>>
>>
>
> My apologies for reversing the plan to move next_bridge to the Analogix
> side in v9 -- I only considered the Rockchip side before.
>
> When I tried modifying the code based on your suggestion, I found it
> better to keep &analogix_plat_data.next_bridge as is. This is because
> the Exynos side needs to maintain compatibility with the legacy method
> of parsing panels and bridges, so the next bridge isn't always parsed by
> the common Analogix side driver.
>
> This patch series has been pending for ages, and I'm even a bit fuzzy on
> the details myself. ;-)

OK, makes sense.

Reviewed-by: Luca Ceresoli <luca.ceresoli@bootlin.com>

--
Luca Ceresoli, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com

_______________________________________________
Linux-rockchip mailing list
Linux-rockchip@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-rockchip

  reply	other threads:[~2026-01-31 13:41 UTC|newest]

Thread overview: 82+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-12-17  9:33 [PATCH v8 00/18] Apply drm_bridge_connector and panel_bridge helper for the Analogix DP driver Damon Ding
2025-12-17  9:33 ` Damon Ding
2025-12-17  9:33 ` [PATCH v8 01/18] drm/display: bridge_connector: Ensure last bridge determines EDID/modes detection capabilities Damon Ding
2025-12-17  9:33   ` Damon Ding
2025-12-31 10:50   ` Luca Ceresoli
2025-12-31 10:50     ` Luca Ceresoli
2025-12-17  9:33 ` [PATCH v8 02/18] drm/bridge: analogix_dp: Formalize the struct analogix_dp_device Damon Ding
2025-12-17  9:33   ` Damon Ding
2026-01-31 12:52   ` Luca Ceresoli
2026-01-31 12:52     ` Luca Ceresoli
2025-12-17  9:33 ` [PATCH v8 03/18] drm/bridge: analogix_dp: Move &drm_bridge_funcs.mode_set to &drm_bridge_funcs.atomic_enable Damon Ding
2025-12-17  9:33   ` Damon Ding
2026-01-31 12:50   ` Luca Ceresoli
2026-01-31 12:50     ` Luca Ceresoli
2025-12-17  9:33 ` [PATCH v8 04/18] drm/bridge: analogix_dp: Add &analogix_dp_plat_data.next_bridge Damon Ding
2025-12-17  9:33   ` Damon Ding
2025-12-31 11:11   ` Luca Ceresoli
2025-12-31 11:11     ` Luca Ceresoli
2026-01-04  2:51     ` Damon Ding
2026-01-04  2:51       ` Damon Ding
2026-01-07  2:36       ` Damon Ding
2026-01-07  2:36         ` Damon Ding
2026-01-31 13:41         ` Luca Ceresoli [this message]
2026-01-31 13:41           ` Luca Ceresoli
2025-12-17  9:33 ` [PATCH v8 05/18] drm/bridge: Move legacy bridge driver out of imx directory for multi-platform use Damon Ding
2025-12-17  9:33   ` Damon Ding
2026-01-31 12:33   ` Luca Ceresoli
2026-01-31 12:33     ` Luca Ceresoli
2026-02-02  2:54     ` Damon Ding
2026-02-02  2:54       ` Damon Ding
2026-02-03  1:31       ` Damon Ding
2026-02-03  1:31         ` Damon Ding
2026-02-03 10:11         ` Luca Ceresoli
2026-02-03 10:11           ` Luca Ceresoli
2026-02-03 14:09           ` Laurent Pinchart
2026-02-03 14:09             ` Laurent Pinchart
2026-02-04  1:09           ` Damon Ding
2026-02-04  1:09             ` Damon Ding
2025-12-17  9:33 ` [PATCH v8 06/18] drm/exynos: exynos_dp: Remove &exynos_dp_device.ptn_bridge Damon Ding
2025-12-17  9:33   ` Damon Ding
2026-01-31 13:41   ` Luca Ceresoli
2026-01-31 13:41     ` Luca Ceresoli
2025-12-17  9:33 ` [PATCH v8 07/18] drm/exynos: exynos_dp: Remove unused &exynos_dp_device.connector Damon Ding
2025-12-17  9:33   ` Damon Ding
2026-01-31 13:40   ` Luca Ceresoli
2026-01-31 13:40     ` Luca Ceresoli
2025-12-17  9:33 ` [PATCH v8 08/18] drm/exynos: exynos_dp: Apply of-display-mode-bridge to parse the display-timings node Damon Ding
2025-12-17  9:33   ` Damon Ding
2025-12-17  9:33 ` [PATCH v8 09/18] drm/bridge: analogix_dp: Remove redundant &analogix_dp_plat_data.skip_connector Damon Ding
2025-12-17  9:33   ` Damon Ding
2025-12-17  9:33 ` [PATCH v8 10/18] drm/bridge: analogix_dp: Move the color format check to .atomic_check() for Rockchip platforms Damon Ding
2025-12-17  9:33   ` Damon Ding
2025-12-17  9:33 ` [PATCH v8 11/18] drm/bridge: analogix_dp: Remove unused &analogix_dp_plat_data.get_modes() Damon Ding
2025-12-17  9:33   ` Damon Ding
2025-12-17  9:33 ` [PATCH v8 12/18] drm/bridge: analogix_dp: Apply drm_bridge_connector helper Damon Ding
2025-12-17  9:33   ` Damon Ding
2025-12-17  9:33 ` [PATCH v8 13/18] drm/bridge: analogix_dp: Add new API analogix_dp_finish_probe() Damon Ding
2025-12-17  9:33   ` Damon Ding
2025-12-17  9:59 ` [PATCH v8 14/18] drm/rockchip: analogix_dp: Apply analogix_dp_finish_probe() Damon Ding
2025-12-17  9:59   ` Damon Ding
2025-12-17  9:59   ` [PATCH v8 15/18] drm/exynos: exynos_dp: " Damon Ding
2025-12-17  9:59     ` Damon Ding
2025-12-17  9:59   ` [PATCH v8 16/18] drm/bridge: analogix_dp: Attach the next bridge in analogix_dp_bridge_attach() Damon Ding
2025-12-17  9:59     ` Damon Ding
2026-01-31 13:34     ` Luca Ceresoli
2026-01-31 13:34       ` Luca Ceresoli
2025-12-17  9:59   ` [PATCH v8 17/18] drm/bridge: analogix_dp: Remove bridge disabing and panel unpreparing in analogix_dp_unbind() Damon Ding
2025-12-17  9:59     ` Damon Ding
2025-12-17  9:59   ` [PATCH v8 18/18] drm/bridge: analogix_dp: Apply panel_bridge helper Damon Ding
2025-12-17  9:59     ` Damon Ding
2026-01-17  7:45 ` [PATCH v8 00/18] Apply drm_bridge_connector and panel_bridge helper for the Analogix DP driver Damon Ding
2026-01-17  7:45   ` Damon Ding
2026-01-19 16:06 ` Heiko Stübner
2026-01-19 16:06   ` Heiko Stübner
2026-02-02  1:33   ` Damon Ding
2026-02-02  1:33     ` Damon Ding
2026-02-03 11:11   ` Luca Ceresoli
2026-02-03 11:11     ` Luca Ceresoli
2026-02-04  1:52     ` Damon Ding
2026-02-04  1:52       ` Damon Ding
2026-02-03 11:53 ` (subset) " Luca Ceresoli
2026-02-03 11:53   ` Luca Ceresoli

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=DG2TG4NCMKXQ.36REPVMTQ7WWD@bootlin.com \
    --to=luca.ceresoli@bootlin.com \
    --cc=Laurent.pinchart@ideasonboard.com \
    --cc=airlied@gmail.com \
    --cc=alim.akhtar@samsung.com \
    --cc=andrzej.hajda@intel.com \
    --cc=andy.yan@rock-chips.com \
    --cc=damon.ding@rock-chips.com \
    --cc=dianders@chromium.org \
    --cc=dmitry.baryshkov@oss.qualcomm.com \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=festevam@gmail.com \
    --cc=heiko@sntech.de \
    --cc=hjc@rock-chips.com \
    --cc=imx@lists.linux.dev \
    --cc=inki.dae@samsung.com \
    --cc=jani.nikula@intel.com \
    --cc=jernej.skrabec@gmail.com \
    --cc=jingoohan1@gmail.com \
    --cc=jonas@kwiboo.se \
    --cc=kernel@pengutronix.de \
    --cc=krzk@kernel.org \
    --cc=kyungmin.park@samsung.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-rockchip@lists.infradead.org \
    --cc=linux-samsung-soc@vger.kernel.org \
    --cc=m.szyprowski@samsung.com \
    --cc=maarten.lankhorst@linux.intel.com \
    --cc=mripard@kernel.org \
    --cc=neil.armstrong@linaro.org \
    --cc=p.zabel@pengutronix.de \
    --cc=rfoss@kernel.org \
    --cc=s.hauer@pengutronix.de \
    --cc=shawnguo@kernel.org \
    --cc=simona@ffwll.ch \
    --cc=sw0312.kim@samsung.com \
    --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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.