From patchwork Thu Nov 15 07:22:30 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Inki Dae X-Patchwork-Id: 1747291 Return-Path: X-Original-To: patchwork-dri-devel@patchwork.kernel.org Delivered-To: patchwork-process-083081@patchwork2.kernel.org Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) by patchwork2.kernel.org (Postfix) with ESMTP id 99093DFFEC for ; Thu, 15 Nov 2012 07:22:44 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 7672D9E8DD for ; Wed, 14 Nov 2012 23:22:44 -0800 (PST) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from mailout1.samsung.com (mailout1.samsung.com [203.254.224.24]) by gabe.freedesktop.org (Postfix) with ESMTP id 3A6E29E763 for ; Wed, 14 Nov 2012 23:22:32 -0800 (PST) Received: from epcpsbgm1.samsung.com (epcpsbgm1 [203.254.230.26]) by mailout1.samsung.com (Oracle Communications Messaging Server 7u4-24.01(7.0.4.24.0) 64bit (built Nov 17 2011)) with ESMTP id <0MDI00432PT3R9F0@mailout1.samsung.com> for dri-devel@lists.freedesktop.org; Thu, 15 Nov 2012 16:22:31 +0900 (KST) Received: from epcpsbgm1.samsung.com ( [203.254.230.43]) by epcpsbgm1.samsung.com (EPCPMTA) with SMTP id D0.D2.01231.73894A05; Thu, 15 Nov 2012 16:22:31 +0900 (KST) X-AuditID: cbfee61a-b7fa66d0000004cf-b0-50a49837ca89 Received: from epmmp1.local.host ( [203.254.227.16]) by epcpsbgm1.samsung.com (EPCPMTA) with SMTP id 90.D2.01231.73894A05; Thu, 15 Nov 2012 16:22:31 +0900 (KST) Received: from daeinki-desktop.10.32.193.11 ([10.90.51.53]) by mmp1.samsung.com (Oracle Communications Messaging Server 7u4-24.01 (7.0.4.24.0) 64bit (built Nov 17 2011)) with ESMTPA id <0MDI00BHOPTJMB40@mmp1.samsung.com> for dri-devel@lists.freedesktop.org; Thu, 15 Nov 2012 16:22:31 +0900 (KST) From: Inki Dae To: airlied@linux.ie, dri-devel@lists.freedesktop.org Subject: [PATCH] drm/exynos: make sure that overlay data are updated Date: Thu, 15 Nov 2012 16:22:30 +0900 Message-id: <1352964150-31675-1-git-send-email-inki.dae@samsung.com> X-Mailer: git-send-email 1.7.4.1 DLP-Filter: Pass X-MTR: 20000000000000000@CPGS X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFjrCLMWRmVeSWpSXmKPExsVy+t8zbV3zGUsCDA6ekre48vU9mwOjx/3u 40wBjFFcNimpOZllqUX6dglcGSsOPWcrWM9Xsbp/D1sDYw9PFyMnh4SAicTXHUdZIWwxiQv3 1rN1MXJxCAksY5Q4M28DO0zR6auToRKLGCXW/DvPDuGsZ5KYNeULE0gVm4CqxMQV99lAbBEB U4mOSUtZQGxmgUKJhT1PwWxhAReJNzunMHcxcnCwANWfm2oPEuYFCp99vJYFYpmCxIJ7b8HG sAgISHybfIgFpFxCQFZi0wFmkLUSAjvYJLZenApVLylxcMUNlgmMggsYGVYxiqYWJBcUJ6Xn GuoVJ+YWl+al6yXn525ihASV1A7GlQ0WhxgFOBiVeHgdfiwOEGJNLCuuzD3EKMHBrCTC++Ig UIg3JbGyKrUoP76oNCe1+BCjD9AlE5mlRJPzgQGfVxJvaGxgbGhoaWhmamlqgENYSZy32SMl QEggPbEkNTs1tSC1CGYcEwenVAPjGd2fxWqabArHg62FAss2rN4xZ/GcjbHdGxLNzafH++io izTZCfV1cggtkji2ynTl51vLPn44Z6EUsPnbh4fblNIKzz7ouB6lxTH9keeEb5uWtJx+zVAv Yyu20Okfj+mBBP9oFfneia8zdYrMjjYvCT62Zzn38YlMt5UVvZIu5Uw13itY/fiCEktxRqKh FnNRcSIATqOeDVcCAAA= X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFvrMLMWRmVeSWpSXmKPExsVy+t9jAV3zGUsCDA7vl7S48vU9mwOjx/3u 40wBjFENjDYZqYkpqUUKqXnJ+SmZeem2St7B8c7xpmYGhrqGlhbmSgp5ibmptkouPgG6bpk5 QGOVFMoSc0qBQgGJxcVK+naYJoSGuOlawDRG6PqGBMH1GBmggYR1jBkrDj1nK1jPV7G6fw9b A2MPTxcjJ4eEgInE6auT2SBsMYkL99YD2VwcQgKLGCXW/DvPDuGsZ5KYNeULE0gVm4CqxMQV 98E6RARMJTomLWUBsZkFCiUW9jwFs4UFXCTe7JzC3MXIwcECVH9uqj1ImBcofPbxWhaIZQoS C+69ZZvAyL2AkWEVo2hqQXJBcVJ6rqFecWJucWleul5yfu4mRnDIPpPawbiyweIQowAHoxIP r8OPxQFCrIllxZW5hxglOJiVRHhfHAQK8aYkVlalFuXHF5XmpBYfYvQBWj6RWUo0OR8YT3kl 8YbGJmZGlkZmxibmxsY4hJXEeZs9UgKEBNITS1KzU1MLUotgxjFxcEo1MM6cEH72Ttz63nTz FVlR+Q1p2264Puadpxh6NU9xF0fpPo3lVb9+qmpM8njDnXHx4f+pKy1T+7Z8q/kgOKF3xcRT j17wJDRXKR7l/fy8RP735ciVV3eGPdiq6H99c5Df9w11Vba8whvMN5yYpWjr8D2kcf8N7T97 1njudi1NK/67tyjuwpGEgxZKLMUZiYZazEXFiQAt1nshhgIAAA== X-CFilter-Loop: Reflected Cc: kyungmin.park@samsung.com, sw0312.kim@samsung.com X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: dri-devel-bounces+patchwork-dri-devel=patchwork.kernel.org@lists.freedesktop.org Errors-To: dri-devel-bounces+patchwork-dri-devel=patchwork.kernel.org@lists.freedesktop.org This patch removes wait_for_vblank call from exynos_drm_encoder_plane_disable function and move it to exynos_drm_encoder_plane_commit function. Disabling dma channel to each plane doens't need vblank signal to update data to real hardware. But updating overlay data to real hardware does need vblank signal. Signed-off-by: Inki Dae Signed-off-by: Kyungmin Park --- drivers/gpu/drm/exynos/exynos_drm_encoder.c | 17 +++++++---------- 1 files changed, 7 insertions(+), 10 deletions(-) diff --git a/drivers/gpu/drm/exynos/exynos_drm_encoder.c b/drivers/gpu/drm/exynos/exynos_drm_encoder.c index 607231a..b284dea 100644 --- a/drivers/gpu/drm/exynos/exynos_drm_encoder.c +++ b/drivers/gpu/drm/exynos/exynos_drm_encoder.c @@ -473,6 +473,13 @@ void exynos_drm_encoder_plane_commit(struct drm_encoder *encoder, void *data) if (overlay_ops && overlay_ops->commit) overlay_ops->commit(manager->dev, zpos); + + /* + * wait for vblank interrupt + * - this makes user that overlay data are updated to real hardware. + */ + if (overlay_ops->wait_for_vblank) + overlay_ops->wait_for_vblank(manager->dev); } void exynos_drm_encoder_plane_enable(struct drm_encoder *encoder, void *data) @@ -505,14 +512,4 @@ void exynos_drm_encoder_plane_disable(struct drm_encoder *encoder, void *data) if (overlay_ops && overlay_ops->disable) overlay_ops->disable(manager->dev, zpos); - - /* - * wait for vblank interrupt - * - this makes sure that hardware overlay is disabled to avoid - * for the dma accesses to memory after gem buffer was released - * because the setting for disabling the overlay will be updated - * at vsync. - */ - if (overlay_ops->wait_for_vblank) - overlay_ops->wait_for_vblank(manager->dev); }