From patchwork Wed Oct 1 06:19:13 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: YoungJun Cho X-Patchwork-Id: 5009841 Return-Path: X-Original-To: patchwork-dri-devel@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork1.web.kernel.org (Postfix) with ESMTP id 8F6F29F375 for ; Wed, 1 Oct 2014 06:19:31 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id D315E20259 for ; Wed, 1 Oct 2014 06:19:30 +0000 (UTC) Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) by mail.kernel.org (Postfix) with ESMTP id F25C020220 for ; Wed, 1 Oct 2014 06:19:29 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 353C96E2C0; Tue, 30 Sep 2014 23:19:29 -0700 (PDT) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from mailout4.samsung.com (mailout4.samsung.com [203.254.224.34]) by gabe.freedesktop.org (Postfix) with ESMTP id 82C4F6E2CB for ; Tue, 30 Sep 2014 23:19:24 -0700 (PDT) Received: from epcpsbgr4.samsung.com (u144.gpu120.samsung.co.kr [203.254.230.144]) by mailout4.samsung.com (Oracle Communications Messaging Server 7u4-24.01 (7.0.4.24.0) 64bit (built Nov 17 2011)) with ESMTP id <0NCR0055D5K5MY40@mailout4.samsung.com> for dri-devel@lists.freedesktop.org; Wed, 01 Oct 2014 15:19:18 +0900 (KST) Received: from epcpsbgm2.samsung.com ( [203.254.230.46]) by epcpsbgr4.samsung.com (EPCPMTA) with SMTP id B7.60.18167.5EC9B245; Wed, 01 Oct 2014 15:19:17 +0900 (KST) X-AuditID: cbfee690-f79ab6d0000046f7-cc-542b9ce553ff Received: from epmmp2 ( [203.254.227.17]) by epcpsbgm2.samsung.com (EPCPMTA) with SMTP id 39.C1.09430.5EC9B245; Wed, 01 Oct 2014 15:19:17 +0900 (KST) Received: from localhost.localdomain ([10.252.75.90]) by mmp2.samsung.com (Oracle Communications Messaging Server 7u4-24.01 (7.0.4.24.0) 64bit (built Nov 17 2011)) with ESMTPA id <0NCR002UR5K1JBD0@mmp2.samsung.com>; Wed, 01 Oct 2014 15:19:17 +0900 (KST) From: YoungJun Cho To: airlied@linux.ie, dri-devel@lists.freedesktop.org Subject: [PATCH 7/7] drm/exynos: dsi: move DSIM_STATE_ENABLED set position Date: Wed, 01 Oct 2014 15:19:13 +0900 Message-id: <1412144353-13114-8-git-send-email-yj44.cho@samsung.com> X-Mailer: git-send-email 1.9.0 In-reply-to: <1412144353-13114-1-git-send-email-yj44.cho@samsung.com> References: <1412144353-13114-1-git-send-email-yj44.cho@samsung.com> X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFrrELMWRmVeSWpSXmKPExsVy+t8zPd2nc7RDDPZNtba4te4cq0XvuZNM Fle+vmezmHR/AovFi3sXWSzONr1ht5gx+SWbA7vH9m8PWD3udx9n8ujbsooxgDmKyyYlNSez LLVI3y6BK+PCsousBc3cFZMXzGRpYFzF2cXIySEhYCLx8PRSZghbTOLCvfVsXYxcHEICyxgl jrY1MsEUfVz2nR0iMZ1RYv+f51BOK5PEg63n2UCq2AQ0JZ5/3MEKYosImEp0TFrKAmIzC1RL LJ44F2ySsICXxNcTB8DqWQRUJZ49nQJm8wq4SLT87WGH2CYnMeX3AjCbU8BVYurZU0DncQAt c5GYPlMRZK+EQDe7xJTTy1gg5ghIfJt8iAWkRkJAVmLTAahvJCUOrrjBMoFReAEjwypG0dSC 5ILipPQiE73ixNzi0rx0veT83E2MkKCesIPx3gHrQ4wCHIxKPLwKCdohQqyJZcWVuYcYTYE2 TGSWEk3OB8ZOXkm8obGZkYWpiamxkbmlmZI472upn8FCAumJJanZqakFqUXxRaU5qcWHGJk4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CAAA= DLP-Filter: Pass X-MTR: 20000000000000000@CPGS X-CFilter-Loop: Reflected Cc: a.hajda@samsung.com, kyungmin.park@samsung.com, sw0312.kim@samsung.com X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.15 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.8 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_MED, 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 The command mode panel should draw image earlier than the display on command execution to prevent showing garbage GRAM screen data. So should set dsi->state as DSIM_STATE_ENABLED between calling exynos_dsi_set_display_enable() and drm_panel_enable() to transmit image data before executing display on command. And moves the display on command execution routine from prepare() to enable() in drm_panel_funcs also. Signed-off-by: YoungJun Cho Acked-by: Inki Dae Acked-by: Kyungmin Park --- drivers/gpu/drm/exynos/exynos_drm_dsi.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/exynos/exynos_drm_dsi.c b/drivers/gpu/drm/exynos/exynos_drm_dsi.c index ded69df..f304a20 100644 --- a/drivers/gpu/drm/exynos/exynos_drm_dsi.c +++ b/drivers/gpu/drm/exynos/exynos_drm_dsi.c @@ -1366,16 +1366,17 @@ static int exynos_dsi_enable(struct exynos_dsi *dsi) exynos_dsi_set_display_mode(dsi); exynos_dsi_set_display_enable(dsi, true); + dsi->state |= DSIM_STATE_ENABLED; + ret = drm_panel_enable(dsi->panel); if (ret < 0) { + dsi->state &= ~DSIM_STATE_ENABLED; exynos_dsi_set_display_enable(dsi, false); drm_panel_unprepare(dsi->panel); exynos_dsi_poweroff(dsi); return ret; } - dsi->state |= DSIM_STATE_ENABLED; - return 0; }