From patchwork Tue Jan 17 12:44:33 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Marek Szyprowski X-Patchwork-Id: 9520705 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 1A37B6020A for ; Tue, 17 Jan 2017 12:46:10 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id F3A452853D for ; Tue, 17 Jan 2017 12:46:09 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id E69CE28545; Tue, 17 Jan 2017 12:46:09 +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 84C6628542 for ; Tue, 17 Jan 2017 12:46:09 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751196AbdAQMqH (ORCPT ); Tue, 17 Jan 2017 07:46:07 -0500 Received: from mailout3.w1.samsung.com ([210.118.77.13]:63732 "EHLO mailout3.w1.samsung.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750817AbdAQMqC (ORCPT ); Tue, 17 Jan 2017 07:46:02 -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 <0OJX009PSCQZH360@mailout3.w1.samsung.com>; Tue, 17 Jan 2017 12:44:59 +0000 (GMT) Received: from eusmges2.samsung.com (unknown [203.254.199.241]) by eucas1p2.samsung.com (KnoxPortal) with ESMTP id 20170117124458eucas1p2987386e1f498ff6bd75a9b8f56bcbb63~aj8PjoXJv0755807558eucas1p2D; Tue, 17 Jan 2017 12:44:58 +0000 (GMT) Received: from eucas1p1.samsung.com ( [182.198.249.206]) by eusmges2.samsung.com (EUCPMTA) with SMTP id 0C.B6.30614.AC11E785; Tue, 17 Jan 2017 12:44:58 +0000 (GMT) Received: from eusmgms2.samsung.com (unknown [182.198.249.180]) by eucas1p1.samsung.com (KnoxPortal) with ESMTP id 20170117124457eucas1p120dac823e1cd08421cb8d7411a9eebbd~aj8O3ICTo2826728267eucas1p1c; Tue, 17 Jan 2017 12:44:57 +0000 (GMT) X-AuditID: cbfec7f1-f793f6d000007796-24-587e11ca334f Received: from eusync2.samsung.com ( [203.254.199.212]) by eusmgms2.samsung.com (EUCPMTA) with SMTP id D2.E4.10233.4C11E785; Tue, 17 Jan 2017 12:44:52 +0000 (GMT) Received: from AMDC2765.digital.local ([106.116.147.25]) by eusync2.samsung.com (Oracle Communications Messaging Server 7.0.5.31.0 64bit (built May 5 2014)) with ESMTPA id <0OJX00GNRCQPHB20@eusync2.samsung.com>; Tue, 17 Jan 2017 12:44:57 +0000 (GMT) From: Marek Szyprowski To: linux-gpio@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-pm@vger.kernel.org, linux-samsung-soc@vger.kernel.org Cc: Marek Szyprowski , Sylwester Nawrocki , Krzysztof Kozlowski , Linus Walleij , Tomasz Figa , Bartlomiej Zolnierkiewicz Subject: [PATCH v2 02/13] soc: samsung: pmu: Use of_device_get_match_data helper Date: Tue, 17 Jan 2017 13:44:33 +0100 Message-id: <1484657084-26227-3-git-send-email-m.szyprowski@samsung.com> X-Mailer: git-send-email 1.9.1 In-reply-to: <1484657084-26227-1-git-send-email-m.szyprowski@samsung.com> X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFrrLIsWRmVeSWpSXmKPExsWy7djPc7qnBOsiDGYdkLTYOGM9q8X58xvY Lab8W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SEmhLDGnFMgzMkADDs4B7sFK+nYJbhn9ayewFnzjrHiy+A1LA+NWji5GTg4JAROJ MzcnsUHYYhIX7q0Hsrk4hASWMErcPNLPDpIQEmhikphyUB3EZhMwlOh62wVWJCLQzCjRsKQX zGEWmMAkMfNTA1MXIweHsECAxIYDtSANLAKqEm1Hj7KC2LwCHhJd2/pZILbJSZw8Nhkszing KfHj53omiGUeEufv72OdwMi7gJFhFaNIamlxbnpusZFecWJucWleul5yfu4mRmDIbzv2c8sO xq53wYcYBTgYlXh4nW7XRAixJpYVV+YeYpTgYFYS4Z0rUBchxJuSWFmVWpQfX1Sak1p8iNEU 6KiJzFKiyfnAeMwriTc0MTS3NDQytrAwNzJSEued+uFKuJBAemJJanZqakFqEUwfEwenVAPj UmOmpEqViBvvn3b9uNKwJijCaBvPeaf9pvkV1x5+eLr5w7aNQskbNXl602uVOv5Jr8p95pbx VWWqzC37lq22ab9Oc1gVf4x1Ns7mdFqR4TPRs85n69rlzK1LmX3k2H0qBKKinE6+ylypGWKm 1/lNtn1Rd/f1mVmuXMvvcv7c+ChPLkuNM1OJpTgj0VCLuag4EQDK5A6gjwIAAA== X-MTR: 20000000000000000@CPGS X-CMS-MailID: 20170117124457eucas1p120dac823e1cd08421cb8d7411a9eebbd X-Msg-Generator: CA X-Sender-IP: 182.198.249.180 X-Local-Sender: =?UTF-8?B?TWFyZWsgU3p5cHJvd3NraRtTUlBPTC1LZXJuZWwgKFRQKRs=?= =?UTF-8?B?7IK87ISx7KCE7J6QG1NlbmlvciBTb2Z0d2FyZSBFbmdpbmVlcg==?= X-Global-Sender: =?UTF-8?B?TWFyZWsgU3p5cHJvd3NraRtTUlBPTC1LZXJuZWwgKFRQKRtT?= =?UTF-8?B?YW1zdW5nIEVsZWN0cm9uaWNzG1NlbmlvciBTb2Z0d2FyZSBFbmdpbmVlcg==?= X-Sender-Code: =?UTF-8?B?QzEwG0VIURtDMTBDRDAyQ0QwMjczOTI=?= CMS-TYPE: 201P X-HopCount: 7 X-CMS-RootMailID: 20170117124457eucas1p120dac823e1cd08421cb8d7411a9eebbd X-RootMTR: 20170117124457eucas1p120dac823e1cd08421cb8d7411a9eebbd References: <1484657084-26227-1-git-send-email-m.szyprowski@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 Replace custom code with generic helper to retrieve driver data. Signed-off-by: Marek Szyprowski --- drivers/soc/samsung/exynos-pmu.c | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/drivers/soc/samsung/exynos-pmu.c b/drivers/soc/samsung/exynos-pmu.c index 5c269bf23210..1f914e63dcc6 100644 --- a/drivers/soc/samsung/exynos-pmu.c +++ b/drivers/soc/samsung/exynos-pmu.c @@ -11,6 +11,7 @@ #include #include +#include #include #include #include @@ -105,7 +106,6 @@ struct regmap *exynos_get_pmu_regmap(void) static int exynos_pmu_probe(struct platform_device *pdev) { - const struct of_device_id *match; struct device *dev = &pdev->dev; struct resource *res; @@ -122,10 +122,7 @@ static int exynos_pmu_probe(struct platform_device *pdev) return -ENOMEM; } pmu_context->dev = dev; - - match = of_match_node(exynos_pmu_of_device_ids, dev->of_node); - - pmu_context->pmu_data = match->data; + pmu_context->pmu_data = of_device_get_match_data(dev); if (pmu_context->pmu_data->pmu_init) pmu_context->pmu_data->pmu_init();