mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Dave Stevenson <dave.stevenson@raspberrypi.com>
To: Maxime Ripard <mripard@kernel.org>,
	 Raspberry Pi Kernel Maintenance <kernel-list@raspberrypi.com>,
	 Maarten Lankhorst <maarten.lankhorst@linux.intel.com>,
	 Thomas Zimmermann <tzimmermann@suse.de>,
	David Airlie <airlied@gmail.com>,
	 Simona Vetter <simona@ffwll.ch>
Cc: Marek Szyprowski <m.szyprowski@samsung.com>,
	 dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org,
	 Dave Stevenson <dave.stevenson@raspberrypi.com>
Subject: [PATCH 1/3] drm/vc4: Match drm_dev_enter and exit calls in vc4_hvs_lut_load
Date: Tue, 08 Oct 2024 17:44:34 +0100	[thread overview]
Message-ID: <20241008-drm-vc4-fixes-v1-1-9d0396ca9f42@raspberrypi.com> (raw)
In-Reply-To: <20241008-drm-vc4-fixes-v1-0-9d0396ca9f42@raspberrypi.com>

Commit 52efe364d196 ("drm/vc4: hvs: Don't write gamma luts on 2711")
added a return path to vc4_hvs_lut_load that had called
drm_dev_enter, but not drm_dev_exit.

Ensure we call drm_dev_exit.

Fixes: 52efe364d196 ("drm/vc4: hvs: Don't write gamma luts on 2711")
Reported-by: Marek Szyprowski <m.szyprowski@samsung.com>
Closes: https://lore.kernel.org/dri-devel/37051126-3921-4afe-a936-5f828bff5752@samsung.com/
Signed-off-by: Dave Stevenson <dave.stevenson@raspberrypi.com>
---
 drivers/gpu/drm/vc4/vc4_hvs.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/vc4/vc4_hvs.c b/drivers/gpu/drm/vc4/vc4_hvs.c
index 2a366a607fcc..546ee11016b2 100644
--- a/drivers/gpu/drm/vc4/vc4_hvs.c
+++ b/drivers/gpu/drm/vc4/vc4_hvs.c
@@ -225,7 +225,7 @@ static void vc4_hvs_lut_load(struct vc4_hvs *hvs,
 		return;
 
 	if (hvs->vc4->gen == VC4_GEN_4)
-		return;
+		goto exit;
 
 	/* The LUT memory is laid out with each HVS channel in order,
 	 * each of which takes 256 writes for R, 256 for G, then 256
@@ -242,6 +242,7 @@ static void vc4_hvs_lut_load(struct vc4_hvs *hvs,
 	for (i = 0; i < crtc->gamma_size; i++)
 		HVS_WRITE(SCALER_GAMDATA, vc4_crtc->lut_b[i]);
 
+exit:
 	drm_dev_exit(idx);
 }
 

-- 
2.34.1


  reply	other threads:[~2024-10-08 16:44 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-10-08 16:44 [PATCH 0/3] drm/vc4: 3 minor fixes from mismatched drm_dev_[enter|exit] calls Dave Stevenson
2024-10-08 16:44 ` Dave Stevenson [this message]
2024-10-09  1:22   ` [PATCH 1/3] drm/vc4: Match drm_dev_enter and exit calls in vc4_hvs_lut_load Maíra Canal
2024-10-09  6:20   ` Marek Szyprowski
2024-10-08 16:44 ` [PATCH 2/3] drm/vc4: Match drm_dev_enter and exit calls in vc4_hvs_atomic_flush Dave Stevenson
2024-10-09  1:26   ` Maíra Canal
2024-10-09  6:20   ` Marek Szyprowski
2024-10-08 16:44 ` [PATCH 3/3] drm/vc4: Correct generation check in vc4_hvs_lut_load Dave Stevenson
2024-10-09  1:30   ` Maíra Canal
2024-10-09 11:32     ` Dave Stevenson
2024-10-09  6:20   ` Marek Szyprowski
2024-10-09 12:15 ` [PATCH 0/3] drm/vc4: 3 minor fixes from mismatched drm_dev_[enter|exit] calls Dave Stevenson

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=20241008-drm-vc4-fixes-v1-1-9d0396ca9f42@raspberrypi.com \
    --to=dave.stevenson@raspberrypi.com \
    --cc=airlied@gmail.com \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=kernel-list@raspberrypi.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=m.szyprowski@samsung.com \
    --cc=maarten.lankhorst@linux.intel.com \
    --cc=mripard@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

all inboxes | Powered by JetHome®