From patchwork Wed Apr 5 07:28:34 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andrzej Hajda X-Patchwork-Id: 9663137 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 7501060353 for ; Wed, 5 Apr 2017 07:28:57 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 667BE284D5 for ; Wed, 5 Apr 2017 07:28:57 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 59EE728535; Wed, 5 Apr 2017 07:28:57 +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 F27EF284D5 for ; Wed, 5 Apr 2017 07:28:56 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753980AbdDEH24 (ORCPT ); Wed, 5 Apr 2017 03:28:56 -0400 Received: from mailout4.w1.samsung.com ([210.118.77.14]:14477 "EHLO mailout4.w1.samsung.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753993AbdDEH2y (ORCPT ); Wed, 5 Apr 2017 03:28:54 -0400 Received: from eucas1p1.samsung.com (unknown [182.198.249.206]) by mailout4.w1.samsung.com (Oracle Communications Messaging Server 7.0.5.31.0 64bit (built May 5 2014)) with ESMTP id <0ONX00JZTE3WD410@mailout4.w1.samsung.com> for linux-samsung-soc@vger.kernel.org; Wed, 05 Apr 2017 08:28:45 +0100 (BST) Received: from eusmges4.samsung.com (unknown [203.254.199.244]) by eucas1p1.samsung.com (KnoxPortal) with ESMTP id 20170405072844eucas1p1b1c2eec1ec8a51eb39a6dd72c5d090e9~yb8ZyLhGY3206832068eucas1p1J; Wed, 5 Apr 2017 07:28:44 +0000 (GMT) Received: from eucas1p2.samsung.com ( [182.198.249.207]) by eusmges4.samsung.com (EUCPMTA) with SMTP id FD.A9.04729.CAC94E85; Wed, 5 Apr 2017 08:28:44 +0100 (BST) Received: from eusmgms1.samsung.com (unknown [182.198.249.179]) by eucas1p1.samsung.com (KnoxPortal) with ESMTP id 20170405072843eucas1p19e426556ce611b8c28715dd648478458~yb8ZAConn2215422154eucas1p1W; Wed, 5 Apr 2017 07:28:43 +0000 (GMT) X-AuditID: cbfec7f4-f79806d000001279-0a-58e49cac4282 Received: from eusync3.samsung.com ( [203.254.199.213]) by eusmgms1.samsung.com (EUCPMTA) with SMTP id C2.4F.17452.22D94E85; Wed, 5 Apr 2017 08:30:42 +0100 (BST) 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 <0ONX000HIE3TW560@eusync3.samsung.com>; Wed, 05 Apr 2017 08:28:43 +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 6/9] drm/exynos/decon5433: kill BIT_CLKS_ENABLED flag Date: Wed, 05 Apr 2017 09:28:34 +0200 Message-id: <1491377317-8042-7-git-send-email-a.hajda@samsung.com> X-Mailer: git-send-email 2.7.4 In-reply-to: <1491377317-8042-1-git-send-email-a.hajda@samsung.com> X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFtrNIsWRmVeSWpSXmKPExsWy7djP87pr5jyJMNi2RdDi1rpzrBYbZ6xn tbjy9T2bxaT7E1gsZpzfx2Sx9shddgc2j/vdx5k8+rasYvT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ngCqNE+7cudpCEsICrxK0P38FsFgFViSfNS8EG8Qo4SfQ1 XGeG2CYncfNcJ5jNKeAscWbHZTaIZU4SrY2vWSYw8i5gZFjFKJJaWpybnltsqFecmFtcmpeu l5yfu4kRGKzbjv3cvIPx0sbgQ4wCHIxKPLwV0x5HCLEmlhVX5h5ilOBgVhLh/TH9SYQQb0pi ZVVqUX58UWlOavEhRlOgoyYyS4km5wMjKa8k3tDE0NzS0MjYwsLcyEhJnLfkw5VwIYH0xJLU 7NTUgtQimD4mDk6pBsZpRv0fc7RaFmyV3nVTcPGKEkb3RrX+IyLTWv//eS2gtcWMx+XcnSfn 84MyDk3k9wydG1+sd/bE5ie/OT+u5hZJVA44vUL6ufOe9l4xrq1bWzkfZvherPIylHq1b96V lZM2/uJJOsLZpvVxxaxTryorvH9FfuWQCIja/97+9fkXBzjzHji3+mspsRRnJBpqMRcVJwIA BfrDcmwCAAA= X-MTR: 20000000000000000@CPGS X-CMS-MailID: 20170405072843eucas1p19e426556ce611b8c28715dd648478458 X-Msg-Generator: CA X-Sender-IP: 182.198.249.179 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: 20170405072843eucas1p19e426556ce611b8c28715dd648478458 X-RootMTR: 20170405072843eucas1p19e426556ce611b8c28715dd648478458 References: <1491377317-8042-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 The flag was used to check if IRQ handlers can touch HW. Since driver enables IRQs only if hardware is enabled the flag becomes redundant. Signed-off-by: Andrzej Hajda --- drivers/gpu/drm/exynos/exynos5433_drm_decon.c | 12 +----------- 1 file changed, 1 insertion(+), 11 deletions(-) diff --git a/drivers/gpu/drm/exynos/exynos5433_drm_decon.c b/drivers/gpu/drm/exynos/exynos5433_drm_decon.c index dc2e69a..2629a59 100644 --- a/drivers/gpu/drm/exynos/exynos5433_drm_decon.c +++ b/drivers/gpu/drm/exynos/exynos5433_drm_decon.c @@ -48,7 +48,6 @@ static const char * const decon_clks_name[] = { }; enum decon_flag_bits { - BIT_CLKS_ENABLED, BIT_WIN_UPDATED, BIT_SUSPENDED }; @@ -486,8 +485,6 @@ static void decon_enable(struct exynos_drm_crtc *crtc) exynos_drm_pipe_clk_enable(crtc, true); - set_bit(BIT_CLKS_ENABLED, &ctx->flags); - decon_swreset(ctx); decon_commit(ctx->crtc); @@ -515,8 +512,6 @@ static void decon_disable(struct exynos_drm_crtc *crtc) decon_swreset(ctx); - clear_bit(BIT_CLKS_ENABLED, &ctx->flags); - exynos_drm_pipe_clk_enable(crtc, false); pm_runtime_put_sync(ctx->dev); @@ -528,8 +523,7 @@ static irqreturn_t decon_te_irq_handler(int irq, void *dev_id) { struct decon_context *ctx = dev_id; - if (!test_bit(BIT_CLKS_ENABLED, &ctx->flags) || - (ctx->out_type & I80_HW_TRG)) + if (ctx->out_type & I80_HW_TRG) return IRQ_HANDLED; decon_set_bits(ctx, DECON_TRIGCON, TRIGCON_SWTRIGCMD, ~0); @@ -654,9 +648,6 @@ static irqreturn_t decon_irq_handler(int irq, void *dev_id) struct decon_context *ctx = dev_id; u32 val; - if (!test_bit(BIT_CLKS_ENABLED, &ctx->flags)) - goto out; - val = readl(ctx->addr + DECON_VIDINTCON1); val &= VIDINTCON1_INTFRMDONEPEND | VIDINTCON1_INTFRMPEND; @@ -672,7 +663,6 @@ static irqreturn_t decon_irq_handler(int irq, void *dev_id) decon_handle_vblank(ctx); } -out: return IRQ_HANDLED; }