Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753235AbcJCLN5 (ORCPT ); Mon, 3 Oct 2016 07:13:57 -0400 Received: from smtp.codeaurora.org ([198.145.29.96]:57446 "EHLO smtp.codeaurora.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752384AbcJCLNs (ORCPT ); Mon, 3 Oct 2016 07:13:48 -0400 DMARC-Filter: OpenDMARC Filter v1.3.1 smtp.codeaurora.org DE55160250 Authentication-Results: pdx-caf-mail.web.codeaurora.org; dmarc=none header.from=codeaurora.org Authentication-Results: pdx-caf-mail.web.codeaurora.org; spf=pass smtp.mailfrom=architt@codeaurora.org Subject: Re: [PATCH 2/2] drm/rockchip: analogix_dp: Refuse to enable PSR if panel doesn't support it To: Sean Paul , Tomeu Vizoso References: <1474639600-30090-1-git-send-email-tomeu.vizoso@collabora.com> <1474639600-30090-2-git-send-email-tomeu.vizoso@collabora.com> Cc: Linux Kernel Mailing List , Yakir Yang , Mark Yao , David Airlie , Heiko Stuebner , dri-devel , Linux ARM Kernel , linux-rockchip@lists.infradead.org From: Archit Taneja Message-ID: Date: Mon, 3 Oct 2016 16:43:41 +0530 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.2.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1786 Lines: 57 On 09/27/2016 06:58 PM, Sean Paul wrote: > On Fri, Sep 23, 2016 at 10:06 AM, Tomeu Vizoso > wrote: >> 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. >> >> Signed-off-by: Tomeu Vizoso > > Thanks for digging into this. > > Reviewed-by: Sean Paul > queued to drm-misc. Archit > > >> Cc: Sean Paul >> Cc: Yakir Yang >> Cc: Archit Taneja >> --- >> drivers/gpu/drm/rockchip/analogix_dp-rockchip.c | 3 +++ >> 1 file changed, 3 insertions(+) >> >> 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); >> -- >> 2.7.4 >> -- Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum, a Linux Foundation Collaborative Project