From patchwork Wed Nov 26 18:10:50 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Gustavo Padovan X-Patchwork-Id: 5387241 Return-Path: X-Original-To: patchwork-dri-devel@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork2.web.kernel.org (Postfix) with ESMTP id 9BFD1C11AC for ; Wed, 26 Nov 2014 18:11:15 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id DA0B920160 for ; Wed, 26 Nov 2014 18:11:14 +0000 (UTC) Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) by mail.kernel.org (Postfix) with ESMTP id 0F0AD20107 for ; Wed, 26 Nov 2014 18:11:14 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 390926E671; Wed, 26 Nov 2014 10:11:13 -0800 (PST) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from mail-qa0-f47.google.com (mail-qa0-f47.google.com [209.85.216.47]) by gabe.freedesktop.org (Postfix) with ESMTP id A5ED36E671 for ; Wed, 26 Nov 2014 10:11:11 -0800 (PST) Received: by mail-qa0-f47.google.com with SMTP id s7so2278461qap.34 for ; Wed, 26 Nov 2014 10:11:11 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=RhMm8VLW+aQYn+H7IB235adUlhyzpjB540K1sPCYY9E=; b=BrGI/7b+hHCL0KrqGOFA3zlvcqteBTS9zYa0pQKcumjmU5Hdk1yAdNKpEWxRqFCxKq sSyDdYeC576NZQsbHD7c5pIwNn6LzGMPq89EBF0ZcUh+EwhxXp+Qi5hERAetHLe8SLz0 AtlLknUC+s+eEv1KtrKTHXJyJ1MqwqobleKpVdcqItAhKt3iNuDZbnH57Gzv+tW9sXnR 9t5KbHbS9xuvZD57zVJzFMZkBxECxaF061NR61WVIdUJbOe175uiBi3Yg7CZyTzS9GaS gvG7EqASvnWUf+AQKvri7lntAVCoeUR2htrVbMjrvvsVMy5aAUpm7PRAeNUFTTbCGVaC A7tQ== X-Received: by 10.224.89.69 with SMTP id d5mr47806673qam.84.1417025470905; Wed, 26 Nov 2014 10:11:10 -0800 (PST) Received: from localhost.localdomain ([191.8.93.69]) by mx.google.com with ESMTPSA id n8sm4483509qaz.40.2014.11.26.10.11.07 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 26 Nov 2014 10:11:10 -0800 (PST) From: Gustavo Padovan To: linux-samsung-soc@vger.kernel.org Subject: [PATCH 2/6] drm/exynos: don't do any DPMS operation while updating planes Date: Wed, 26 Nov 2014 16:10:50 -0200 Message-Id: <1417025454-3916-3-git-send-email-gustavo@padovan.org> X-Mailer: git-send-email 1.9.3 In-Reply-To: <1417025454-3916-1-git-send-email-gustavo@padovan.org> References: <1417025454-3916-1-git-send-email-gustavo@padovan.org> Cc: Gustavo Padovan , dri-devel@lists.freedesktop.org X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" X-Spam-Status: No, score=-4.2 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_MED, T_RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP From: Gustavo Padovan DPMS only makes sense when the mode changes, for plane update changes do not perform any dpms operation. This move places the win_commit() and commit() calls directly in the code instead of calling exynos_drm_crtc_commit() thus avoiding DPMS operations. Signed-off-by: Gustavo Padovan --- drivers/gpu/drm/exynos/exynos_drm_crtc.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/exynos/exynos_drm_crtc.c b/drivers/gpu/drm/exynos/exynos_drm_crtc.c index 13c7ba5..e946b5f5 100644 --- a/drivers/gpu/drm/exynos/exynos_drm_crtc.c +++ b/drivers/gpu/drm/exynos/exynos_drm_crtc.c @@ -115,6 +115,8 @@ static int exynos_drm_crtc_mode_set_commit(struct drm_crtc *crtc, int x, int y, struct drm_framebuffer *old_fb) { struct exynos_drm_crtc *exynos_crtc = to_exynos_crtc(crtc); + struct exynos_drm_manager *manager = exynos_crtc->manager; + struct exynos_drm_plane *exynos_plane = to_exynos_plane(crtc->primary); struct drm_framebuffer *fb = crtc->primary->fb; unsigned int crtc_w; unsigned int crtc_h; @@ -134,7 +136,11 @@ static int exynos_drm_crtc_mode_set_commit(struct drm_crtc *crtc, int x, int y, if (ret) return ret; - exynos_drm_crtc_commit(crtc); + if (manager->ops->win_commit) + manager->ops->win_commit(manager, exynos_plane->zpos); + + if (manager->ops->commit) + manager->ops->commit(manager); return 0; }