[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20190403201326.3127-3-sebastian.reichel@collabora.com>
Date: Wed, 3 Apr 2019 22:13:24 +0200
From: Sebastian Reichel <sebastian.reichel@...labora.com>
To: Sebastian Reichel <sre@...nel.org>,
Tomi Valkeinen <tomi.valkeinen@...com>,
Tony Lindgren <tony@...mide.com>, Pavel Machek <pavel@....cz>,
Laurent Pinchart <laurent.pinchart@...asonboard.com>
Cc: "H. Nikolaus Schaller" <hns@...delico.com>,
dri-devel@...ts.freedesktop.org, linux-omap@...r.kernel.org,
linux-kernel@...r.kernel.org, kernel@...labora.com,
Sebastian Reichel <sebastian.reichel@...labora.com>
Subject: [PATCHv6 2/4] drm/omap: don't check dispc timings for DSI
While most display types only forward their VM to the DISPC, this
is not true for DSI. DSI calculates the VM for DISPC based on its
own, but it's not identical. Actually the DSI VM is not even a valid
DISPC VM making this check fail. Let's restore the old behaviour
and avoid checking the DISPC VM for DSI here.
Fixes: 7c27fa57ef31 ("drm/omap: Call dispc timings check operation directly")
Acked-by: Pavel Machek <pavel@....cz>
Tested-by: Tony Lindgren <tony@...mide.com>
Tested-by: Pavel Machek <pavel@....cz>
Signed-off-by: Sebastian Reichel <sebastian.reichel@...labora.com>
---
drivers/gpu/drm/omapdrm/omap_crtc.c | 18 ++++++++++++++----
1 file changed, 14 insertions(+), 4 deletions(-)
diff --git a/drivers/gpu/drm/omapdrm/omap_crtc.c b/drivers/gpu/drm/omapdrm/omap_crtc.c
index 5a29bf01c0e8..86827a061b0b 100644
--- a/drivers/gpu/drm/omapdrm/omap_crtc.c
+++ b/drivers/gpu/drm/omapdrm/omap_crtc.c
@@ -395,10 +395,20 @@ static enum drm_mode_status omap_crtc_mode_valid(struct drm_crtc *crtc,
int r;
drm_display_mode_to_videomode(mode, &vm);
- r = priv->dispc_ops->mgr_check_timings(priv->dispc, omap_crtc->channel,
- &vm);
- if (r)
- return r;
+
+ /*
+ * DSI might not call this, since the supplied mode is not a
+ * valid DISPC mode. DSI will calculate and configure the
+ * proper DISPC mode later.
+ */
+ if (omap_crtc->pipe->output->next == NULL ||
+ omap_crtc->pipe->output->next->type != OMAP_DISPLAY_TYPE_DSI) {
+ r = priv->dispc_ops->mgr_check_timings(priv->dispc,
+ omap_crtc->channel,
+ &vm);
+ if (r)
+ return r;
+ }
/* Check for bandwidth limit */
if (priv->max_bandwidth) {
--
2.20.1
Powered by blists - more mailing lists