devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Kaustabh Chakraborty <kauschluss@disroot.org>
To: Krzysztof Kozlowski <krzk@kernel.org>
Cc: Inki Dae <inki.dae@samsung.com>,
	Seung-Woo Kim <sw0312.kim@samsung.com>,
	Kyungmin Park <kyungmin.park@samsung.com>,
	David Airlie <airlied@gmail.com>, Simona Vetter <simona@ffwll.ch>,
	Alim Akhtar <alim.akhtar@samsung.com>,
	Maarten Lankhorst <maarten.lankhorst@linux.intel.com>,
	Maxime Ripard <mripard@kernel.org>,
	Thomas Zimmermann <tzimmermann@suse.de>,
	Rob Herring <robh@kernel.org>, Conor Dooley <conor@kernel.org>,
	dri-devel@lists.freedesktop.org,
	linux-arm-kernel@lists.infradead.org,
	linux-samsung-soc@vger.kernel.org, linux-kernel@vger.kernel.org,
	devicetree@vger.kernel.org, kauschluss@disroot.org
Subject: Re: [PATCH 2/6] drm/exynos: exynos7_drm_decon: fix suspended condition in decon_commit()
Date: Wed, 25 Sep 2024 19:22:26 +0000	[thread overview]
Message-ID: <206c17ac8f79bbd51bf94b8f1f72fbb9@disroot.org> (raw)
In-Reply-To: <f64c303e-8a88-4aee-9110-ee4a06a3d67f@kernel.org>

On 2024-09-20 12:40, Krzysztof Kozlowski wrote:
> On 19/09/2024 17:11, Kaustabh Chakraborty wrote:
>> decon_commit() gets called during atomic_enable. At this stage, DECON is
>> suspended, and thus the function refuses to run. Fix the suspended
>> condition checking in decon_commit().
>> 
>> Signed-off-by: Kaustabh Chakraborty <kauschluss@disroot.org>
>> ---
> 
> If this is a fix, then you miss fixes tag and cc-stable. However the
> explanation seems just incomplete. This looked like a intentional code,
> so you should explain really why original approach was wrong.

Fixes: 96976c3d9aff ("drm/exynos: Add DECON driver")

Now that I read the commit description of the above commit, which mentions
that the DECON driver is based on the FIMD driver, I think it makes more
sense to rewrite the suspend logic exactly as done in the FIMD driver.
Will do it in v2.

Here's a commit description which may be better suited, let me know:

A flag variable in struct decon_context, called 'suspended' is set to false
at the end of decon_atomic_enable() and is set back to true at the end of
decon_atomic_disable().

Functions called in decon_atomic_enable(), such as decon_enable_vblank()
and decon_commit() are guarded by suspend condition checking, where it
refuses to proceed if 'suspended' is set to true. Since 'suspended' isn't
set to true until the end of the calling function, the called functions
aren't even executed.

The original commit, 96976c3d9aff ("drm/exynos: Add DECON driver")
implementing the DECON driver, is based on the FIMD driver, but changes
the suspend flag logic which causes this issue. Implement the suspend
logic present in FIMD, which changes the flag at the beginning of
atomic_enable and atomic_disable instead.

> 
> Best regards,
> Krzysztof

  reply	other threads:[~2024-09-25 19:22 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <CGME20240919151130epcas1p10a885b3364250f5ff4e06975cfef13e4@epcas1p1.samsung.com>
2024-09-19 15:10 ` [PATCH 0/6] Samsung Exynos 7870 DECON driver support Kaustabh Chakraborty
2024-09-19 15:11   ` [PATCH 1/6] drm/exynos: exynos7_drm_decon: fix uninitialized crtc reference in functions Kaustabh Chakraborty
2024-09-19 15:11   ` [PATCH 2/6] drm/exynos: exynos7_drm_decon: fix suspended condition in decon_commit() Kaustabh Chakraborty
2024-09-20 12:40     ` Krzysztof Kozlowski
2024-09-25 19:22       ` Kaustabh Chakraborty [this message]
2024-09-19 15:11   ` [PATCH 3/6] drm/exynos: exynos7_drm_decon: fix ideal_clk by converting it to Hz Kaustabh Chakraborty
2024-10-07 10:38     ` 대인기/Tizen Platform Lab(SR)/삼성전자
2024-09-19 15:11   ` [PATCH 4/6] drm/exynos: exynos7_drm_decon: properly clear channels during bind Kaustabh Chakraborty
2024-09-19 15:19   ` [PATCH 5/6] drm/exynos: exynos7_drm_decon: add driver data and support for Exynos7870 Kaustabh Chakraborty
2024-09-19 15:20   ` [PATCH 6/6] dt-bindings: display: samsung,exynos7-decon: add exynos7870 compatible Kaustabh Chakraborty
2024-09-20 12:39     ` Krzysztof Kozlowski
2024-09-25 18:42       ` Kaustabh Chakraborty
2024-09-25 19:25         ` Krzysztof Kozlowski
2024-09-25 19:36           ` Kaustabh Chakraborty
2024-09-25 19:56             ` Krzysztof Kozlowski
2024-09-25 20:05               ` Kaustabh Chakraborty
2024-09-25 20:34                 ` Krzysztof Kozlowski
     [not found]                 ` <CGME20240926053449epcas1p2e8596f64b7ee5d3b8cdf565bacdc6510@epcas1p2.samsung.com>
2024-09-26  5:34                   ` Kwanghoon Son
2024-09-28 16:25                     ` Kaustabh Chakraborty
2024-11-01  5:08   ` [PATCH 0/6] Samsung Exynos 7870 DECON driver support 대인기/Tizen Platform Lab(SR)/삼성전자
2024-11-05 20:11     ` Rob Herring
2024-11-05 23:54       ` 대인기/Tizen Platform Lab(SR)/삼성전자

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=206c17ac8f79bbd51bf94b8f1f72fbb9@disroot.org \
    --to=kauschluss@disroot.org \
    --cc=airlied@gmail.com \
    --cc=alim.akhtar@samsung.com \
    --cc=conor@kernel.org \
    --cc=devicetree@vger.kernel.org \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=inki.dae@samsung.com \
    --cc=krzk@kernel.org \
    --cc=kyungmin.park@samsung.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-samsung-soc@vger.kernel.org \
    --cc=maarten.lankhorst@linux.intel.com \
    --cc=mripard@kernel.org \
    --cc=robh@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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).