Received: by 2002:a05:6a10:eb17:0:0:0:0 with SMTP id hx23csp540950pxb; Thu, 9 Sep 2021 06:45:21 -0700 (PDT) X-Google-Smtp-Source: ABdhPJx1LRndh+DcjhunW9em9Cp7kYq7fYicHelYx+FjDNBxX039xpuAgggZDctpicxcEt4J8b7B X-Received: by 2002:a02:ad17:: with SMTP id s23mr2908956jan.135.1631195121280; Thu, 09 Sep 2021 06:45:21 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1631195121; cv=none; d=google.com; s=arc-20160816; b=08kxkCrY5CXwSz5pW5rs9FmcVzxnolOJksuxm3mjB7L5FOHJfHYe4yvMMucA4IKev2 50QOFT/h5QhixjeXF//fRc1w0SK0DV8HuuHNHfcJ7a/TtY0MpTYaSeXWHFvuWdqhNZm8 h+m8ATBEphOrSEDzPs7bPTgSw2Tv3zCbUvNYauZpdMfK7ECbtf9G5Dm2lARqz8TyUwN/ CQdEKQB4RzXRy88GKKaxtZ3pbA5gDG+epi4O3+wTDPl8LYGhXJ0OKortvrlra3FsAn21 PN+7Zz5AdVhjvQYdrXUPjP9G1JCcHD+h60mKSE5djN9DPV1nATzlA/QaX+RreWaqgc9r h1lg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=Ck06a6y1g8ydUkQRok1GFjvGmmxIfzxU6BXpdFjNzTo=; b=R2NFhtnJ8cteGWOxPhMtwKiHlchMbsuSQrRmwe+H3Ekx7HYY8tsQW5sxwFO9hShAXA ZgyAzIpy44Fv9BvVEG8KMF2w66ZKa2FVHx/MRmaqy1so/MUTfzv1rdrJqX3N9GnDPkxL bv7QweU8fh4aZ3pWvZlVKl8S5ToRySwVfnhvG4YeGzKu/NGQmWacRS+TVsGArb5SXacW qcvkH6GhvPyX/hDuCdOVAHUy/A/MNrpH7e+5a8Me/sAMgiK+LUPUCgzM+s94TssfHx3q wO57FM+kbYuwde+Og+6syIXKGyh5ISLnAAslyiLy+/Lxnzxo1Rz5w07MvuPYHxC7g6pA qj7g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b="C37/nFb8"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id 13si2303038jan.43.2021.09.09.06.45.09; Thu, 09 Sep 2021 06:45:21 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b="C37/nFb8"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1357627AbhIINoV (ORCPT + 99 others); Thu, 9 Sep 2021 09:44:21 -0400 Received: from mail.kernel.org ([198.145.29.99]:60536 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1351801AbhIIMrH (ORCPT ); Thu, 9 Sep 2021 08:47:07 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id 026BF613D0; Thu, 9 Sep 2021 11:56:18 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1631188580; bh=6sB9V2TH2YXKggSm4ORmhaVpFYlE+jF8nGZ2tX7oayk=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=C37/nFb8NQvJIw7Chtpb6dP33LMvufkhlvmlA3pdcTRkfOkWYY5amuOgWdqGZBnnw ktNxYB/ZaMtSgldW9w22waXoHPL4l+ZhUh/6iLoJrn5/1az0hCExr5Dcv9wYDTKuln cEMuvEkO7QXztlrbXrDwC5GQD9/mV0a/rznJoeOP12DYZSSO9SZkZuX1h6irqeQH+3 FGUG+JChBMfFNZ0tgyWwYf2hGiX7BgD1v4rnLSh5Gr+vZkhC+3jwpy7C38Ze0Z+PFZ WjC3i0FhnZwc0aFyXIIDrTUimAevRInI6GhryJe7AAIztRogpGVGtav5Zcf31gEb8f 8XrW2ur7j12Aw== From: Sasha Levin To: linux-kernel@vger.kernel.org, stable@vger.kernel.org Cc: David Heidelberg , Dmitry Baryshkov , Rob Clark , Sasha Levin , linux-arm-msm@vger.kernel.org, dri-devel@lists.freedesktop.org, freedreno@lists.freedesktop.org Subject: [PATCH AUTOSEL 5.4 057/109] drm/msm: mdp4: drop vblank get/put from prepare/complete_commit Date: Thu, 9 Sep 2021 07:54:14 -0400 Message-Id: <20210909115507.147917-57-sashal@kernel.org> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20210909115507.147917-1-sashal@kernel.org> References: <20210909115507.147917-1-sashal@kernel.org> MIME-Version: 1.0 X-stable: review X-Patchwork-Hint: Ignore Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: David Heidelberg [ Upstream commit 56bd931ae506730c9ab1e4cc4bfefa43fc2d18fa ] msm_atomic is doing vblank get/put's already, currently there no need to duplicate the effort in MDP4 Fix warning: ... WARNING: CPU: 3 PID: 79 at drivers/gpu/drm/drm_vblank.c:1194 drm_vblank_put+0x1cc/0x1d4 ... and multiple vblank time-outs: ... msm 5100000.mdp: vblank time out, crtc=1 ... Tested on Nexus 7 2013 (deb), LTS 5.10.50. Introduced by: 119ecb7fd3b5 ("drm/msm/mdp4: request vblank during modeset") Signed-off-by: David Heidelberg Link: https://lore.kernel.org/r/20210715060925.7880-1-david@ixit.cz Signed-off-by: Dmitry Baryshkov Signed-off-by: Rob Clark Signed-off-by: Sasha Levin --- drivers/gpu/drm/msm/disp/mdp4/mdp4_kms.c | 13 ------------- 1 file changed, 13 deletions(-) diff --git a/drivers/gpu/drm/msm/disp/mdp4/mdp4_kms.c b/drivers/gpu/drm/msm/disp/mdp4/mdp4_kms.c index 20194d86d033..5d50e93efe36 100644 --- a/drivers/gpu/drm/msm/disp/mdp4/mdp4_kms.c +++ b/drivers/gpu/drm/msm/disp/mdp4/mdp4_kms.c @@ -108,13 +108,6 @@ static void mdp4_disable_commit(struct msm_kms *kms) static void mdp4_prepare_commit(struct msm_kms *kms, struct drm_atomic_state *state) { - int i; - struct drm_crtc *crtc; - struct drm_crtc_state *crtc_state; - - /* see 119ecb7fd */ - for_each_new_crtc_in_state(state, crtc, crtc_state, i) - drm_crtc_vblank_get(crtc); } static void mdp4_flush_commit(struct msm_kms *kms, unsigned crtc_mask) @@ -133,12 +126,6 @@ static void mdp4_wait_flush(struct msm_kms *kms, unsigned crtc_mask) static void mdp4_complete_commit(struct msm_kms *kms, unsigned crtc_mask) { - struct mdp4_kms *mdp4_kms = to_mdp4_kms(to_mdp_kms(kms)); - struct drm_crtc *crtc; - - /* see 119ecb7fd */ - for_each_crtc_mask(mdp4_kms->dev, crtc, crtc_mask) - drm_crtc_vblank_put(crtc); } static long mdp4_round_pixclk(struct msm_kms *kms, unsigned long rate, -- 2.30.2