From patchwork Tue Jan 17 12:44:31 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Marek Szyprowski X-Patchwork-Id: 91625 Delivered-To: patch@linaro.org Received: by 10.140.20.99 with SMTP id 90csp470115qgi; Tue, 17 Jan 2017 04:45:27 -0800 (PST) X-Received: by 10.99.176.14 with SMTP id h14mr46037991pgf.22.1484657127666; Tue, 17 Jan 2017 04:45:27 -0800 (PST) Return-Path: Received: from bombadil.infradead.org (bombadil.infradead.org. [2001:1868:205::9]) by mx.google.com with ESMTPS id p17si24821503pgi.67.2017.01.17.04.45.27 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 17 Jan 2017 04:45:27 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-arm-kernel-bounces+patch=linaro.org@lists.infradead.org designates 2001:1868:205::9 as permitted sender) client-ip=2001:1868:205::9; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-arm-kernel-bounces+patch=linaro.org@lists.infradead.org designates 2001:1868:205::9 as permitted sender) smtp.mailfrom=linux-arm-kernel-bounces+patch=linaro.org@lists.infradead.org Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.87 #1 (Red Hat Linux)) id 1cTT8f-0000oZ-My; Tue, 17 Jan 2017 12:45:25 +0000 Received: from mailout2.w1.samsung.com ([210.118.77.12]) by bombadil.infradead.org with esmtps (Exim 4.87 #1 (Red Hat Linux)) id 1cTT8b-0007tf-Cx for linux-arm-kernel@lists.infradead.org; Tue, 17 Jan 2017 12:45:23 +0000 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 <0OJX0042FCQVQH70@mailout2.w1.samsung.com> for linux-arm-kernel@lists.infradead.org; Tue, 17 Jan 2017 12:44:55 +0000 (GMT) Received: from eusmges1.samsung.com (unknown [203.254.199.239]) by eucas1p2.samsung.com (KnoxPortal) with ESMTP id 20170117124454eucas1p28ee3939196499fa7661b4f12047eb373~aj8LwEuyD0769107691eucas1p2O; Tue, 17 Jan 2017 12:44:54 +0000 (GMT) Received: from eucas1p2.samsung.com ( [182.198.249.207]) by eusmges1.samsung.com (EUCPMTA) with SMTP id 53.57.16908.8C11E785; Tue, 17 Jan 2017 12:44:56 +0000 (GMT) Received: from eusmgms1.samsung.com (unknown [182.198.249.179]) by eucas1p1.samsung.com (KnoxPortal) with ESMTP id 20170117124453eucas1p1b812596939db4c4f3298b941555eb05a~aj8K9y9Zp2833328333eucas1p1g; Tue, 17 Jan 2017 12:44:53 +0000 (GMT) X-AuditID: cbfec7ef-f79d26d00000420c-88-587e11c8afee Received: from eusync2.samsung.com ( [203.254.199.212]) by eusmgms1.samsung.com (EUCPMTA) with SMTP id CE.95.06687.EF11E785; Tue, 17 Jan 2017 12:45:50 +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:53 +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 Subject: [PATCH v2 00/13] Move pad retention control to Exynos pin controller driver Date: Tue, 17 Jan 2017 13:44:31 +0100 Message-id: <1484657084-26227-1-git-send-email-m.szyprowski@samsung.com> X-Mailer: git-send-email 1.9.1 X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFjrLIsWRmVeSWpSXmKPExsWy7djP87onBOsiDJ6vMbPYOGM9q8X58xvY Lab8Wc5ksenxNVaLzfP/MFp87j3CaDHj/D4mi7VH7rJbHH7TzmqxatcfRgcuj52z7rJ7bFrV yeZx59oeNo/NS+o9+rasYvT4vEkugC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wFCi620XWJWIQDOjRMOS XjCHWWACk8TMTxBVwgJhEpvXb2cEsVkEVCV+rlzGDGLzCnhInJ+5jQVin5zEyWOTWScwci9g ZFjFKJJaWpybnltsqFecmFtcmpeul5yfu4kRGMLbjv3cvIPx0sbgQ4wCHIxKPLwOt2sihFgT y4orcw8xSnAwK4nwzhWoixDiTUmsrEotyo8vKs1JLT7EaAq0fCKzlGhyPjC+8kriDU0MzS0N jYwtLMyNjJTEeUs+XAkXEkhPLEnNTk0tSC2C6WPi4JRqYCxlOymQ9OaNq6z7s4oPi1wy3c/m yP12F7/n9P7I+r877UXUvt2tLLiqtoNRU6Ht9UW7PgWd9//7l3+8VvRV+4ViwY97XQGu+dlX Tle9YpoqvZf12MSGi5Ju9YLyzt5Zm45tW1f9/kDaIgdVmf/3O+dNXDT5UsIOZsusGqHtT5ay 8DhyxHcFMiqxFGckGmoxFxUnAgDvfGExdwIAAA== X-MTR: 20000000000000000@CPGS X-CMS-MailID: 20170117124453eucas1p1b812596939db4c4f3298b941555eb05a X-Msg-Generator: CA X-Sender-IP: 182.198.249.179 X-Local-Sender: =?utf-8?q?Marek_Szyprowski=1BSRPOL-Kernel_=28TP=29=1B?= =?utf-8?b?7IK87ISx7KCE7J6QG1NlbmlvciBTb2Z0d2FyZSBFbmdpbmVlcg==?= X-Global-Sender: =?utf-8?q?Marek_Szyprowski=1BSRPOL-Kernel_=28TP=29=1BSam?= =?utf-8?q?sung_Electronics=1BSenior_Software_Engineer?= X-Sender-Code: =?utf-8?q?C10=1BEHQ=1BC10CD02CD027392?= CMS-TYPE: 201P X-HopCount: 7 X-CMS-RootMailID: 20170117124453eucas1p1b812596939db4c4f3298b941555eb05a X-RootMTR: 20170117124453eucas1p1b812596939db4c4f3298b941555eb05a References: X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20170117_044521_600699_D5D76E5F X-CRM114-Status: GOOD ( 19.69 ) X-Spam-Score: -10.1 (----------) X-Spam-Report: SpamAssassin version 3.4.1 on bombadil.infradead.org summary: Content analysis details: (-10.1 points) pts rule name description ---- ---------------------- -------------------------------------------------- -5.0 RCVD_IN_DNSWL_HI RBL: Sender listed at http://www.dnswl.org/, high trust [210.118.77.12 listed in list.dnswl.org] -0.0 RCVD_IN_MSPIKE_H3 RBL: Good reputation (+3) [210.118.77.12 listed in wl.mailspike.net] -3.2 RP_MATCHES_RCVD Envelope sender domain matches handover relay domain -0.0 SPF_HELO_PASS SPF: HELO matches SPF record -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] -0.0 RCVD_IN_MSPIKE_WL Mailspike good senders X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Bartlomiej Zolnierkiewicz , Linus Walleij , Tomasz Figa , Krzysztof Kozlowski , Sylwester Nawrocki , Marek Szyprowski MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patch=linaro.org@lists.infradead.org Hello, This patchset is a follow-up of my work on adding runtime PM support to Exynos pin controller driver: http://www.spinics.net/lists/arm-kernel/msg550161.html Runtime PM support itself needs a bit more discussion, so lets first focus on the prerequisites. In case of Exynos pin controller driver it is a pad retention control. In current code it was handled by machine and PMU code and had no relation to what pin controller driver does. This patch series moves pad retention control to pin controller driver. While implementing it, I also did a little cleanup of both Exynos PMU and pin controller drivers. Exynos PMU driver now provides a convenient function to get PMU regmap from other Exynos drivers. Patch #1 provides a new interface to get Exynos PMU regmap, which is used by the patch #11. Patches 2-10 are additional cleanups to the code I was modyfying. Patches 10-12 implements the move of retention control and patch #13 is another cleanup, which is possible after removing dependency to platform PM code. Patches are based on linux-next from 2017.01.16 with Exynos4415 support removal patch applied: https://lkml.org/lkml/2017/1/14/137 Changelog: v2: - reworked exynos_get_pmu_regmap() function and moved to Exynos PMU driver, now it doesn't depend on driver probe order thus doesn't need to defer probing of pinctrl driver if PMU has not yet been probed - collected Acks, minor fixes according to review comments v1: https://www.spinics.net/lists/arm-kernel/msg554487.html - removed the need to add PMU phandles to all pin controller nodes, so old DTBs are properly supported. This has been achieved by getting PMU regmap from the "exynos-pmu" device of fixed name. - more cleanup in Exynos pin controller driver: added missing entries in DT documentation, removed "memory allocation failed" messages and added initconst annotations. - added support for s5pv210. - reworked retention control code to be simpler and ready for adding Exynos5433 support. v0: http://www.spinics.net/lists/arm-kernel/msg550161.html - initial version - part of "Runtime PM for Exynos pin controller driver" patchset Patch summary: Marek Szyprowski (13): soc: samsung: pmu: Provide global function to get PMU regmap soc: samsung: pmu: Use of_device_get_match_data helper soc: samsung: pmu: Remove messages for failed memory allocation pinctrl: samsung: Document Exynos3250 SoC support pinctrl: samsung: Remove messages for failed memory allocation pinctrl: samsung: Fix samsung_pinctrl_create_functions return value pinctrl: samsung: Add missing initconst annotation pinctrl: samsung: Remove dead code pinctrl: samsung: Use generic of_device_get_match_data helper pinctrl: samsung: Add infrastructure for pin-bank retention control pinctrl: samsung: Move retention control from mach-exynos to the pinctrl driver pinctrl: samsung: Move retention control from mach-s5pv210 to the pinctrl driver pinctrl: samsung: Replace syscore ops with standard platform device pm_ops .../bindings/pinctrl/samsung-pinctrl.txt | 1 + arch/arm/mach-exynos/suspend.c | 64 ------ arch/arm/mach-s5pv210/pm.c | 7 - arch/arm/mach-s5pv210/regs-clock.h | 4 - drivers/pinctrl/samsung/pinctrl-exynos.c | 232 +++++++++++++++++++-- drivers/pinctrl/samsung/pinctrl-s3c64xx.c | 12 +- drivers/pinctrl/samsung/pinctrl-samsung.c | 123 ++++------- drivers/pinctrl/samsung/pinctrl-samsung.h | 42 ++++ drivers/soc/samsung/exynos-pmu.c | 22 +- include/linux/soc/samsung/exynos-pmu.h | 7 + 10 files changed, 320 insertions(+), 194 deletions(-) -- 1.9.1 _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel Reviewed-by: Krzysztof Kozlowski Reviewed-by: Krzysztof Kozlowski Acked-by: Krzysztof Kozlowski