diff options
author | Tomeu Vizoso <tomeu.vizoso@collabora.com> | 2016-09-23 16:06:40 +0200 |
---|---|---|
committer | Daniel Vetter <daniel.vetter@ffwll.ch> | 2016-10-04 08:23:17 +0200 |
commit | 0546d685f07cc4fc5748fd36e57d167877c2842d (patch) | |
tree | 56b229e308a2efaae292b3bb0d0d8308a39ef518 /drivers/gpu | |
parent | drm/bridge: analogix_dp: Add analogix_dp_psr_supported (diff) | |
download | linux-0546d685f07cc4fc5748fd36e57d167877c2842d.tar.xz linux-0546d685f07cc4fc5748fd36e57d167877c2842d.zip |
drm/rockchip: analogix_dp: Refuse to enable PSR if panel doesn't support it
There's no point in enabling PSR when the panel doesn't support it.
This also avoids a problem when PSR gets enabled when a CRTC is being
disabled, because sometimes in that situation the DSP_HOLD_VALID_INTR
interrupt on which we wait will never arrive. This was observed on
RK3288 with a panel without PSR (veyron-jaq Chromebook).
It's very easy to reproduce by running the kms_rmfb test in IGT a few
times.
Cc: Yakir Yang <ykk@rock-chips.com>
Reviewed-by: Sean Paul <seanpaul@chromium.org>
Signed-off-by: Tomeu Vizoso <tomeu.vizoso@collabora.com>
Signed-off-by: Archit Taneja <architt@codeaurora.org>
Link: http://patchwork.freedesktop.org/patch/msgid/1474639600-30090-2-git-send-email-tomeu.vizoso@collabora.com
Diffstat (limited to 'drivers/gpu')
-rw-r--r-- | drivers/gpu/drm/rockchip/analogix_dp-rockchip.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/gpu/drm/rockchip/analogix_dp-rockchip.c b/drivers/gpu/drm/rockchip/analogix_dp-rockchip.c index e83be157cc2a..8548e8271639 100644 --- a/drivers/gpu/drm/rockchip/analogix_dp-rockchip.c +++ b/drivers/gpu/drm/rockchip/analogix_dp-rockchip.c @@ -85,6 +85,9 @@ static void analogix_dp_psr_set(struct drm_encoder *encoder, bool enabled) struct rockchip_dp_device *dp = to_dp(encoder); unsigned long flags; + if (!analogix_dp_psr_supported(dp->dev)) + return; + dev_dbg(dp->dev, "%s PSR...\n", enabled ? "Entry" : "Exit"); spin_lock_irqsave(&dp->psr_lock, flags); |