dri-devel Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Boris Brezillon <boris.brezillon@collabora.com>
To: Marek Szyprowski <m.szyprowski@samsung.com>
Cc: Jernej Skrabec <jernej.skrabec@siol.net>,
	Jonas Karlman <jonas@kwiboo.se>,
	Neil Armstrong <narmstrong@baylibre.com>,
	Seung-Woo Kim <sw0312.kim@samsung.com>,
	dri-devel@lists.freedesktop.org,
	Kyungmin Park <kyungmin.park@samsung.com>,
	Laurent Pinchart <Laurent.pinchart@ideasonboard.com>
Subject: Re: [PATCH 3/3] drm/exynos: dsi: Fix bridge chain handling
Date: Tue, 7 Jan 2020 14:34:16 +0100	[thread overview]
Message-ID: <20200107143416.33717553@collabora.com> (raw)
In-Reply-To: <3cf5afd7-9bdf-25ac-0683-2b72105681eb@samsung.com>

Hi Marek,

On Tue, 7 Jan 2020 10:11:43 +0100
Marek Szyprowski <m.szyprowski@samsung.com> wrote:

> Hi Boris,
> 
> Sorry, for the late reply, I've just got back from my prolonged Chrismas 
> holidays.
> 
> On 27.12.2019 15:41, Boris Brezillon wrote:
> > Commit 05193dc38197 ("drm/bridge: Make the bridge chain a double-linked
> > list") patched the bridge chain logic to use a double-linked list instead
> > of a single-linked list. This change induced changes to the Exynos driver
> > which was manually resetting the encoder->bridge element to NULL to
> > control the enable/disable sequence of the bridge chain. During this
> > conversion, 2 bugs were introduced:
> >
> > 1/ list_splice() was used to move chain elements to our own internal
> >     chain, but list_splice() does not reset the source list to an empty
> >     state, leading to unexpected bridge hook calls when
> >     drm_bridge_chain_xxx() helpers were called by the core. Replacing
> >     the list_splice() call by list_splice_init() fixes this problem.
> >
> > 2/ drm_bridge_chain_xxx() helpers operate on the
> >     bridge->encoder->bridge_chain list, which is now empty. When the
> >     helper uses list_for_each_entry_reverse() we end up with no operation
> >     done which is not what we want. But that's even worse when the helper
> >     uses list_for_each_entry_from(), because in that case we end up in
> >     an infinite loop searching for the list head element which is no
> >     longer encoder->bridge_chain but exynos_dsi->bridge_chain. To address
> >     that problem we stop using the bridge chain helpers and call the
> >     hooks directly.
> >
> > Reported-by: Marek Szyprowski <m.szyprowski@samsung.com>
> > Fixes: 05193dc38197 ("drm/bridge: Make the bridge chain a double-linked list")
> > Signed-off-by: Boris Brezillon <boris.brezillon@collabora.com>  
> 
> Works fine on Exynos5250-based Arndale board.
> 
> Tested-by: Marek Szyprowski <m.szyprowski@samsung.com>

Thanks for testing, but can you also add your R-b (I need it to make
dim happy)? While you're at it, maybe you can review patch 2 (it's very
similar to this patch).
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

  reply	other threads:[~2020-01-07 13:34 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-12-27 14:41 [PATCH 1/3] drm/bridge: Fix drm_bridge_chain_pre_enable() Boris Brezillon
2019-12-27 14:41 ` [PATCH 2/3] drm/vc4: dsi: Fix bridge chain handling Boris Brezillon
2020-01-07 15:17   ` Andrzej Hajda
2019-12-27 14:41 ` [PATCH 3/3] drm/exynos: " Boris Brezillon
2020-01-06  7:41   ` Boris Brezillon
2020-01-07  9:11   ` Marek Szyprowski
2020-01-07 13:34     ` Boris Brezillon [this message]
2020-01-07 14:30   ` Andrzej Hajda
2020-01-06 10:29 ` [PATCH 1/3] drm/bridge: Fix drm_bridge_chain_pre_enable() Laurent Pinchart
2020-01-07 15:27   ` Andrzej Hajda
2020-01-07 15:33     ` Boris Brezillon

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=20200107143416.33717553@collabora.com \
    --to=boris.brezillon@collabora.com \
    --cc=Laurent.pinchart@ideasonboard.com \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=jernej.skrabec@siol.net \
    --cc=jonas@kwiboo.se \
    --cc=kyungmin.park@samsung.com \
    --cc=m.szyprowski@samsung.com \
    --cc=narmstrong@baylibre.com \
    --cc=sw0312.kim@samsung.com \
    /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