From patchwork Thu Jan 19 13:48:42 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Marek Szyprowski X-Patchwork-Id: 9525859 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 27248601AE for ; Thu, 19 Jan 2017 13:50:40 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 18D5C28111 for ; Thu, 19 Jan 2017 13:50:40 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 0D86E28517; Thu, 19 Jan 2017 13:50:40 +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 92FD328111 for ; Thu, 19 Jan 2017 13:50:39 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752679AbdASNui (ORCPT ); Thu, 19 Jan 2017 08:50:38 -0500 Received: from mailout2.w1.samsung.com ([210.118.77.12]:48118 "EHLO mailout2.w1.samsung.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752780AbdASNtr (ORCPT ); Thu, 19 Jan 2017 08:49:47 -0500 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 <0OK100GOZ51U4K70@mailout2.w1.samsung.com>; Thu, 19 Jan 2017 13:49:06 +0000 (GMT) Received: from eusmges4.samsung.com (unknown [203.254.199.244]) by eucas1p2.samsung.com (KnoxPortal) with ESMTP id 20170119134905eucas1p2ed82a062fa906c35bf3a1c996d58fa8a~bMGy3W_gr1689016890eucas1p2h; Thu, 19 Jan 2017 13:49:05 +0000 (GMT) Received: from eucas1p1.samsung.com ( [182.198.249.206]) by eusmges4.samsung.com (EUCPMTA) with SMTP id 43.6F.28517.1D3C0885; Thu, 19 Jan 2017 13:49:05 +0000 (GMT) Received: from eusmgms1.samsung.com (unknown [182.198.249.179]) by eucas1p1.samsung.com (KnoxPortal) with ESMTP id 20170119134904eucas1p1cc044892728a1716acc2f77f32180c42~bMGyMmps01053410534eucas1p1Y; Thu, 19 Jan 2017 13:49:04 +0000 (GMT) X-AuditID: cbfec7f4-f79716d000006f65-d2-5880c3d1a585 Received: from eusync1.samsung.com ( [203.254.199.211]) by eusmgms1.samsung.com (EUCPMTA) with SMTP id 51.31.06687.B04C0885; Thu, 19 Jan 2017 13:50:03 +0000 (GMT) Received: from AMDC2765.digital.local ([106.116.147.25]) by eusync1.samsung.com (Oracle Communications Messaging Server 7.0.5.31.0 64bit (built May 5 2014)) with ESMTPA id <0OK100BYG51LGB30@eusync1.samsung.com>; Thu, 19 Jan 2017 13:49:04 +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 v3 02/13] soc: samsung: pmu: Use of_device_get_match_data helper Date: Thu, 19 Jan 2017 14:48:42 +0100 Message-id: <1484833733-16082-3-git-send-email-m.szyprowski@samsung.com> X-Mailer: git-send-email 1.9.1 In-reply-to: <1484833733-16082-1-git-send-email-m.szyprowski@samsung.com> X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFrrLIsWRmVeSWpSXmKPExsWy7djPc7oXDzdEGBz/KmqxccZ6Vovz5zew W0z5s5zJYtP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C1zckSEmhLDGnFMgzMkADDs4B7sFK+nYJbhldr/cyFazgqvh2YgNrA+Mjji5GTg4JAROJ iR8msEDYYhIX7q1n62Lk4hASWMIo8ez4eRYIp4lJ4vLta6wgVWwChhJdb7vAqkQEmhklGpb0 gjnMAhOYJGZ+amACqRIWCJCYu385UIKDg0VAVWLuaWaQMK+Ah8Szu9vZINbJSZw8NhlsKKeA p8TUOU1gcSGgmiVLL7JOYORdwMiwilEktbQ4Nz232FCvODG3uDQvXS85P3cTIzDotx37uXkH 46WNwYcYBTgYlXh4O4rqI4RYE8uKK3MPMUpwMCuJ8NrsbYgQ4k1JrKxKLcqPLyrNSS0+xGgK dNNEZinR5HxgROaVxBuaGJpbGhoZW1iYGxkpifOWfLgSLiSQnliSmp2aWpBaBNPHxMEp1cDI uiXTpenzk+Q3OtINDhMOvtpy7aSb4e+Op7Ix/3Zwm7v8uFfv+c0rMJBDmPtiokzQ81cGs0Iv syXVhrTvMCyessZjyV+V6NLSmAdTGI2OP4qPc02N8yity/i0l4e7coZGmqqo7LmOZV2t/q+3 bPT4t1okf1Pueu0VF+Ido/12a+vM5XsVeViJpTgj0VCLuag4EQAHddFPkAIAAA== X-MTR: 20000000000000000@CPGS X-CMS-MailID: 20170119134904eucas1p1cc044892728a1716acc2f77f32180c42 X-Msg-Generator: CA X-Sender-IP: 182.198.249.179 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: 20170119134904eucas1p1cc044892728a1716acc2f77f32180c42 X-RootMTR: 20170119134904eucas1p1cc044892728a1716acc2f77f32180c42 References: <1484833733-16082-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 Reviewed-by: Tomasz Figa --- 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();