From patchwork Wed Feb 22 16:05:05 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andrzej Hajda X-Patchwork-Id: 9587081 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 12222600CA for ; Wed, 22 Feb 2017 16:05:25 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 0038A28678 for ; Wed, 22 Feb 2017 16:05:25 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id E93402867C; Wed, 22 Feb 2017 16:05:24 +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 966D828684 for ; Wed, 22 Feb 2017 16:05:24 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754749AbdBVQFY (ORCPT ); Wed, 22 Feb 2017 11:05:24 -0500 Received: from mailout3.w1.samsung.com ([210.118.77.13]:62620 "EHLO mailout3.w1.samsung.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753699AbdBVQFV (ORCPT ); Wed, 22 Feb 2017 11:05:21 -0500 Received: from eucas1p2.samsung.com (unknown [182.198.249.207]) by mailout3.w1.samsung.com (Oracle Communications Messaging Server 7.0.5.31.0 64bit (built May 5 2014)) with ESMTP id <0OLS00DKJA0UF680@mailout3.w1.samsung.com> for linux-samsung-soc@vger.kernel.org; Wed, 22 Feb 2017 16:05:19 +0000 (GMT) Received: from eusmges1.samsung.com (unknown [203.254.199.239]) by eucas1p1.samsung.com (KnoxPortal) with ESMTP id 20170222160518eucas1p1a5b579be23e34bad00de0acafad132a4~lp5bLFU--0110101101eucas1p1B; Wed, 22 Feb 2017 16:05:18 +0000 (GMT) Received: from eucas1p1.samsung.com ( [182.198.249.206]) by eusmges1.samsung.com (EUCPMTA) with SMTP id DA.63.16908.0C6BDA85; Wed, 22 Feb 2017 16:05:20 +0000 (GMT) Received: from eusmgms2.samsung.com (unknown [182.198.249.180]) by eucas1p1.samsung.com (KnoxPortal) with ESMTP id 20170222160517eucas1p1a254801abe01ae5ee77681ff4f955ba8~lp5agU9hf0645706457eucas1p1S; Wed, 22 Feb 2017 16:05:17 +0000 (GMT) X-AuditID: cbfec7ef-f79d26d00000420c-ef-58adb6c0dc6f Received: from eusync3.samsung.com ( [203.254.199.213]) by eusmgms2.samsung.com (EUCPMTA) with SMTP id 27.9A.10233.3C6BDA85; Wed, 22 Feb 2017 16:05:23 +0000 (GMT) Received: from AMDC2768.DIGITAL.local ([106.120.43.17]) by eusync3.samsung.com (Oracle Communications Messaging Server 7.0.5.31.0 64bit (built May 5 2014)) with ESMTPA id <0OLS00IUKA0QUK20@eusync3.samsung.com>; Wed, 22 Feb 2017 16:05:17 +0000 (GMT) From: Andrzej Hajda To: Inki Dae Cc: Andrzej Hajda , Bartlomiej Zolnierkiewicz , Marek Szyprowski , dri-devel@lists.freedesktop.org, linux-samsung-soc@vger.kernel.org, Krzysztof Kozlowski , Javier Martinez Canillas Subject: [PATCH 4/4] drm/exynos/decon5433: signal frame done interrupt at VSYNC Date: Wed, 22 Feb 2017 17:05:05 +0100 Message-id: <1487779505-4062-5-git-send-email-a.hajda@samsung.com> X-Mailer: git-send-email 2.7.4 In-reply-to: <1487779505-4062-1-git-send-email-a.hajda@samsung.com> X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFjrHIsWRmVeSWpSXmKPExsWy7djPc7oHtq2NMOicJ29xa905VouNM9az Wlz5+p7NYtL9CSwWb96uYbI4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ROJvT9PsELYYhIX7q1n62Lk 4hASWMIo8XvvQUYIp5FJ4te7lYwgVWwCmhJ/N99kA7FFBJQlVu1rZwcpYhbYwCRxt+8k2Chh AX+JbX+2sYPYLAKqEpf294HFeQWcJE7e2Q+1Tk7i5rlO5i5GDg5OAWeJRRctQcJCQCWvZy1l n8DIu4CRYRWjSGppcW56brGRXnFibnFpXrpecn7uJkZgWG879nPLDsaud8GHGAU4GJV4eA8s WhshxJpYVlyZe4hRgoNZSYT3/2KgEG9KYmVValF+fFFpTmrxIUZToJsmMkuJJucDYy6vJN7Q xNDc0tDI2MLC3MhISZx36ocr4UIC6YklqdmpqQWpRTB9TBycUg2MWlM/cVzdE7eCTeDHj0YG 5RTGJS0tivcUd92bM9PG8UWi0T+lB1f3MHxiiLG87SpSO//CxyOrDs91DP1hnpHan1CVvjS0 S0Px87yC3xlmwf53S055Syz6b7/nSuGyeAaZmCvhVxriA4Q7Ale12TnP8/wYyLD4QiTnftZz H1u2JYh6ntBb+eCREktxRqKhFnNRcSIArZ1AcYECAAA= X-MTR: 20000000000000000@CPGS X-CMS-MailID: 20170222160517eucas1p1a254801abe01ae5ee77681ff4f955ba8 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: 20170222160517eucas1p1a254801abe01ae5ee77681ff4f955ba8 X-RootMTR: 20170222160517eucas1p1a254801abe01ae5ee77681ff4f955ba8 References: <1487779505-4062-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 DECON in case of video mode generates interrupt by default at start of vertical back porch. As this interrupt is used to generate VBLANK events more optimal point is start of vertical front porch. Signed-off-by: Andrzej Hajda --- drivers/gpu/drm/exynos/exynos5433_drm_decon.c | 2 +- include/video/exynos5433_decon.h | 4 ++++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/exynos/exynos5433_drm_decon.c b/drivers/gpu/drm/exynos/exynos5433_drm_decon.c index bfa9396..2694b32 100644 --- a/drivers/gpu/drm/exynos/exynos5433_drm_decon.c +++ b/drivers/gpu/drm/exynos/exynos5433_drm_decon.c @@ -105,7 +105,7 @@ static int decon_enable_vblank(struct exynos_drm_crtc *crtc) if (ctx->out_type & IFTYPE_I80) val |= VIDINTCON0_FRAMEDONE; else - val |= VIDINTCON0_INTFRMEN; + val |= VIDINTCON0_INTFRMEN | VIDINTCON0_FRAMESEL_FP; writel(val, ctx->addr + DECON_VIDINTCON0); } diff --git a/include/video/exynos5433_decon.h b/include/video/exynos5433_decon.h index beefc62..2391b03 100644 --- a/include/video/exynos5433_decon.h +++ b/include/video/exynos5433_decon.h @@ -128,6 +128,10 @@ /* VIDINTCON0 */ #define VIDINTCON0_FRAMEDONE (1 << 17) +#define VIDINTCON0_FRAMESEL_BP (0 << 15) +#define VIDINTCON0_FRAMESEL_VS (1 << 15) +#define VIDINTCON0_FRAMESEL_AC (2 << 15) +#define VIDINTCON0_FRAMESEL_FP (3 << 15) #define VIDINTCON0_INTFRMEN (1 << 12) #define VIDINTCON0_INTEN (1 << 0)