From patchwork Tue Apr 18 12:40:00 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andrzej Hajda X-Patchwork-Id: 9685481 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id E6AD46037E for ; Tue, 18 Apr 2017 12:40:23 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id D84202522B for ; Tue, 18 Apr 2017 12:40:23 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id CD35027D4A; Tue, 18 Apr 2017 12:40:23 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.9 required=2.0 tests=BAYES_00,RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 8827E28375 for ; Tue, 18 Apr 2017 12:40:21 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753212AbdDRMkU (ORCPT ); Tue, 18 Apr 2017 08:40:20 -0400 Received: from mailout2.w1.samsung.com ([210.118.77.12]:24193 "EHLO mailout2.w1.samsung.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753123AbdDRMkS (ORCPT ); Tue, 18 Apr 2017 08:40:18 -0400 Received: from eucas1p1.samsung.com (unknown [182.198.249.206]) by mailout2.w1.samsung.com (Oracle Communications Messaging Server 7.0.5.31.0 64bit (built May 5 2014)) with ESMTP id <0OOL00GCQV71W890@mailout2.w1.samsung.com> for linux-samsung-soc@vger.kernel.org; Tue, 18 Apr 2017 13:40:15 +0100 (BST) Received: from eusmges5.samsung.com (unknown [203.254.199.245]) by eucas1p1.samsung.com (KnoxPortal) with ESMTP id 20170418124014eucas1p188090d8dff8a16b028d42154aab26f7a~2flFqEHZY3235532355eucas1p1v; Tue, 18 Apr 2017 12:40:14 +0000 (GMT) Received: from eucas1p1.samsung.com ( [182.198.249.206]) by eusmges5.samsung.com (EUCPMTA) with SMTP id 70.80.25577.E2906F85; Tue, 18 Apr 2017 13:40:14 +0100 (BST) Received: from eusmgms2.samsung.com (unknown [182.198.249.180]) by eucas1p1.samsung.com (KnoxPortal) with ESMTP id 20170418124013eucas1p15b1db76e79fb76f825be90793525c9b3~2flE9uoRq1108411084eucas1p1n; Tue, 18 Apr 2017 12:40:13 +0000 (GMT) X-AuditID: cbfec7f5-f792f6d0000063e9-10-58f6092e3058 Received: from eusync1.samsung.com ( [203.254.199.211]) by eusmgms2.samsung.com (EUCPMTA) with SMTP id BB.39.20206.54906F85; Tue, 18 Apr 2017 13:40:37 +0100 (BST) Received: from AMDC2768.DIGITAL.local ([106.120.43.17]) by eusync1.samsung.com (Oracle Communications Messaging Server 7.0.5.31.0 64bit (built May 5 2014)) with ESMTPA id <0OOL006UZV6ZTM40@eusync1.samsung.com>; Tue, 18 Apr 2017 13:40:13 +0100 (BST) From: Andrzej Hajda To: Inki Dae Cc: Andrzej Hajda , Bartlomiej Zolnierkiewicz , Marek Szyprowski , dri-devel@lists.freedesktop.org, linux-samsung-soc@vger.kernel.org Subject: [PATCH 4/7] drm/exynos: propagate info about command mode from panel Date: Tue, 18 Apr 2017 14:40:00 +0200 Message-id: <1492519203-23537-5-git-send-email-a.hajda@samsung.com> X-Mailer: git-send-email 2.7.4 In-reply-to: <1492519203-23537-1-git-send-email-a.hajda@samsung.com> X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFtrDIsWRmVeSWpSXmKPExsWy7djPc7p6nN8iDLrbRSxurTvHarFxxnpW iytf37NZTLo/gcVixvl9TBZrj9xld2DzuN99nMmjb8sqRo/Pm+QCmKO4bFJSczLLUov07RK4 Mi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vzbsx3M5hVwlnh8 /ysTxDo5iZvnOsHinAIuEr3nTrOC2EJANevnnGScwMi7gJFhFaNIamlxbnpusZFecWJucWle ul5yfu4mRmDAbjv2c8sOxq53wYcYBTgYlXh4V+z7EiHEmlhWXJl7iFGCg1lJhHfdh68RQrwp iZVVqUX58UWlOanFhxhNgY6ayCwlmpwPjKa8knhDE0NzS0MjYwsLcyMjJXHeqR+uhAsJpCeW pGanphakFsH0MXFwSjUwTvZNXvhY+fGD3l3vzgQvi/b4EMUmeWDp/xexSr+CXx66xl7EFZoz y9D1pf9m40/+W3fpn78RcblpY06S7U7r02uX7Fp99tr3KS1bo+LnNz1m9U03DJzDxzkrKHcJ t+SdG6p1HonKsh+qfq2b3mR58ijvFUF/Hb3/7V+T+grOTbyb0LHRKr93rhJLcUaioRZzUXEi AI2O7m5uAgAA X-MTR: 20000000000000000@CPGS X-CMS-MailID: 20170418124013eucas1p15b1db76e79fb76f825be90793525c9b3 X-Msg-Generator: CA X-Sender-IP: 182.198.249.180 X-Local-Sender: =?UTF-8?B?QW5kcnplaiBIYWpkYRtTUlBPTC1LZXJuZWwgKFRQKRvsgrw=?= =?UTF-8?B?7ISx7KCE7J6QG1NlbmlvciBTb2Z0d2FyZSBFbmdpbmVlcg==?= X-Global-Sender: =?UTF-8?B?QW5kcnplaiBIYWpkYRtTUlBPTC1LZXJuZWwgKFRQKRtTYW1z?= =?UTF-8?B?dW5nIEVsZWN0cm9uaWNzG1NlbmlvciBTb2Z0d2FyZSBFbmdpbmVlcg==?= X-Sender-Code: =?UTF-8?B?QzEwG0VIURtDMTBDRDAyQ0QwMjczOTI=?= CMS-TYPE: 201P X-HopCount: 7 X-CMS-RootMailID: 20170418124013eucas1p15b1db76e79fb76f825be90793525c9b3 X-RootMTR: 20170418124013eucas1p15b1db76e79fb76f825be90793525c9b3 References: <1492519203-23537-1-git-send-email-a.hajda@samsung.com> Sender: linux-samsung-soc-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-samsung-soc@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP mipi_dsi framework provides information about panel's mode of work. This info should be propagated upstream to configure all elements of the pipeline. As CRTC is the common nominator of the pipeline we can put such info into its structures. Signed-off-by: Andrzej Hajda --- drivers/gpu/drm/exynos/exynos_drm_drv.h | 1 + drivers/gpu/drm/exynos/exynos_drm_dsi.c | 2 ++ 2 files changed, 3 insertions(+) diff --git a/drivers/gpu/drm/exynos/exynos_drm_drv.h b/drivers/gpu/drm/exynos/exynos_drm_drv.h index 527bf1d..96b9d49 100644 --- a/drivers/gpu/drm/exynos/exynos_drm_drv.h +++ b/drivers/gpu/drm/exynos/exynos_drm_drv.h @@ -165,6 +165,7 @@ struct exynos_drm_crtc { const struct exynos_drm_crtc_ops *ops; void *ctx; struct exynos_drm_clk *pipe_clk; + bool i80_mode : 1; }; static inline void exynos_drm_pipe_clk_enable(struct exynos_drm_crtc *crtc, diff --git a/drivers/gpu/drm/exynos/exynos_drm_dsi.c b/drivers/gpu/drm/exynos/exynos_drm_dsi.c index 515090f..79df1c9 100644 --- a/drivers/gpu/drm/exynos/exynos_drm_dsi.c +++ b/drivers/gpu/drm/exynos/exynos_drm_dsi.c @@ -1545,6 +1545,8 @@ static int exynos_dsi_host_attach(struct mipi_dsi_host *host, drm_panel_attach(dsi->panel, &dsi->connector); dsi->connector.status = connector_status_connected; } + exynos_drm_crtc_get_by_type(drm, EXYNOS_DISPLAY_TYPE_LCD)->i80_mode = + !(dsi->mode_flags & MIPI_DSI_MODE_VIDEO); mutex_unlock(&drm->mode_config.mutex);