From patchwork Thu Apr 26 11:51:25 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bartlomiej Zolnierkiewicz X-Patchwork-Id: 10365823 X-Patchwork-Delegate: eduardo.valentin@ti.com 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 00E1B601BE for ; Thu, 26 Apr 2018 11:55:14 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id E693528E33 for ; Thu, 26 Apr 2018 11:55:13 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id DB22228EA6; Thu, 26 Apr 2018 11:55:13 +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=-8.0 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,MAILING_LIST_MULTI,RCVD_IN_DNSWL_HI autolearn=unavailable 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 8EF1C28E33 for ; Thu, 26 Apr 2018 11:55:13 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756073AbeDZLwh (ORCPT ); Thu, 26 Apr 2018 07:52:37 -0400 Received: from mailout3.samsung.com ([203.254.224.33]:21334 "EHLO mailout3.samsung.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755529AbeDZLw0 (ORCPT ); Thu, 26 Apr 2018 07:52:26 -0400 Received: from epcas1p4.samsung.com (unknown [182.195.41.48]) by mailout3.samsung.com (KnoxPortal) with ESMTP id 20180426115224epoutp03564791e933951cfe799516979ba316e2~o_izpHeC02115921159epoutp03-; Thu, 26 Apr 2018 11:52:24 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 mailout3.samsung.com 20180426115224epoutp03564791e933951cfe799516979ba316e2~o_izpHeC02115921159epoutp03- DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=samsung.com; s=mail20170921; t=1524743544; bh=r3pD7yaRUCXNWHWS1aYleOTyFGorpbS4lnJRNfsTUwo=; h=From:To:Cc:Subject:Date:In-reply-to:References:From; b=iu3onD8vvsOjrvNxUsEjB94BmJWx0Ho4oG8dvwW7o0PJS4ZByj89DYcj4zvnz1wcb WRc6bxQE4nRjVOyKk9cqQf02WaukCBEFDmggMvhmcvP0U+JXF/h5X3rvxhqG1gs0aT j4J6zGlW7I+nLwMYiA7aIGpoUvMpRHeAl6iAb1rw= Received: from epsmges1p2.samsung.com (unknown [182.195.42.54]) by epcas1p4.samsung.com (KnoxPortal) with ESMTP id 20180426115224epcas1p4fb5ce2e9a465cd7979a0b0872fa1c495~o_izYmnyJ2714427144epcas1p4R; Thu, 26 Apr 2018 11:52:24 +0000 (GMT) Received: from epcas1p1.samsung.com ( [182.195.41.45]) by epsmges1p2.samsung.com (Symantec Messaging Gateway) with SMTP id 20.5B.04135.87DB1EA5; Thu, 26 Apr 2018 20:52:24 +0900 (KST) Received: from epsmgms2p1new.samsung.com (unknown [182.195.42.142]) by epcas1p3.samsung.com (KnoxPortal) with ESMTP id 20180426115224epcas1p3dde7044de7d11c7ec7a7411df1123552~o_izEp59K1255812558epcas1p3z; Thu, 26 Apr 2018 11:52:24 +0000 (GMT) X-AuditID: b6c32a36-b6dff70000001027-22-5ae1bd787411 Received: from epmmp2 ( [203.254.227.17]) by epsmgms2p1new.samsung.com (Symantec Messaging Gateway) with SMTP id 79.8C.03822.77DB1EA5; Thu, 26 Apr 2018 20:52:24 +0900 (KST) Received: from AMDC3058.DIGITAL.local ([106.120.53.102]) by mmp2.samsung.com (Oracle Communications Messaging Server 7.0.5.31.0 64bit (built May 5 2014)) with ESMTPA id <0P7S00GD7JMBQG00@mmp2.samsung.com>; Thu, 26 Apr 2018 20:52:23 +0900 (KST) From: Bartlomiej Zolnierkiewicz To: Eduardo Valentin Cc: Zhang Rui , linux-samsung-soc@vger.kernel.org, linux-pm@vger.kernel.org, linux-kernel@vger.kernel.org, b.zolnierkie@samsung.com Subject: [PATCH 10/18] thermal: exynos: move IRQs clearing to exynos_tmu_initialize() Date: Thu, 26 Apr 2018 13:51:25 +0200 Message-id: <1524743493-28113-11-git-send-email-b.zolnierkie@samsung.com> X-Mailer: git-send-email 1.9.1 In-reply-to: <1524743493-28113-1-git-send-email-b.zolnierkie@samsung.com> X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFlrBIsWRmVeSWpSXmKPExsWy7bCmrm7F3odRBmd2CFpsnLGe1WL+lWus Fpd3zWGz+Nx7hNFixvl9TBZPHvaxObB57Jx1l91j8Z6XTB59W1YxenzeJBfAEsVlk5Kak1mW WqRvl8CVsfX/NqaCpwIVDevPsjQw9vB1MXJwSAiYSFxbFtXFyMkhJLCDUeLyTakuRi4g+zuj xMTZ/xhBEiA1lx5PY4VIbGCUeHn+DxuE84tR4tGXa2wgVWwCVhIT21eBdYgIaEmcuLSdCaSI WWAOo8Ssht0sIAlhgXCJO4f3s4PYLAKqEk1H74M18Ap4SuydsJgdYp2cxMljk1lBbE6g+IUj TSwggyQE/rJKbGp/zwRR5CLRPH8vlC0s8er4FnaIf6QlLh21hahvZpT4tmMPM0TNBEaJPeuF IGxricPHL4ItYBbgk3j3tYcVopdXoqMNqsRD4mrLNWaIsKPE3vW8EA8D/dJ+9wXbBEapBYwM qxjFUguKc9NTiw0LjPSKE3OLS/PS9ZLzczcxguNPy2wH46JzPocYBTgYlXh4AxY+iBJiTSwr rsw9xCjBwawkwhvf+jBKiDclsbIqtSg/vqg0J7X4EKM0B4uSOO9TnzNRQgLpiSWp2ampBalF MFkmDk6pBsaolHsFQqbb2d7fexEpvzlmho/X1BtzVBrCJOY7ZLtE2P9h89aZtjPq/d/pZxfd 2vajc/FajchN95Zrndomn8HM+9b9bbfd9uDyV46f5FmlJpWa/b/rLKLju6UogsdjYyYb8/en Mwy/L0jaLtdjd1dwusqx6LQSqcDTC79sK1n2U91INspJ85MSS3FGoqEWc1FxIgDIdvcUuwIA AA== X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFmpkluLIzCtJLcpLzFFi42I5/e+xoG7F3odRBtc9LTbOWM9qMf/KNVaL y7vmsFl87j3CaDHj/D4miycP+9gc2Dx2zrrL7rF4z0smj74tqxg9Pm+SC2CJ4rJJSc3JLEst 0rdL4MrY+n8bU8FTgYqG9WdZGhh7+LoYOTkkBEwkLj2exgpiCwmsY5S48kehi5ELyP7FKLGs dw8zSIJNwEpiYvsqRhBbREBL4sSl7UwgRcwCcxglnq+YwwSSEBYIl7hzeD87iM0ioCrRdPQ+ WAOvgKfE3gmL2SG2yUmcPDYZbBsnUPzCkSYWiM0eEvf73rNNYORZwMiwilEytaA4Nz232KjA MC+1XK84Mbe4NC9dLzk/dxMjMGC2Hdbq28F4f0n8IUYBDkYlHt6AhQ+ihFgTy4orcw8xSnAw K4nwxrc+jBLiTUmsrEotyo8vKs1JLT7EKM3BoiTOezvvWKSQQHpiSWp2ampBahFMlomDU6qB sZ9Jvy+z5lzu7DmTLM68i+96W/ZtuyDH75cbOxfXTZ1ws/3a93a9g9Ptr6yVKmYQn8HmduDb 4gZuD86j03LWLzW8mWDYdXzHKcvjUa2+M1oU2v7oXuLzmbDDffNdYa6XNys37+13ivz2ZuF+ OSkO7w1awq+POO5c7LTikqLTtC9Vz3IXv3v++YASS3FGoqEWc1FxIgDfndeHFAIAAA== X-CMS-MailID: 20180426115224epcas1p3dde7044de7d11c7ec7a7411df1123552 X-Msg-Generator: CA CMS-TYPE: 101P X-CMS-RootMailID: 20180426115224epcas1p3dde7044de7d11c7ec7a7411df1123552 X-RootMTR: 20180426115224epcas1p3dde7044de7d11c7ec7a7411df1123552 References: <1524743493-28113-1-git-send-email-b.zolnierkie@samsung.com> Sender: linux-pm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-pm@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Move ->tmu_clear_irqs call from ->tmu_initialize method to exynos_tmu_initialize(). There should be no functional changes caused by this patch. Signed-off-by: Bartlomiej Zolnierkiewicz Reviewed-by: Daniel Lezcano --- drivers/thermal/samsung/exynos_tmu.c | 12 +++--------- 1 file changed, 3 insertions(+), 9 deletions(-) diff --git a/drivers/thermal/samsung/exynos_tmu.c b/drivers/thermal/samsung/exynos_tmu.c index 1664d37..82484c5 100644 --- a/drivers/thermal/samsung/exynos_tmu.c +++ b/drivers/thermal/samsung/exynos_tmu.c @@ -368,8 +368,10 @@ static int exynos_tmu_initialize(struct platform_device *pdev) status = readb(data->base + EXYNOS_TMU_REG_STATUS); if (!status) ret = -EBUSY; - else + else { data->tmu_initialize(pdev); + data->tmu_clear_irqs(data); + } clk_disable(data->clk); mutex_unlock(&data->lock); @@ -430,8 +432,6 @@ static void exynos4210_tmu_initialize(struct platform_device *pdev) writeb(temp - reference, data->base + EXYNOS4210_TMU_REG_TRIG_LEVEL0 + i * 4); } - - data->tmu_clear_irqs(data); } static void exynos4412_tmu_initialize(struct platform_device *pdev) @@ -486,8 +486,6 @@ static void exynos4412_tmu_initialize(struct platform_device *pdev) con = readl(data->base + EXYNOS_TMU_REG_CONTROL); con |= (1 << EXYNOS_TMU_THERM_TRIP_EN_SHIFT); writel(con, data->base + EXYNOS_TMU_REG_CONTROL); - - data->tmu_clear_irqs(data); } static void exynos5433_tmu_initialize(struct platform_device *pdev) @@ -571,8 +569,6 @@ static void exynos5433_tmu_initialize(struct platform_device *pdev) falling_threshold |= (threshold_code << j * 8); writel(falling_threshold, data->base + falling_reg_offset); } - - data->tmu_clear_irqs(data); } static void exynos7_tmu_initialize(struct platform_device *pdev) @@ -635,8 +631,6 @@ static void exynos7_tmu_initialize(struct platform_device *pdev) writel(falling_threshold, data->base + EXYNOS7_THD_TEMP_FALL7_6 + reg_off); } - - data->tmu_clear_irqs(data); } static void exynos4210_tmu_control(struct platform_device *pdev, bool on)