From patchwork Sat Aug 15 16:26:19 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Gustavo Padovan X-Patchwork-Id: 7021141 Return-Path: X-Original-To: patchwork-linux-samsung-soc@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork2.web.kernel.org (Postfix) with ESMTP id E015EC05AC for ; Sat, 15 Aug 2015 16:26:53 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 16B93206DB for ; Sat, 15 Aug 2015 16:26:53 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 27A4C206E2 for ; Sat, 15 Aug 2015 16:26:52 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753964AbbHOQ0v (ORCPT ); Sat, 15 Aug 2015 12:26:51 -0400 Received: from mail-yk0-f173.google.com ([209.85.160.173]:35349 "EHLO mail-yk0-f173.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753923AbbHOQ0v (ORCPT ); Sat, 15 Aug 2015 12:26:51 -0400 Received: by ykbi184 with SMTP id i184so28634748ykb.2 for ; Sat, 15 Aug 2015 09:26:50 -0700 (PDT) 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=RS6U+ETlcE41kBj+PV3D0ygwoYvxvuNah5A+cSmZ/pQ=; b=Ey18msN23HaW0CI8E6HUm48LH7xbV5mvWFhQipfaEtEwL8iAtcCUA0uqA6uq0pd6Rh uvV8q54FV8thrYlLD7G2JGEw1YfxmGUBRWZ0wwWC55kr6nUDydCUk4bdduSSH9lVx6gq e+IBjBKtadvqY0DUKFERtF2LxmGVZ4R3Yqy63AkzZrcOMcKzxmcvlyHN5LWlMA/CoxUp hrlbtX6Y+08eCGYpUt6cB6S2lZ9XIJAQ9NQnqiDJG7JDsgYa1PkvGkiu1QMZ1Tl00gY/ LWiDh3AkbQSVj2nWTqqDV6tbX78nxvcILJFuTAteUNIqEA5YvgWIEWVAQx5xNmyg2GCe PV2w== X-Received: by 10.13.226.22 with SMTP id l22mr41960481ywe.67.1439656010902; Sat, 15 Aug 2015 09:26:50 -0700 (PDT) Received: from jade.localdomain ([187.64.235.140]) by smtp.gmail.com with ESMTPSA id m132sm8636775ywb.34.2015.08.15.09.26.48 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sat, 15 Aug 2015 09:26:50 -0700 (PDT) From: Gustavo Padovan To: linux-samsung-soc@vger.kernel.org Cc: dri-devel@lists.freedesktop.org, inki.dae@samsung.com, jy0922.shim@samsung.com, tjakobi@math.uni-bielefeld.de, Gustavo Padovan Subject: [PATCH 10/11] drm/exynos: remove wait queue for pending page flip Date: Sat, 15 Aug 2015 13:26:19 -0300 Message-Id: <1439655980-32146-11-git-send-email-gustavo@padovan.org> X-Mailer: git-send-email 2.1.0 In-Reply-To: <1439655980-32146-1-git-send-email-gustavo@padovan.org> References: <1439655980-32146-1-git-send-email-gustavo@padovan.org> Sender: linux-samsung-soc-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-samsung-soc@vger.kernel.org X-Spam-Status: No, score=-6.9 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, T_RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=ham 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 Exynos atomic commit procedures already does this job of waiting for pending updates to finish, that means using pending_flip_queue is pointless now because the disable CRTC procedure will never happen during a page_flip. Signed-off-by: Gustavo Padovan --- drivers/gpu/drm/exynos/exynos_drm_crtc.c | 11 +---------- drivers/gpu/drm/exynos/exynos_drm_drv.h | 1 - 2 files changed, 1 insertion(+), 11 deletions(-) diff --git a/drivers/gpu/drm/exynos/exynos_drm_crtc.c b/drivers/gpu/drm/exynos/exynos_drm_crtc.c index 049ab67..44bb30e 100644 --- a/drivers/gpu/drm/exynos/exynos_drm_crtc.c +++ b/drivers/gpu/drm/exynos/exynos_drm_crtc.c @@ -35,11 +35,6 @@ static void exynos_drm_crtc_disable(struct drm_crtc *crtc) { struct exynos_drm_crtc *exynos_crtc = to_exynos_crtc(crtc); - /* wait for the completion of page flip. */ - if (!wait_event_timeout(exynos_crtc->pending_flip_queue, - (exynos_crtc->event == NULL), HZ/20)) - exynos_crtc->event = NULL; - drm_crtc_vblank_off(crtc); if (exynos_crtc->ops->disable) @@ -144,8 +139,6 @@ struct exynos_drm_crtc *exynos_drm_crtc_create(struct drm_device *drm_dev, if (!exynos_crtc) return ERR_PTR(-ENOMEM); - init_waitqueue_head(&exynos_crtc->pending_flip_queue); - exynos_crtc->pipe = pipe; exynos_crtc->type = type; exynos_crtc->ops = ops; @@ -213,10 +206,8 @@ void exynos_drm_crtc_finish_update(struct exynos_drm_crtc *exynos_crtc, wake_up(&exynos_crtc->wait_update); spin_lock_irqsave(&crtc->dev->event_lock, flags); - if (exynos_crtc->event) { + if (exynos_crtc->event) drm_crtc_send_vblank_event(crtc, exynos_crtc->event); - wake_up(&exynos_crtc->pending_flip_queue); - } exynos_crtc->event = NULL; spin_unlock_irqrestore(&crtc->dev->event_lock, flags); diff --git a/drivers/gpu/drm/exynos/exynos_drm_drv.h b/drivers/gpu/drm/exynos/exynos_drm_drv.h index d77dca4..5d052235 100644 --- a/drivers/gpu/drm/exynos/exynos_drm_drv.h +++ b/drivers/gpu/drm/exynos/exynos_drm_drv.h @@ -145,7 +145,6 @@ struct exynos_drm_crtc { struct drm_crtc base; enum exynos_drm_output_type type; unsigned int pipe; - wait_queue_head_t pending_flip_queue; struct drm_pending_vblank_event *event; wait_queue_head_t wait_update; atomic_t pending_update;