From: Paul Cercueil <paul@crapouillou.net>
To: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>,
Maxime Ripard <mripard@kernel.org>,
Thomas Zimmermann <tzimmermann@suse.de>,
David Airlie <airlied@linux.ie>, Daniel Vetter <daniel@ffwll.ch>,
Simon Ser <contact@emersion.fr>
Cc: od@zcrc.me, dri-devel@lists.freedesktop.org,
linux-kernel@vger.kernel.org,
Paul Cercueil <paul@crapouillou.net>,
stable@vger.kernel.org
Subject: [PATCH] drm: DON'T require each CRTC to have a unique primary plane
Date: Sat, 27 Mar 2021 11:22:14 +0000 [thread overview]
Message-ID: <20210327112214.10252-1-paul@crapouillou.net> (raw)
The ingenic-drm driver has two mutually exclusive primary planes
already; so the fact that a CRTC must have one and only one primary
plane is an invalid assumption.
Fixes: 96962e3de725 ("drm: require each CRTC to have a unique primary plane")
Cc: <stable@vger.kernel.org> # 5.11
Signed-off-by: Paul Cercueil <paul@crapouillou.net>
---
drivers/gpu/drm/drm_mode_config.c | 11 -----------
1 file changed, 11 deletions(-)
diff --git a/drivers/gpu/drm/drm_mode_config.c b/drivers/gpu/drm/drm_mode_config.c
index 37b4b9f0e468..d86621c41047 100644
--- a/drivers/gpu/drm/drm_mode_config.c
+++ b/drivers/gpu/drm/drm_mode_config.c
@@ -626,9 +626,7 @@ void drm_mode_config_validate(struct drm_device *dev)
{
struct drm_encoder *encoder;
struct drm_crtc *crtc;
- struct drm_plane *plane;
u32 primary_with_crtc = 0, cursor_with_crtc = 0;
- unsigned int num_primary = 0;
if (!drm_core_check_feature(dev, DRIVER_MODESET))
return;
@@ -676,13 +674,4 @@ void drm_mode_config_validate(struct drm_device *dev)
cursor_with_crtc |= drm_plane_mask(crtc->cursor);
}
}
-
- drm_for_each_plane(plane, dev) {
- if (plane->type == DRM_PLANE_TYPE_PRIMARY)
- num_primary++;
- }
-
- WARN(num_primary != dev->mode_config.num_crtc,
- "Must have as many primary planes as there are CRTCs, but have %u primary planes and %u CRTCs",
- num_primary, dev->mode_config.num_crtc);
}
--
2.30.2
next reply other threads:[~2021-03-27 11:22 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-03-27 11:22 Paul Cercueil [this message]
2021-03-27 11:24 ` Simon Ser
2021-03-27 11:26 ` Paul Cercueil
2021-03-29 8:15 ` Pekka Paalanen
2021-03-29 11:41 ` Paul Cercueil
2021-03-29 14:35 ` Pekka Paalanen
2021-03-29 15:21 ` Paul Cercueil
2021-03-29 14:07 ` Maxime Ripard
2021-03-29 14:11 ` Simon Ser
2021-03-29 15:32 ` Paul Cercueil
2021-03-29 15:36 ` Simon Ser
2021-03-30 6:55 ` Pekka Paalanen
2021-03-29 15:15 ` Paul Cercueil
2021-03-29 15:35 ` Maxime Ripard
2021-03-29 15:39 ` Paul Cercueil
2021-03-29 15:42 ` Simon Ser
2021-03-29 16:15 ` Paul Cercueil
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=20210327112214.10252-1-paul@crapouillou.net \
--to=paul@crapouillou.net \
--cc=airlied@linux.ie \
--cc=contact@emersion.fr \
--cc=daniel@ffwll.ch \
--cc=dri-devel@lists.freedesktop.org \
--cc=linux-kernel@vger.kernel.org \
--cc=maarten.lankhorst@linux.intel.com \
--cc=mripard@kernel.org \
--cc=od@zcrc.me \
--cc=stable@vger.kernel.org \
--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®