From patchwork Thu Feb 14 01:19:16 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jeykumar Sankaran X-Patchwork-Id: 10811535 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 8FCB41399 for ; Thu, 14 Feb 2019 01:19:33 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 747EB2DE18 for ; Thu, 14 Feb 2019 01:19:33 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 621E52DE31; Thu, 14 Feb 2019 01:19:33 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-7.7 required=2.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,MAILING_LIST_MULTI,RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id BBDF52DE1F for ; Thu, 14 Feb 2019 01:19:32 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729690AbfBNBTc (ORCPT ); Wed, 13 Feb 2019 20:19:32 -0500 Received: from smtp.codeaurora.org ([198.145.29.96]:60874 "EHLO smtp.codeaurora.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729745AbfBNBTc (ORCPT ); Wed, 13 Feb 2019 20:19:32 -0500 Received: by smtp.codeaurora.org (Postfix, from userid 1000) id 908CB6090C; Thu, 14 Feb 2019 01:19:30 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=codeaurora.org; s=default; t=1550107171; bh=7+SuD+G+p/I70qta7gP7cIjWjpFwTTKcUJlGV9eTrRg=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=GNvU7RUnTrc1FG496vJC+Y7qOejILiLHB3fmox17LEp5dN6lbr5NwKDct2PODX4Iz 1+6DfrWjDDjOz4X1Iy8qMVo8zxyXptO8clsCIzDv/BSD8WJeSzEON6jr6P+mBgfAIL 04J0cGH+KVe07gnN7lcw2X9J0UWvOD5Qw1lAJ8oM= Received: from jeykumar-linux.qualcomm.com (i-global254.qualcomm.com [199.106.103.254]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-SHA256 (128/128 bits)) (No client certificate requested) (Authenticated sender: jsanka@smtp.codeaurora.org) by smtp.codeaurora.org (Postfix) with ESMTPSA id E7A7960A3B; Thu, 14 Feb 2019 01:19:29 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=codeaurora.org; s=default; t=1550107170; bh=7+SuD+G+p/I70qta7gP7cIjWjpFwTTKcUJlGV9eTrRg=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=J1KAlNsKiyke+eSkW/cB5lpbX7QgUYqknvjp/MoMbvJwMrNIE48wx5mTaV/+be4mv 2o0oAPh+TNLHV/tG26evhrXr4ZKVplEGBiTFLzeaUIoju57lFlfNta5YaqpqmsxRh7 MsKOIm1Isk7NDBhEyJmBQ9chJdt6UWa+zPU4DaYc= DMARC-Filter: OpenDMARC Filter v1.3.2 smtp.codeaurora.org E7A7960A3B Authentication-Results: pdx-caf-mail.web.codeaurora.org; dmarc=none (p=none dis=none) header.from=codeaurora.org Authentication-Results: pdx-caf-mail.web.codeaurora.org; spf=none smtp.mailfrom=jsanka@codeaurora.org From: Jeykumar Sankaran To: dri-devel@lists.freedesktop.org, freedreno@lists.freedesktop.org, linux-arm-msm@vger.kernel.org Cc: Jeykumar Sankaran , seanpaul@chromium.org, robdclark@gmail.com, hoegsberg@google.com Subject: [PATCH v2 7/7] drm/msm/dpu: check split role for single flush Date: Wed, 13 Feb 2019 17:19:16 -0800 Message-Id: <1550107156-17625-8-git-send-email-jsanka@codeaurora.org> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1550107156-17625-1-git-send-email-jsanka@codeaurora.org> References: <1550107156-17625-1-git-send-email-jsanka@codeaurora.org> Sender: linux-arm-msm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Removing unwanted access of crtc_state for finding this information. Use split role information to know whether we have slave ctl. Signed-off-by: Jeykumar Sankaran Reviewed-by: Sean Paul --- drivers/gpu/drm/msm/disp/dpu1/dpu_encoder_phys_vid.c | 14 +------------- 1 file changed, 1 insertion(+), 13 deletions(-) diff --git a/drivers/gpu/drm/msm/disp/dpu1/dpu_encoder_phys_vid.c b/drivers/gpu/drm/msm/disp/dpu1/dpu_encoder_phys_vid.c index 02362c5..3fc3cc0 100644 --- a/drivers/gpu/drm/msm/disp/dpu1/dpu_encoder_phys_vid.c +++ b/drivers/gpu/drm/msm/disp/dpu1/dpu_encoder_phys_vid.c @@ -347,22 +347,10 @@ static void dpu_encoder_phys_vid_underrun_irq(void *arg, int irq_idx) phys_enc); } -static bool _dpu_encoder_phys_is_dual_ctl(struct dpu_encoder_phys *phys_enc) -{ - struct dpu_crtc_state *dpu_cstate; - - if (!phys_enc) - return false; - - dpu_cstate = to_dpu_crtc_state(phys_enc->parent->crtc->state); - - return dpu_cstate->num_ctls > 1; -} - static bool dpu_encoder_phys_vid_needs_single_flush( struct dpu_encoder_phys *phys_enc) { - return (phys_enc && _dpu_encoder_phys_is_dual_ctl(phys_enc)); + return phys_enc->split_role != ENC_ROLE_SOLO; } static void _dpu_encoder_phys_vid_setup_irq_hw_idx(