From patchwork Mon Jan 30 12:38:22 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Marek Szyprowski X-Patchwork-Id: 92849 Delivered-To: patch@linaro.org Received: by 10.140.20.99 with SMTP id 90csp1412510qgi; Mon, 30 Jan 2017 04:39:31 -0800 (PST) X-Received: by 10.84.133.69 with SMTP id 63mr31065596plf.97.1485779971026; Mon, 30 Jan 2017 04:39:31 -0800 (PST) Return-Path: Received: from bombadil.infradead.org (bombadil.infradead.org. [65.50.211.133]) by mx.google.com with ESMTPS id 140si8427173pgg.95.2017.01.30.04.39.30 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 30 Jan 2017 04:39:31 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-arm-kernel-bounces+patch=linaro.org@lists.infradead.org designates 65.50.211.133 as permitted sender) client-ip=65.50.211.133; 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 65.50.211.133 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 1cYBF3-0004fJ-Ss; Mon, 30 Jan 2017 12:39:29 +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 1cYBEd-0004aM-02 for linux-arm-kernel@lists.infradead.org; Mon, 30 Jan 2017 12:39:05 +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 <0OKL00C8KF4FIZ60@mailout2.w1.samsung.com> for linux-arm-kernel@lists.infradead.org; Mon, 30 Jan 2017 12:38:39 +0000 (GMT) Received: from eusmges4.samsung.com (unknown [203.254.199.244]) by eucas1p1.samsung.com (KnoxPortal) with ESMTP id 20170130123838eucas1p1a7557301a638066854ed1bf13ed361fe~ejPayqet20307403074eucas1p1f; Mon, 30 Jan 2017 12:38:38 +0000 (GMT) Received: from eucas1p2.samsung.com ( [182.198.249.207]) by eusmges4.samsung.com (EUCPMTA) with SMTP id 27.A2.28517.DC33F885; Mon, 30 Jan 2017 12:38:38 +0000 (GMT) Received: from eusmgms1.samsung.com (unknown [182.198.249.179]) by eucas1p1.samsung.com (KnoxPortal) with ESMTP id 20170130123837eucas1p1056a57f23b1e3bf089e5bc55bb2cf2d4~ejPaMABne2024520245eucas1p1j; Mon, 30 Jan 2017 12:38:37 +0000 (GMT) X-AuditID: cbfec7f4-f79716d000006f65-82-588f33cdd960 Received: from eusync3.samsung.com ( [203.254.199.213]) by eusmgms1.samsung.com (EUCPMTA) with SMTP id 1E.C6.06687.0143F885; Mon, 30 Jan 2017 12:39:44 +0000 (GMT) Received: from AMDC2765.digital.local ([106.116.147.25]) by eusync3.samsung.com (Oracle Communications Messaging Server 7.0.5.31.0 64bit (built May 5 2014)) with ESMTPA id <0OKL0038AF49F510@eusync3.samsung.com>; Mon, 30 Jan 2017 12:38:37 +0000 (GMT) From: Marek Szyprowski To: linux-gpio@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-samsung-soc@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH v3 1/7] soc: smasung: pmu: Add register defines for pad retention control Date: Mon, 30 Jan 2017 13:38:22 +0100 Message-id: <1485779908-32147-2-git-send-email-m.szyprowski@samsung.com> X-Mailer: git-send-email 1.9.1 In-reply-to: <1485779908-32147-1-git-send-email-m.szyprowski@samsung.com> X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFnrAIsWRmVeSWpSXmKPExsWy7djP87rnjPsjDO5rWWycsZ7V4vz5DewW 978eZbSY8mc5k8Wmx9dYLTbP/8NocXnXHDaLGef3MVmsPXKX3eLwm3ZWi1W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Wn4v3OWawNjEe5uhg5 OSQETCT693SwQdhiEhfurQeyuTiEBJYwStyc3csCkhASaGKS2LKKD8RmEzCU6HrbBVYkItDO KPH69jUmEIdZYAuTRNemi+wgVcIC0RKNtz+A2SwCqhJXlvxnBrF5BTwkDu96wAyxTk7i5LHJ rCA2p4CnxJanh5ghtnlInL/xn2UCI+8CRoZVjCKppcW56bnFhnrFibnFpXnpesn5uZsYgeG/ 7djPzTsYL20MPsQowMGoxMN7Q7gvQog1say4MvcQowQHs5II70nV/ggh3pTEyqrUovz4otKc 1OJDjKZAR01klhJNzgfGZl5JvKGJobmloZGxhYW5kZGSOG/JhyvhQgLpiSWp2ampBalFMH1M HJxSDYwRMp94Ggo9sx7sflj0P6t5p9FSg9mC+vNen7FacNb+KRcns+a0G99NmRjdSk63cvJL TU1L9fj3IXmKnMyPmkrOrRV8Z6Q1Fn699jbFyulhuW39r6I1EYyfeWqXFE6rveny/umSdQ21 ddPSQktypN7Vv2OLuyK8N5S71FnLZb7YY0++Rc69XkosxRmJhlrMRcWJAFx4HACVAgAA X-MTR: 20000000000000000@CPGS X-CMS-MailID: 20170130123837eucas1p1056a57f23b1e3bf089e5bc55bb2cf2d4 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: 20170130123837eucas1p1056a57f23b1e3bf089e5bc55bb2cf2d4 X-RootMTR: 20170130123837eucas1p1056a57f23b1e3bf089e5bc55bb2cf2d4 References: <1485779908-32147-1-git-send-email-m.szyprowski@samsung.com> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20170130_043903_196686_0E9DF119 X-CRM114-Status: GOOD ( 12.32 ) 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 , Lee Jones , Marek Szyprowski MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patch=linaro.org@lists.infradead.org Add PMU defines related to pad retention control. Will be later used by the Exynos pin controller driver. Signed-off-by: Marek Szyprowski --- include/linux/soc/samsung/exynos-regs-pmu.h | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) -- 1.9.1 _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel diff --git a/include/linux/soc/samsung/exynos-regs-pmu.h b/include/linux/soc/samsung/exynos-regs-pmu.h index 9786c62d7159..49df0a01a2cc 100644 --- a/include/linux/soc/samsung/exynos-regs-pmu.h +++ b/include/linux/soc/samsung/exynos-regs-pmu.h @@ -631,4 +631,20 @@ | EXYNOS5420_KFC_USE_STANDBY_WFI2 \ | EXYNOS5420_KFC_USE_STANDBY_WFI3) +/* For EXYNOS5433 */ +#define EXYNOS5433_PAD_RETENTION_AUD_OPTION (0x3028) +#define EXYNOS5433_PAD_RETENTION_MMC2_OPTION (0x30C8) +#define EXYNOS5433_PAD_RETENTION_TOP_OPTION (0x3108) +#define EXYNOS5433_PAD_RETENTION_UART_OPTION (0x3128) +#define EXYNOS5433_PAD_RETENTION_MMC0_OPTION (0x3148) +#define EXYNOS5433_PAD_RETENTION_MMC1_OPTION (0x3168) +#define EXYNOS5433_PAD_RETENTION_EBIA_OPTION (0x3188) +#define EXYNOS5433_PAD_RETENTION_EBIB_OPTION (0x31A8) +#define EXYNOS5433_PAD_RETENTION_SPI_OPTION (0x31C8) +#define EXYNOS5433_PAD_RETENTION_MIF_OPTION (0x31E8) +#define EXYNOS5433_PAD_RETENTION_USBXTI_OPTION (0x3228) +#define EXYNOS5433_PAD_RETENTION_BOOTLDO_OPTION (0x3248) +#define EXYNOS5433_PAD_RETENTION_UFS_OPTION (0x3268) +#define EXYNOS5433_PAD_RETENTION_FSYSGENIO_OPTION (0x32A8) + #endif /* __LINUX_SOC_EXYNOS_REGS_PMU_H */ From patchwork Mon Jan 30 12:38:23 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Marek Szyprowski X-Patchwork-Id: 92856 Delivered-To: patch@linaro.org Received: by 10.140.20.99 with SMTP id 90csp1413532qgi; Mon, 30 Jan 2017 04:42:24 -0800 (PST) X-Received: by 10.98.13.203 with SMTP id 72mr22788493pfn.64.1485780144765; Mon, 30 Jan 2017 04:42:24 -0800 (PST) Return-Path: Received: from bombadil.infradead.org (bombadil.infradead.org. [65.50.211.133]) by mx.google.com with ESMTPS id t6si12533626pfi.59.2017.01.30.04.42.24 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 30 Jan 2017 04:42:24 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-arm-kernel-bounces+patch=linaro.org@lists.infradead.org designates 65.50.211.133 as permitted sender) client-ip=65.50.211.133; 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 65.50.211.133 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 1cYBHq-0007vP-7x; Mon, 30 Jan 2017 12:42:22 +0000 Received: from mailout4.w1.samsung.com ([210.118.77.14]) by bombadil.infradead.org with esmtps (Exim 4.87 #1 (Red Hat Linux)) id 1cYBEg-0004aa-Hs for linux-arm-kernel@lists.infradead.org; Mon, 30 Jan 2017 12:39:09 +0000 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 <0OKL00588F4FA560@mailout4.w1.samsung.com> for linux-arm-kernel@lists.infradead.org; Mon, 30 Jan 2017 12:38:39 +0000 (GMT) Received: from eusmges1.samsung.com (unknown [203.254.199.239]) by eucas1p2.samsung.com (KnoxPortal) with ESMTP id 20170130123838eucas1p2767cad82712506cbfc998f5e680d504e~ejPbYOF2i2038020380eucas1p2w; Mon, 30 Jan 2017 12:38:38 +0000 (GMT) Received: from eucas1p1.samsung.com ( [182.198.249.206]) by eusmges1.samsung.com (EUCPMTA) with SMTP id FB.93.16908.1D33F885; Mon, 30 Jan 2017 12:38:41 +0000 (GMT) Received: from eusmgms1.samsung.com (unknown [182.198.249.179]) by eucas1p1.samsung.com (KnoxPortal) with ESMTP id 20170130123838eucas1p12953af1e9af22e17ed9ca9c49dbd1e9d~ejPapzAGE2024520245eucas1p1k; Mon, 30 Jan 2017 12:38:38 +0000 (GMT) X-AuditID: cbfec7ef-f79d26d00000420c-d6-588f33d138c4 Received: from eusync3.samsung.com ( [203.254.199.213]) by eusmgms1.samsung.com (EUCPMTA) with SMTP id 2F.C6.06687.1143F885; Mon, 30 Jan 2017 12:39:45 +0000 (GMT) Received: from AMDC2765.digital.local ([106.116.147.25]) by eusync3.samsung.com (Oracle Communications Messaging Server 7.0.5.31.0 64bit (built May 5 2014)) with ESMTPA id <0OKL0038AF49F510@eusync3.samsung.com>; Mon, 30 Jan 2017 12:38:38 +0000 (GMT) From: Marek Szyprowski To: linux-gpio@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-samsung-soc@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH v3 2/7] pinctrl: samsung: Ensure that pad retention is disabled on driver init Date: Mon, 30 Jan 2017 13:38:23 +0100 Message-id: <1485779908-32147-3-git-send-email-m.szyprowski@samsung.com> X-Mailer: git-send-email 1.9.1 In-reply-to: <1485779908-32147-1-git-send-email-m.szyprowski@samsung.com> X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFnrAIsWRmVeSWpSXmKPExsWy7djPc7oXjfsjDOYuFbLYOGM9q8X58xvY Le5/PcpoMeXPciaLTY+vsVpsnv+H0eLyrjlsFjPO72OyWHvkLrvF4TftrBardv1hdOD22Dnr LrvHplWdbB53ru1h89i8pN6jb8sqRo/Pm+QC2KK4bFJSczLLUov07RK4MlqWZRR85ao4fbq2 gXEmZxcjJ4eEgInE3y1fGSFsMYkL99azdTFycQgJLGOUaHn+hxHC+cwoseHoMXaYjt23V7DD Vf26cg+qpYFJYkbjIjaQKjYBQ4mut11gCRGBdkaJu30dTCAOs8AmJom2JSeYQaqEBRIkfr/5 AdbBIqAq8XrfcTCbV8BDYuWFHVD75CROHpvMCmJzCnhKbHl6iBkiPpld4vUNlS5GDiBbVmLT Aaiwi8SWTxOhWoUlXh3fAmXLSHR2HGSCsPsZJZpatSHsGYwS597yQtjWEoePXwRbxSzAJzFp 23RmiPG8Eh1tQhAlHhK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0t37JSuZG+pd+ATF7zJzvrqrX/qn+r7uFMGV7+riY9bO2vz0 IVNM58EAPfulE9jXxdhvslx96stdnVurjN7kK9eLXO9YFL295EjpvXczPqVf1Y2a3h+27eyF x3OUe02Ol014e7rDKnNBlOIN5xMaK6dsk/wbxsykocRSnJFoqMVcVJwIAAsK2rCUAgAA X-MTR: 20000000000000000@CPGS X-CMS-MailID: 20170130123838eucas1p12953af1e9af22e17ed9ca9c49dbd1e9d 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: 20170130123838eucas1p12953af1e9af22e17ed9ca9c49dbd1e9d X-RootMTR: 20170130123838eucas1p12953af1e9af22e17ed9ca9c49dbd1e9d References: <1485779908-32147-1-git-send-email-m.szyprowski@samsung.com> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20170130_043906_777602_7A5299A1 X-CRM114-Status: GOOD ( 13.35 ) 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 ---- ---------------------- -------------------------------------------------- -0.0 RCVD_IN_MSPIKE_H3 RBL: Good reputation (+3) [210.118.77.14 listed in wl.mailspike.net] -5.0 RCVD_IN_DNSWL_HI RBL: Sender listed at http://www.dnswl.org/, high trust [210.118.77.14 listed in list.dnswl.org] -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 , Lee Jones , Marek Szyprowski MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patch=linaro.org@lists.infradead.org When pin controller device is a part of power domain, there is no guarantee that the power domain was not turned off and then on during boot process before probing of the pin control driver. If it happened, then pin control driver should ensure that pad retention is turned off during its probe call. Signed-off-by: Marek Szyprowski Reviewed-by: Krzysztof Kozlowski --- drivers/pinctrl/samsung/pinctrl-exynos.c | 5 +++++ 1 file changed, 5 insertions(+) -- 1.9.1 _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel diff --git a/drivers/pinctrl/samsung/pinctrl-exynos.c b/drivers/pinctrl/samsung/pinctrl-exynos.c index 63e51b56a22a..fa3802970570 100644 --- a/drivers/pinctrl/samsung/pinctrl-exynos.c +++ b/drivers/pinctrl/samsung/pinctrl-exynos.c @@ -777,6 +777,7 @@ static void exynos_retention_disable(struct samsung_pinctrl_drv_data *drvdata) { struct samsung_retention_ctrl *ctrl; struct regmap *pmu_regs; + int i; ctrl = devm_kzalloc(drvdata->dev, sizeof(*ctrl), GFP_KERNEL); if (!ctrl) @@ -794,6 +795,10 @@ static void exynos_retention_disable(struct samsung_pinctrl_drv_data *drvdata) ctrl->enable = exynos_retention_enable; ctrl->disable = exynos_retention_disable; + /* Ensure that retention is disabled on driver init */ + for (i = 0; i < ctrl->nr_regs; i++) + regmap_write(pmu_regs, ctrl->regs[i], ctrl->value); + return ctrl; } From patchwork Mon Jan 30 12:38:24 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Marek Szyprowski X-Patchwork-Id: 92851 Delivered-To: patch@linaro.org Received: by 10.140.20.99 with SMTP id 90csp1412765qgi; Mon, 30 Jan 2017 04:40:15 -0800 (PST) X-Received: by 10.99.169.17 with SMTP id u17mr23413480pge.191.1485780015161; Mon, 30 Jan 2017 04:40:15 -0800 (PST) Return-Path: Received: from bombadil.infradead.org (bombadil.infradead.org. [65.50.211.133]) by mx.google.com with ESMTPS id r14si12468152pli.158.2017.01.30.04.40.14 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 30 Jan 2017 04:40:15 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-arm-kernel-bounces+patch=linaro.org@lists.infradead.org designates 65.50.211.133 as permitted sender) client-ip=65.50.211.133; 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 65.50.211.133 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 1cYBFk-0006UM-IO; Mon, 30 Jan 2017 12:40:12 +0000 Received: from mailout1.w1.samsung.com ([210.118.77.11]) by bombadil.infradead.org with esmtps (Exim 4.87 #1 (Red Hat Linux)) id 1cYBEe-0004aj-Fp for linux-arm-kernel@lists.infradead.org; Mon, 30 Jan 2017 12:39:06 +0000 Received: from eucas1p1.samsung.com (unknown [182.198.249.206]) by mailout1.w1.samsung.com (Oracle Communications Messaging Server 7.0.5.31.0 64bit (built May 5 2014)) with ESMTP id <0OKL00BB4F4G8C60@mailout1.w1.samsung.com> for linux-arm-kernel@lists.infradead.org; Mon, 30 Jan 2017 12:38:40 +0000 (GMT) Received: from eusmges1.samsung.com (unknown [203.254.199.239]) by eucas1p2.samsung.com (KnoxPortal) with ESMTP id 20170130123839eucas1p2ec428a0a076590bbec5e5bceb7c18465~ejPb04cmn1821118211eucas1p2I; Mon, 30 Jan 2017 12:38:39 +0000 (GMT) Received: from eucas1p1.samsung.com ( [182.198.249.206]) by eusmges1.samsung.com (EUCPMTA) with SMTP id DC.93.16908.1D33F885; Mon, 30 Jan 2017 12:38:41 +0000 (GMT) Received: from eusmgms1.samsung.com (unknown [182.198.249.179]) by eucas1p1.samsung.com (KnoxPortal) with ESMTP id 20170130123838eucas1p1fdae7ffe2af981607ec389f27c46f689~ejPbJGGai0316903169eucas1p1j; Mon, 30 Jan 2017 12:38:38 +0000 (GMT) X-AuditID: cbfec7ef-f79d26d00000420c-d8-588f33d1ff43 Received: from eusync3.samsung.com ( [203.254.199.213]) by eusmgms1.samsung.com (EUCPMTA) with SMTP id 10.D6.06687.1143F885; Mon, 30 Jan 2017 12:39:45 +0000 (GMT) Received: from AMDC2765.digital.local ([106.116.147.25]) by eusync3.samsung.com (Oracle Communications Messaging Server 7.0.5.31.0 64bit (built May 5 2014)) with ESMTPA id <0OKL0038AF49F510@eusync3.samsung.com>; Mon, 30 Jan 2017 12:38:38 +0000 (GMT) From: Marek Szyprowski To: linux-gpio@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-samsung-soc@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH v3 3/7] pinctrl: samsung: Add support for pad retention control for Exynos5433 SoCs Date: Mon, 30 Jan 2017 13:38:24 +0100 Message-id: <1485779908-32147-4-git-send-email-m.szyprowski@samsung.com> X-Mailer: git-send-email 1.9.1 In-reply-to: <1485779908-32147-1-git-send-email-m.szyprowski@samsung.com> X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFnrMIsWRmVeSWpSXmKPExsWy7djPc7oXjfsjDI73G1hsnLGe1eL8+Q3s Fve/HmW0mPJnOZPFpsfXWC02z//DaHF51xw2ixnn9zFZrD1yl93i8Jt2VotVu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jDO1uxg5 OSQETCSOHmpkgbDFJC7cW8/WxcjFISSwhFHi8vdNUE4Tk8SVpYfAqtgEDCW63naBJUQE2hkl Xt++xgTiMAtsYZLo2nSRHaRKWCBV4srcz4wgNouAqsTNVU+ZQWxeAQ+J/k0zWCH2yUmcPDYZ zOYU8JTY8vQQWI0QUM35G/9ZJjDyLmBkWMUoklpanJueW2yoV5yYW1yal66XnJ+7iREYAduO /dy8g/HSxuBDjAIcjEo8vDeE+yKEWBPLiitzDzFKcDArifCeVO2PEOJNSaysSi3Kjy8qzUkt PsRoCnTURGYp0eR8YHTmlcQbmhiaWxoaGVtYmBsZKYnzlny4Ei4kkJ5YkpqdmlqQWgTTx8TB KdXAKPH3c8GNZRO+vX55pFVtawDHjuM33x0xCtDP+bNE70lg0f1926adSlT8c/me/PLVVv4z +KbN2N10NjpCZOee88IMkh76tcJLdT/KFHNHKnz9sOXlm+L3O7TKVlXzCXyeVKt0/daDjg/K nxdPrUy+UL4taRdPfkJU7zl/ru74tHrPN1tCD7B0v1JiKc5INNRiLipOBACxdx95lgIAAA== X-MTR: 20000000000000000@CPGS X-CMS-MailID: 20170130123838eucas1p1fdae7ffe2af981607ec389f27c46f689 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: 20170130123838eucas1p1fdae7ffe2af981607ec389f27c46f689 X-RootMTR: 20170130123838eucas1p1fdae7ffe2af981607ec389f27c46f689 References: <1485779908-32147-1-git-send-email-m.szyprowski@samsung.com> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20170130_043904_687725_48ACD9DF X-CRM114-Status: GOOD ( 13.13 ) 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.11 listed in list.dnswl.org] -0.0 RCVD_IN_MSPIKE_H3 RBL: Good reputation (+3) [210.118.77.11 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 , Lee Jones , Marek Szyprowski MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patch=linaro.org@lists.infradead.org This patch adds support for retention control for Exynos5433 SoCs. Three groups of pins has been defined for retention control: common shared group for ALIVE, CPIF, eSE, FINGER, IMEM, NFC, PERIC, TOUCH pin banks and separate control for FSYS and AUD pin banks, for which PMU retention registers match whole banks. Signed-off-by: Marek Szyprowski Reviewed-by: Krzysztof Kozlowski --- drivers/pinctrl/samsung/pinctrl-exynos.c | 58 ++++++++++++++++++++++++++++++++ 1 file changed, 58 insertions(+) -- 1.9.1 _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel diff --git a/drivers/pinctrl/samsung/pinctrl-exynos.c b/drivers/pinctrl/samsung/pinctrl-exynos.c index fa3802970570..7b0e6cc35e04 100644 --- a/drivers/pinctrl/samsung/pinctrl-exynos.c +++ b/drivers/pinctrl/samsung/pinctrl-exynos.c @@ -1551,6 +1551,54 @@ static void exynos_retention_disable(struct samsung_pinctrl_drv_data *drvdata) EXYNOS5433_PIN_BANK_EINTG(3, 0x000, "gpj1", 0x00), }; +/* PMU pin retention groups registers for Exynos5433 (without audio & fsys) */ +static const u32 exynos5433_retention_regs[] = { + EXYNOS5433_PAD_RETENTION_TOP_OPTION, + EXYNOS5433_PAD_RETENTION_UART_OPTION, + EXYNOS5433_PAD_RETENTION_EBIA_OPTION, + EXYNOS5433_PAD_RETENTION_EBIB_OPTION, + EXYNOS5433_PAD_RETENTION_SPI_OPTION, + EXYNOS5433_PAD_RETENTION_MIF_OPTION, + EXYNOS5433_PAD_RETENTION_USBXTI_OPTION, + EXYNOS5433_PAD_RETENTION_BOOTLDO_OPTION, + EXYNOS5433_PAD_RETENTION_UFS_OPTION, + EXYNOS5433_PAD_RETENTION_FSYSGENIO_OPTION, +}; + +static const struct samsung_retention_data exynos5433_retention_data __initconst = { + .regs = exynos5433_retention_regs, + .nr_regs = ARRAY_SIZE(exynos5433_retention_regs), + .value = EXYNOS_WAKEUP_FROM_LOWPWR, + .refcnt = &exynos_shared_retention_refcnt, + .init = exynos_retention_init, +}; + +/* PMU retention control for audio pins can be tied to audio pin bank */ +static const u32 exynos5433_audio_retention_regs[] = { + EXYNOS5433_PAD_RETENTION_AUD_OPTION, +}; + +static const struct samsung_retention_data exynos5433_audio_retention_data __initconst = { + .regs = exynos5433_audio_retention_regs, + .nr_regs = ARRAY_SIZE(exynos5433_audio_retention_regs), + .value = EXYNOS_WAKEUP_FROM_LOWPWR, + .init = exynos_retention_init, +}; + +/* PMU retention control for mmc pins can be tied to fsys pin bank */ +static const u32 exynos5433_fsys_retention_regs[] = { + EXYNOS5433_PAD_RETENTION_MMC0_OPTION, + EXYNOS5433_PAD_RETENTION_MMC1_OPTION, + EXYNOS5433_PAD_RETENTION_MMC2_OPTION, +}; + +static const struct samsung_retention_data exynos5433_fsys_retention_data __initconst = { + .regs = exynos5433_fsys_retention_regs, + .nr_regs = ARRAY_SIZE(exynos5433_fsys_retention_regs), + .value = EXYNOS_WAKEUP_FROM_LOWPWR, + .init = exynos_retention_init, +}; + /* * Samsung pinctrl driver data for Exynos5433 SoC. Exynos5433 SoC includes * ten gpio/pin-mux/pinconfig controllers. @@ -1564,6 +1612,7 @@ static void exynos_retention_disable(struct samsung_pinctrl_drv_data *drvdata) .suspend = exynos_pinctrl_suspend, .resume = exynos_pinctrl_resume, .nr_ext_resources = 1, + .retention_data = &exynos5433_retention_data, }, { /* pin-controller instance 1 data */ .pin_banks = exynos5433_pin_banks1, @@ -1571,6 +1620,7 @@ static void exynos_retention_disable(struct samsung_pinctrl_drv_data *drvdata) .eint_gpio_init = exynos_eint_gpio_init, .suspend = exynos_pinctrl_suspend, .resume = exynos_pinctrl_resume, + .retention_data = &exynos5433_audio_retention_data, }, { /* pin-controller instance 2 data */ .pin_banks = exynos5433_pin_banks2, @@ -1578,6 +1628,7 @@ static void exynos_retention_disable(struct samsung_pinctrl_drv_data *drvdata) .eint_gpio_init = exynos_eint_gpio_init, .suspend = exynos_pinctrl_suspend, .resume = exynos_pinctrl_resume, + .retention_data = &exynos5433_retention_data, }, { /* pin-controller instance 3 data */ .pin_banks = exynos5433_pin_banks3, @@ -1585,6 +1636,7 @@ static void exynos_retention_disable(struct samsung_pinctrl_drv_data *drvdata) .eint_gpio_init = exynos_eint_gpio_init, .suspend = exynos_pinctrl_suspend, .resume = exynos_pinctrl_resume, + .retention_data = &exynos5433_retention_data, }, { /* pin-controller instance 4 data */ .pin_banks = exynos5433_pin_banks4, @@ -1592,6 +1644,7 @@ static void exynos_retention_disable(struct samsung_pinctrl_drv_data *drvdata) .eint_gpio_init = exynos_eint_gpio_init, .suspend = exynos_pinctrl_suspend, .resume = exynos_pinctrl_resume, + .retention_data = &exynos5433_retention_data, }, { /* pin-controller instance 5 data */ .pin_banks = exynos5433_pin_banks5, @@ -1599,6 +1652,7 @@ static void exynos_retention_disable(struct samsung_pinctrl_drv_data *drvdata) .eint_gpio_init = exynos_eint_gpio_init, .suspend = exynos_pinctrl_suspend, .resume = exynos_pinctrl_resume, + .retention_data = &exynos5433_fsys_retention_data, }, { /* pin-controller instance 6 data */ .pin_banks = exynos5433_pin_banks6, @@ -1606,6 +1660,7 @@ static void exynos_retention_disable(struct samsung_pinctrl_drv_data *drvdata) .eint_gpio_init = exynos_eint_gpio_init, .suspend = exynos_pinctrl_suspend, .resume = exynos_pinctrl_resume, + .retention_data = &exynos5433_retention_data, }, { /* pin-controller instance 7 data */ .pin_banks = exynos5433_pin_banks7, @@ -1613,6 +1668,7 @@ static void exynos_retention_disable(struct samsung_pinctrl_drv_data *drvdata) .eint_gpio_init = exynos_eint_gpio_init, .suspend = exynos_pinctrl_suspend, .resume = exynos_pinctrl_resume, + .retention_data = &exynos5433_retention_data, }, { /* pin-controller instance 8 data */ .pin_banks = exynos5433_pin_banks8, @@ -1620,6 +1676,7 @@ static void exynos_retention_disable(struct samsung_pinctrl_drv_data *drvdata) .eint_gpio_init = exynos_eint_gpio_init, .suspend = exynos_pinctrl_suspend, .resume = exynos_pinctrl_resume, + .retention_data = &exynos5433_retention_data, }, { /* pin-controller instance 9 data */ .pin_banks = exynos5433_pin_banks9, @@ -1627,6 +1684,7 @@ static void exynos_retention_disable(struct samsung_pinctrl_drv_data *drvdata) .eint_gpio_init = exynos_eint_gpio_init, .suspend = exynos_pinctrl_suspend, .resume = exynos_pinctrl_resume, + .retention_data = &exynos5433_retention_data, }, }; From patchwork Mon Jan 30 12:38:25 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Marek Szyprowski X-Patchwork-Id: 92853 Delivered-To: patch@linaro.org Received: by 10.140.20.99 with SMTP id 90csp1413112qgi; Mon, 30 Jan 2017 04:41:09 -0800 (PST) X-Received: by 10.98.220.139 with SMTP id c11mr22738141pfl.96.1485780069687; Mon, 30 Jan 2017 04:41:09 -0800 (PST) Return-Path: Received: from bombadil.infradead.org (bombadil.infradead.org. [65.50.211.133]) by mx.google.com with ESMTPS id 207si8443327pgh.10.2017.01.30.04.41.09 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 30 Jan 2017 04:41:09 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-arm-kernel-bounces+patch=linaro.org@lists.infradead.org designates 65.50.211.133 as permitted sender) client-ip=65.50.211.133; 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 65.50.211.133 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 1cYBGe-0006rE-4o; Mon, 30 Jan 2017 12:41:08 +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 1cYBEf-0004aM-7j for linux-arm-kernel@lists.infradead.org; Mon, 30 Jan 2017 12:39:07 +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 <0OKL00CB3F4G1K60@mailout2.w1.samsung.com> for linux-arm-kernel@lists.infradead.org; Mon, 30 Jan 2017 12:38:40 +0000 (GMT) Received: from eusmges1.samsung.com (unknown [203.254.199.239]) by eucas1p1.samsung.com (KnoxPortal) with ESMTP id 20170130123839eucas1p175cb8902925e7a90278ceb68b100ac16~ejPcRTSLS0307403074eucas1p1n; Mon, 30 Jan 2017 12:38:39 +0000 (GMT) Received: from eucas1p2.samsung.com ( [182.198.249.207]) by eusmges1.samsung.com (EUCPMTA) with SMTP id DD.93.16908.2D33F885; Mon, 30 Jan 2017 12:38:42 +0000 (GMT) Received: from eusmgms1.samsung.com (unknown [182.198.249.179]) by eucas1p1.samsung.com (KnoxPortal) with ESMTP id 20170130123839eucas1p156e10c543d4daf6675fa3e326a724cc2~ejPbndXxr0307403074eucas1p1k; Mon, 30 Jan 2017 12:38:39 +0000 (GMT) X-AuditID: cbfec7ef-f79d26d00000420c-dc-588f33d2a2cb Received: from eusync3.samsung.com ( [203.254.199.213]) by eusmgms1.samsung.com (EUCPMTA) with SMTP id 61.D6.06687.2143F885; Mon, 30 Jan 2017 12:39:46 +0000 (GMT) Received: from AMDC2765.digital.local ([106.116.147.25]) by eusync3.samsung.com (Oracle Communications Messaging Server 7.0.5.31.0 64bit (built May 5 2014)) with ESMTPA id <0OKL0038AF49F510@eusync3.samsung.com>; Mon, 30 Jan 2017 12:38:39 +0000 (GMT) From: Marek Szyprowski To: linux-gpio@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-samsung-soc@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH v3 4/7] mfd: exynos-lpass: Remove pad retention control Date: Mon, 30 Jan 2017 13:38:25 +0100 Message-id: <1485779908-32147-5-git-send-email-m.szyprowski@samsung.com> X-Mailer: git-send-email 1.9.1 In-reply-to: <1485779908-32147-1-git-send-email-m.szyprowski@samsung.com> X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFnrEIsWRmVeSWpSXmKPExsWy7djP87qXjPsjDGbMEbDYOGM9q8X58xvY Le5/PcpoMeXPciaLTY+vsVpsnv+H0eLyrjlsFjPO72OyWHvkLrvF4TftrBardv1hdOD22Dnr LrvHplWdbB53ru1h89i8pN6jb8sqRo/Pm+QC2KK4bFJSczLLUov07RK4Mm61lxW0K1ScujmV pYHxq1QXIyeHhICJxKpX21ggbDGJC/fWs3UxcnEICSxjlHi19RIThPOZUaLh6hlWmI6p/+Yy wVVdedoI1dLAJHG18xUz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CW2PD3EDGILAdWcv/GfZQIj7wJGhlWMIqmlxbnpucWGesWJucWleel6yfm5mxiB4b/t 2M/NOxgvbQw+xCjAwajEw3tDuC9CiDWxrLgy9xCjBAezkgjvSdX+CCHelMTKqtSi/Pii0pzU 4kOMpkBHTWSWEk3OB8ZmXkm8oYmhuaWhkbGFhbmRkZI4b8mHK+FCAumJJanZqakFqUUwfUwc nFINjJLcijfeVBlzqLTP1Ok5u//LoUf1ykW1R6+yz+Q3uLnBcZa2pHZv0qTDTvPep7oYNSyK e3hY/daut/fusC+1c4rf/HPivfWPTjaxcN3fe1OO8e/ZrGLVlMl2xnrHFsrsE75af1Q7fM7z rMS0x1Pe3zn07MF37fP31Z8/+jArTfAY58MXTustt7IosRRnJBpqMRcVJwIAumVccJUCAAA= X-MTR: 20000000000000000@CPGS X-CMS-MailID: 20170130123839eucas1p156e10c543d4daf6675fa3e326a724cc2 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: 20170130123839eucas1p156e10c543d4daf6675fa3e326a724cc2 X-RootMTR: 20170130123839eucas1p156e10c543d4daf6675fa3e326a724cc2 References: <1485779908-32147-1-git-send-email-m.szyprowski@samsung.com> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20170130_043905_434787_26DCB205 X-CRM114-Status: GOOD ( 17.18 ) 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 ---- ---------------------- -------------------------------------------------- -0.0 RCVD_IN_MSPIKE_H3 RBL: Good reputation (+3) [210.118.77.12 listed in wl.mailspike.net] -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] -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 , Lee Jones , Marek Szyprowski MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patch=linaro.org@lists.infradead.org Pad retention should be controlled from pin control driver, so remove it from Exynos LPASS driver. After this change, no more access to PMU regmap is needed, so remove also the code for handling PMU regmap. Signed-off-by: Marek Szyprowski Acked-by: Krzysztof Kozlowski Acked-by: Sylwester Nawrocki --- .../bindings/mfd/samsung,exynos5433-lpass.txt | 2 -- drivers/mfd/exynos-lpass.c | 17 ----------------- include/linux/mfd/syscon/exynos5-pmu.h | 3 --- 3 files changed, 22 deletions(-) -- 1.9.1 _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel diff --git a/Documentation/devicetree/bindings/mfd/samsung,exynos5433-lpass.txt b/Documentation/devicetree/bindings/mfd/samsung,exynos5433-lpass.txt index c110e118b79f..a8deaee82c44 100644 --- a/Documentation/devicetree/bindings/mfd/samsung,exynos5433-lpass.txt +++ b/Documentation/devicetree/bindings/mfd/samsung,exynos5433-lpass.txt @@ -5,7 +5,6 @@ Required properties: - compatible : "samsung,exynos5433-lpass" - reg : should contain the LPASS top SFR region location and size - - samsung,pmu-syscon : the phandle to the Power Management Unit node - #address-cells : should be 1 - #size-cells : should be 1 - ranges : must be present @@ -25,7 +24,6 @@ Example: audio-subsystem { compatible = "samsung,exynos5433-lpass"; reg = <0x11400000 0x100>, <0x11500000 0x08>; - samsung,pmu-syscon = <&pmu_system_controller>; #address-cells = <1>; #size-cells = <1>; ranges; diff --git a/drivers/mfd/exynos-lpass.c b/drivers/mfd/exynos-lpass.c index 2e064fb8826f..17915daa2e80 100644 --- a/drivers/mfd/exynos-lpass.c +++ b/drivers/mfd/exynos-lpass.c @@ -18,7 +18,6 @@ #include #include #include -#include #include #include #include @@ -51,8 +50,6 @@ #define LPASS_INTR_SFR BIT(0) struct exynos_lpass { - /* pointer to the Power Management Unit regmap */ - struct regmap *pmu; /* pointer to the LPASS TOP regmap */ struct regmap *top; }; @@ -81,10 +78,6 @@ static void exynos_lpass_enable(struct exynos_lpass *lpass) regmap_write(lpass->top, SFR_LPASS_INTR_CPU_MASK, LPASS_INTR_SFR | LPASS_INTR_DMA | LPASS_INTR_I2S); - /* Activate related PADs from retention state */ - regmap_write(lpass->pmu, EXYNOS5433_PAD_RETENTION_AUD_OPTION, - EXYNOS5433_PAD_INITIATE_WAKEUP_FROM_LOWPWR); - exynos_lpass_core_sw_reset(lpass, LPASS_I2S_SW_RESET); exynos_lpass_core_sw_reset(lpass, LPASS_DMA_SW_RESET); exynos_lpass_core_sw_reset(lpass, LPASS_MEM_SW_RESET); @@ -95,9 +88,6 @@ static void exynos_lpass_disable(struct exynos_lpass *lpass) /* Mask any unmasked IP interrupt sources */ regmap_write(lpass->top, SFR_LPASS_INTR_CPU_MASK, 0); regmap_write(lpass->top, SFR_LPASS_INTR_CA5_MASK, 0); - - /* Deactivate related PADs from retention state */ - regmap_write(lpass->pmu, EXYNOS5433_PAD_RETENTION_AUD_OPTION, 0); } static const struct regmap_config exynos_lpass_reg_conf = { @@ -131,13 +121,6 @@ static int exynos_lpass_probe(struct platform_device *pdev) return PTR_ERR(lpass->top); } - lpass->pmu = syscon_regmap_lookup_by_phandle(dev->of_node, - "samsung,pmu-syscon"); - if (IS_ERR(lpass->pmu)) { - dev_err(dev, "Failed to lookup PMU regmap\n"); - return PTR_ERR(lpass->pmu); - } - platform_set_drvdata(pdev, lpass); exynos_lpass_enable(lpass); diff --git a/include/linux/mfd/syscon/exynos5-pmu.h b/include/linux/mfd/syscon/exynos5-pmu.h index c28ff21ca4d2..0622ae86f9db 100644 --- a/include/linux/mfd/syscon/exynos5-pmu.h +++ b/include/linux/mfd/syscon/exynos5-pmu.h @@ -46,7 +46,4 @@ #define EXYNOS5_MIPI_PHY_S_RESETN BIT(1) #define EXYNOS5_MIPI_PHY_M_RESETN BIT(2) -#define EXYNOS5433_PAD_RETENTION_AUD_OPTION (0x3028) -#define EXYNOS5433_PAD_INITIATE_WAKEUP_FROM_LOWPWR BIT(28) - #endif /* _LINUX_MFD_SYSCON_PMU_EXYNOS5_H_ */ From patchwork Mon Jan 30 12:38:26 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Marek Szyprowski X-Patchwork-Id: 92855 Delivered-To: patch@linaro.org Received: by 10.140.20.99 with SMTP id 90csp1413485qgi; Mon, 30 Jan 2017 04:42:15 -0800 (PST) X-Received: by 10.84.210.5 with SMTP id z5mr31679627plh.32.1485780135427; Mon, 30 Jan 2017 04:42:15 -0800 (PST) Return-Path: Received: from bombadil.infradead.org (bombadil.infradead.org. [65.50.211.133]) by mx.google.com with ESMTPS id a21si8423974pgi.248.2017.01.30.04.42.15 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 30 Jan 2017 04:42:15 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-arm-kernel-bounces+patch=linaro.org@lists.infradead.org designates 65.50.211.133 as permitted sender) client-ip=65.50.211.133; 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 65.50.211.133 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 1cYBHh-0007Zg-KS; Mon, 30 Jan 2017 12:42:13 +0000 Received: from mailout1.w1.samsung.com ([210.118.77.11]) by bombadil.infradead.org with esmtps (Exim 4.87 #1 (Red Hat Linux)) id 1cYBEh-0004aj-34 for linux-arm-kernel@lists.infradead.org; Mon, 30 Jan 2017 12:39:09 +0000 Received: from eucas1p2.samsung.com (unknown [182.198.249.207]) by mailout1.w1.samsung.com (Oracle Communications Messaging Server 7.0.5.31.0 64bit (built May 5 2014)) with ESMTP id <0OKL00BB6F4H8C60@mailout1.w1.samsung.com> for linux-arm-kernel@lists.infradead.org; Mon, 30 Jan 2017 12:38:41 +0000 (GMT) Received: from eusmges2.samsung.com (unknown [203.254.199.241]) by eucas1p2.samsung.com (KnoxPortal) with ESMTP id 20170130123840eucas1p2ef26f48a6bb661e051c4fa95118285f5~ejPc97fUV2844928449eucas1p2h; Mon, 30 Jan 2017 12:38:40 +0000 (GMT) Received: from eucas1p1.samsung.com ( [182.198.249.206]) by eusmges2.samsung.com (EUCPMTA) with SMTP id 24.66.30614.0D33F885; Mon, 30 Jan 2017 12:38:40 +0000 (GMT) Received: from eusmgms1.samsung.com (unknown [182.198.249.179]) by eucas1p2.samsung.com (KnoxPortal) with ESMTP id 20170130123839eucas1p2bbbf9dd2c3d9cc1dbff1830a1e7e22cb~ejPcTqnj32037920379eucas1p2P; Mon, 30 Jan 2017 12:38:39 +0000 (GMT) X-AuditID: cbfec7f1-f793f6d000007796-47-588f33d04d58 Received: from eusync3.samsung.com ( [203.254.199.213]) by eusmgms1.samsung.com (EUCPMTA) with SMTP id B2.D6.06687.2143F885; Mon, 30 Jan 2017 12:39:46 +0000 (GMT) Received: from AMDC2765.digital.local ([106.116.147.25]) by eusync3.samsung.com (Oracle Communications Messaging Server 7.0.5.31.0 64bit (built May 5 2014)) with ESMTPA id <0OKL0038AF49F510@eusync3.samsung.com>; Mon, 30 Jan 2017 12:38:39 +0000 (GMT) From: Marek Szyprowski To: linux-gpio@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-samsung-soc@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH v3 5/7] mfd: exynos-lpass: Add support for clocks Date: Mon, 30 Jan 2017 13:38:26 +0100 Message-id: <1485779908-32147-6-git-send-email-m.szyprowski@samsung.com> X-Mailer: git-send-email 1.9.1 In-reply-to: <1485779908-32147-1-git-send-email-m.szyprowski@samsung.com> X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFrrLIsWRmVeSWpSXmKPExsWy7djPc7oXjPsjDO5cErHYOGM9q8X58xvY Le5/PcpoMeXPciaLTY+vsVpsnv+H0eLyrjlsFjPO72OyWHvkLrvF4TftrBardv1hdOD22Dnr LrvHplWdbB53ru1h89i8pN6jb8sqRo/Pm+QC2KK4bFJSczLLUov07RK4Mt59zC9okq3Y3TOD tYHxq3gXIyeHhICJxNQNC5kgbDGJC/fWs4HYQgJLGSXO38uFsD8zSpxeJQZT/2rDbKB6LqD4 MkaJW0uOs0M4DUwSVztfMYNUsQkYSnS97WIDSYgItDNK3O3rAGthFtjEJNG25ARYlbCAo8Tb WxtZQGwWAVWJxmn/we7gFfCQuHZiJzPEPjmJk8cms4LYnAKeElueHoKKT2aX6P5b38XIAWTL Smw6wAxhukh86I2FqBCWeHV8CzuELSPR2XEQ6st+RommVm0IewajxLm3vBC2tcTh4xfBNjEL 8ElM2jYdaiSvREebEITpIbHwnAVEtaPEuvdvWCFen8Mo8ervY+YJjDILGBlWMYqklhbnpqcW G+kVJ+YWl+al6yXn525iBEb66X/HP+5gfH/C6hCjAAejEg/vDeG+CCHWxLLiytxDjBIczE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33oi0/MLk+Y6pRuXqhN5HnyOCXE1 f/hgo/WhHxHaVfcPVfMbeD1hq+q4739vWsbf02+VWIozEg21mIuKEwE9jkaWlQIAAA== X-MTR: 20000000000000000@CPGS X-CMS-MailID: 20170130123839eucas1p2bbbf9dd2c3d9cc1dbff1830a1e7e22cb 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: 20170130123839eucas1p2bbbf9dd2c3d9cc1dbff1830a1e7e22cb X-RootMTR: 20170130123839eucas1p2bbbf9dd2c3d9cc1dbff1830a1e7e22cb References: <1485779908-32147-1-git-send-email-m.szyprowski@samsung.com> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20170130_043907_451646_8B05E4D0 X-CRM114-Status: GOOD ( 16.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 ---- ---------------------- -------------------------------------------------- -0.0 RCVD_IN_MSPIKE_H3 RBL: Good reputation (+3) [210.118.77.11 listed in wl.mailspike.net] -5.0 RCVD_IN_DNSWL_HI RBL: Sender listed at http://www.dnswl.org/, high trust [210.118.77.11 listed in list.dnswl.org] -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 , Lee Jones , Marek Szyprowski MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patch=linaro.org@lists.infradead.org Exynos LPASS requires some clocks to be enabled to make any access to its registers. This patch adds code for handling such clocks. For current set of registers it is enough to keep sfr0_ctrl clock enabled. Till now it worked only because those clocks were enabled by bootloader and driver probe() happened before they were disabled by clock core because of lack of users. Handling those clocks is also needed to make it possible to enable support for audio power domain. This patch requires adding sfr0_ctrl clock to device tree. Signed-off-by: Marek Szyprowski Reviewed-by: Krzysztof Kozlowski Acked-by: Sylwester Nawrocki --- .../devicetree/bindings/mfd/samsung,exynos5433-lpass.txt | 6 ++++++ drivers/mfd/exynos-lpass.c | 10 ++++++++++ 2 files changed, 16 insertions(+) -- 1.9.1 _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel diff --git a/Documentation/devicetree/bindings/mfd/samsung,exynos5433-lpass.txt b/Documentation/devicetree/bindings/mfd/samsung,exynos5433-lpass.txt index a8deaee82c44..df664018c148 100644 --- a/Documentation/devicetree/bindings/mfd/samsung,exynos5433-lpass.txt +++ b/Documentation/devicetree/bindings/mfd/samsung,exynos5433-lpass.txt @@ -5,6 +5,10 @@ Required properties: - compatible : "samsung,exynos5433-lpass" - reg : should contain the LPASS top SFR region location and size + - clock-names : should contain following required clocks: "sfr0_ctrl" + - clocks : should contain clock specifiers of all clocks, which + input names have been specified in clock-names + property, in same order. - #address-cells : should be 1 - #size-cells : should be 1 - ranges : must be present @@ -24,6 +28,8 @@ Example: audio-subsystem { compatible = "samsung,exynos5433-lpass"; reg = <0x11400000 0x100>, <0x11500000 0x08>; + clocks = <&cmu_aud CLK_PCLK_SFR0_CTRL>; + clock-names = "sfr0_ctrl"; #address-cells = <1>; #size-cells = <1>; ranges; diff --git a/drivers/mfd/exynos-lpass.c b/drivers/mfd/exynos-lpass.c index 17915daa2e80..be264988bdc9 100644 --- a/drivers/mfd/exynos-lpass.c +++ b/drivers/mfd/exynos-lpass.c @@ -14,6 +14,7 @@ * only version 2 as published by the Free Software Foundation. */ +#include #include #include #include @@ -52,6 +53,7 @@ struct exynos_lpass { /* pointer to the LPASS TOP regmap */ struct regmap *top; + struct clk *sfr0_clk; }; static void exynos_lpass_core_sw_reset(struct exynos_lpass *lpass, int mask) @@ -71,6 +73,8 @@ static void exynos_lpass_core_sw_reset(struct exynos_lpass *lpass, int mask) static void exynos_lpass_enable(struct exynos_lpass *lpass) { + clk_prepare_enable(lpass->sfr0_clk); + /* Unmask SFR, DMA and I2S interrupt */ regmap_write(lpass->top, SFR_LPASS_INTR_CA5_MASK, LPASS_INTR_SFR | LPASS_INTR_DMA | LPASS_INTR_I2S); @@ -88,6 +92,8 @@ static void exynos_lpass_disable(struct exynos_lpass *lpass) /* Mask any unmasked IP interrupt sources */ regmap_write(lpass->top, SFR_LPASS_INTR_CPU_MASK, 0); regmap_write(lpass->top, SFR_LPASS_INTR_CA5_MASK, 0); + + clk_disable_unprepare(lpass->sfr0_clk); } static const struct regmap_config exynos_lpass_reg_conf = { @@ -114,6 +120,10 @@ static int exynos_lpass_probe(struct platform_device *pdev) if (IS_ERR(base_top)) return PTR_ERR(base_top); + lpass->sfr0_clk = devm_clk_get(dev, "sfr0_ctrl"); + if (IS_ERR(lpass->sfr0_clk)) + return PTR_ERR(lpass->sfr0_clk); + lpass->top = regmap_init_mmio(dev, base_top, &exynos_lpass_reg_conf); if (IS_ERR(lpass->top)) { From patchwork Mon Jan 30 12:38:27 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Marek Szyprowski X-Patchwork-Id: 92854 Delivered-To: patch@linaro.org Received: by 10.140.20.99 with SMTP id 90csp1413168qgi; Mon, 30 Jan 2017 04:41:20 -0800 (PST) X-Received: by 10.99.238.69 with SMTP id n5mr23501633pgk.38.1485780080374; Mon, 30 Jan 2017 04:41:20 -0800 (PST) Return-Path: Received: from bombadil.infradead.org (bombadil.infradead.org. [65.50.211.133]) by mx.google.com with ESMTPS id n1si12480144pld.109.2017.01.30.04.41.20 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 30 Jan 2017 04:41:20 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-arm-kernel-bounces+patch=linaro.org@lists.infradead.org designates 65.50.211.133 as permitted sender) client-ip=65.50.211.133; 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 65.50.211.133 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 1cYBGo-0007CV-Af; Mon, 30 Jan 2017 12:41:18 +0000 Received: from mailout3.w1.samsung.com ([210.118.77.13]) by bombadil.infradead.org with esmtps (Exim 4.87 #1 (Red Hat Linux)) id 1cYBEf-0004b9-LV for linux-arm-kernel@lists.infradead.org; Mon, 30 Jan 2017 12:39:08 +0000 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 <0OKL00D74F4HQZ60@mailout3.w1.samsung.com> for linux-arm-kernel@lists.infradead.org; Mon, 30 Jan 2017 12:38:41 +0000 (GMT) Received: from eusmges3.samsung.com (unknown [203.254.199.242]) by eucas1p2.samsung.com (KnoxPortal) with ESMTP id 20170130123840eucas1p2f33c521ce0ef18f4822b324cb8fe6ceb~ejPdNSIND2844128441eucas1p2T; Mon, 30 Jan 2017 12:38:40 +0000 (GMT) Received: from eucas1p2.samsung.com ( [182.198.249.207]) by eusmges3.samsung.com (EUCPMTA) with SMTP id 07.A7.09557.0D33F885; Mon, 30 Jan 2017 12:38:40 +0000 (GMT) Received: from eusmgms1.samsung.com (unknown [182.198.249.179]) by eucas1p1.samsung.com (KnoxPortal) with ESMTP id 20170130123840eucas1p1cc8877c0968d5da70dc93bdbda344c93~ejPcjYbAI0491204912eucas1p1I; Mon, 30 Jan 2017 12:38:40 +0000 (GMT) X-AuditID: cbfec7f2-f790f6d000002555-f1-588f33d0aa8f Received: from eusync3.samsung.com ( [203.254.199.213]) by eusmgms1.samsung.com (EUCPMTA) with SMTP id D3.D6.06687.3143F885; Mon, 30 Jan 2017 12:39:47 +0000 (GMT) Received: from AMDC2765.digital.local ([106.116.147.25]) by eusync3.samsung.com (Oracle Communications Messaging Server 7.0.5.31.0 64bit (built May 5 2014)) with ESMTPA id <0OKL0038AF49F510@eusync3.samsung.com>; Mon, 30 Jan 2017 12:38:40 +0000 (GMT) From: Marek Szyprowski To: linux-gpio@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-samsung-soc@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH v3 6/7] mfd: exynos-lpass: Add missing remove() function Date: Mon, 30 Jan 2017 13:38:27 +0100 Message-id: <1485779908-32147-7-git-send-email-m.szyprowski@samsung.com> X-Mailer: git-send-email 1.9.1 In-reply-to: <1485779908-32147-1-git-send-email-m.szyprowski@samsung.com> X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFnrIIsWRmVeSWpSXmKPExsWy7djP87oXjPsjDE4fVrHYOGM9q8X58xvY Le5/PcpoMeXPciaLTY+vsVpsnv+H0eLyrjlsFjPO72OyWHvkLrvF4TftrBardv1hdOD22Dnr LrvHplWdbB53ru1h89i8pN6jb8sqRo/Pm+QC2KK4bFJSczLLUov07RK4Mqa33GcreM1Z0T1n P1MD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QouttFxtIQkSg nVHi9e1rTCAOs8AWJomuTRfZQaqEBTwk1q7fAWazCKhKdF59AWbzAsXvzZnOBrFOTuLkscms IDangKfElqeHmCFWe0icv/GfZQIj7wJGhlWMIqmlxbnpucWGesWJucWleel6yfm5mxiB4b/t 2M/NOxgvbQw+xCjAwajEw3tDuC9CiDWxrLgy9xCjBAezkgjvSdX+CCHelMTKqtSi/Pii0pzU 4kOMpkBHTWSWEk3OB8ZmXkm8oYmhuaWhkbGFhbmRkZI4b8mHK+FCAumJJanZqakFqUUwfUwc nFINjEkMTa9X9QQaihTseHj6rFPykZfXmu/+tt93eYrgMz0vvxn/t/j0pxxNuDHrpfb1Q7mz dMRffnZenijwYEHTPuGtzB3XVlm9ZP+vNKFmSxPLiScMTZN9feOY91zWtzHt0SiS3Lx6FmNh reqpFVNWT+Vl6BGv7o/ZJlmp+Sf6xCLdNZzznshzTFBiKc5INNRiLipOBACmeRaClQIAAA== X-MTR: 20000000000000000@CPGS X-CMS-MailID: 20170130123840eucas1p1cc8877c0968d5da70dc93bdbda344c93 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: 20170130123840eucas1p1cc8877c0968d5da70dc93bdbda344c93 X-RootMTR: 20170130123840eucas1p1cc8877c0968d5da70dc93bdbda344c93 References: <1485779908-32147-1-git-send-email-m.szyprowski@samsung.com> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20170130_043906_437221_D9EE2FB8 X-CRM114-Status: GOOD ( 12.39 ) 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.13 listed in list.dnswl.org] -0.0 RCVD_IN_MSPIKE_H3 RBL: Good reputation (+3) [210.118.77.13 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 , Lee Jones , Marek Szyprowski MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patch=linaro.org@lists.infradead.org Disable device on driver remove and release allocated regmap. Signed-off-by: Marek Szyprowski Reviewed-by: Krzysztof Kozlowski Acked-by: Sylwester Nawrocki --- drivers/mfd/exynos-lpass.c | 11 +++++++++++ 1 file changed, 11 insertions(+) -- 1.9.1 _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel diff --git a/drivers/mfd/exynos-lpass.c b/drivers/mfd/exynos-lpass.c index be264988bdc9..9dbbedad916f 100644 --- a/drivers/mfd/exynos-lpass.c +++ b/drivers/mfd/exynos-lpass.c @@ -137,6 +137,16 @@ static int exynos_lpass_probe(struct platform_device *pdev) return of_platform_populate(dev->of_node, NULL, NULL, dev); } +static int exynos_lpass_remove(struct platform_device *pdev) +{ + struct exynos_lpass *lpass = platform_get_drvdata(pdev); + + exynos_lpass_disable(lpass); + regmap_exit(lpass->top); + + return 0; +} + static int __maybe_unused exynos_lpass_suspend(struct device *dev) { struct exynos_lpass *lpass = dev_get_drvdata(dev); @@ -171,6 +181,7 @@ static SIMPLE_DEV_PM_OPS(lpass_pm_ops, exynos_lpass_suspend, .of_match_table = exynos_lpass_of_match, }, .probe = exynos_lpass_probe, + .remove = exynos_lpass_remove, }; module_platform_driver(exynos_lpass_driver); From patchwork Mon Jan 30 12:38:28 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Marek Szyprowski X-Patchwork-Id: 92852 Delivered-To: patch@linaro.org Received: by 10.140.20.99 with SMTP id 90csp1413103qgi; Mon, 30 Jan 2017 04:41:09 -0800 (PST) X-Received: by 10.98.73.130 with SMTP id r2mr22653777pfi.182.1485780068936; Mon, 30 Jan 2017 04:41:08 -0800 (PST) Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id j9si12507861pfc.290.2017.01.30.04.41.08; Mon, 30 Jan 2017 04:41:08 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-gpio-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-gpio-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-gpio-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752758AbdA3MlC (ORCPT + 4 others); Mon, 30 Jan 2017 07:41:02 -0500 Received: from mailout4.w1.samsung.com ([210.118.77.14]:43067 "EHLO mailout4.w1.samsung.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751277AbdA3MlB (ORCPT ); Mon, 30 Jan 2017 07:41:01 -0500 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 <0OKL0062BF4I7L60@mailout4.w1.samsung.com>; Mon, 30 Jan 2017 12:38:42 +0000 (GMT) Received: from eusmges3.samsung.com (unknown [203.254.199.242]) by eucas1p2.samsung.com (KnoxPortal) with ESMTP id 20170130123841eucas1p2df5eab7b5676b8ffa41ba04d7239f4fb~ejPeDiuqa0359803598eucas1p25; Mon, 30 Jan 2017 12:38:41 +0000 (GMT) Received: from eucas1p1.samsung.com ( [182.198.249.206]) by eusmges3.samsung.com (EUCPMTA) with SMTP id E7.A7.09557.1D33F885; Mon, 30 Jan 2017 12:38:41 +0000 (GMT) Received: from eusmgms2.samsung.com (unknown [182.198.249.180]) by eucas1p2.samsung.com (KnoxPortal) with ESMTP id 20170130123840eucas1p20025e600860b43b2da81d9063f96e442~ejPdQLgzY1821218212eucas1p2H; Mon, 30 Jan 2017 12:38:40 +0000 (GMT) X-AuditID: cbfec7f2-f790f6d000002555-f4-588f33d1ee79 Received: from eusync3.samsung.com ( [203.254.199.213]) by eusmgms2.samsung.com (EUCPMTA) with SMTP id 91.76.10233.FC33F885; Mon, 30 Jan 2017 12:38:39 +0000 (GMT) Received: from AMDC2765.digital.local ([106.116.147.25]) by eusync3.samsung.com (Oracle Communications Messaging Server 7.0.5.31.0 64bit (built May 5 2014)) with ESMTPA id <0OKL0038AF49F510@eusync3.samsung.com>; Mon, 30 Jan 2017 12:38:40 +0000 (GMT) From: Marek Szyprowski To: linux-gpio@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-samsung-soc@vger.kernel.org, linux-kernel@vger.kernel.org Cc: Marek Szyprowski , Sylwester Nawrocki , Krzysztof Kozlowski , Linus Walleij , Tomasz Figa , Lee Jones , Bartlomiej Zolnierkiewicz Subject: [PATCH v3 7/7] mfd: exynos-lpass: Add runtime PM support Date: Mon, 30 Jan 2017 13:38:28 +0100 Message-id: <1485779908-32147-8-git-send-email-m.szyprowski@samsung.com> X-Mailer: git-send-email 1.9.1 In-reply-to: <1485779908-32147-1-git-send-email-m.szyprowski@samsung.com> X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFrrHIsWRmVeSWpSXmKPExsWy7djPc7oXjfsjDI7Mk7fYOGM9q8X58xvY Le5/PcpoMeXPciaLTY+vsVpsnv+H0eLyrjlsFjPO72OyWHvkLrvF4TftrBardv1hdOD22Dnr LrvHplWdbB53ru1h89i8pN6jb8sqRo/Pm+QC2KK4bFJSczLLUov07RK4Mm6sYC9YLFAxd+Jr 1gbGT7xdjJwcEgImEke/fmGBsMUkLtxbzwZiCwksZZRoaTDvYuQCsj8zSpz70sgC09B5djsr RNEyRonutlyIogYmib3TZ4F1swkYSnS97WIDSYgItDNK3O3rYAJxmAU2MUm0LTnBDFIlLOAo 8e74PrCxLAKqEm8fvgaKc3DwCnhIXLtqALFNTuLksclg2zgFPCW2PD3EDDJHQmAeu8TzTVPB 6iUEZCU2HWCGqHeReLvqE9SlwhKvjm9hh7BlJC5P7oaK9zNKNLVqQ9gzgF57Cw0Ka4nDxy+C 7WIW4JOYtG061HheiY42IYgSD4n+ro1QYUeJuxMkIH6fwyixYfMKxgmMMgsYGVYxiqSWFuem pxYb6xUn5haX5qXrJefnbmIExvrpf8c/7WD8esLqEKMAB6MSD+8N4b4IIdbEsuLK3EOMEhzM SiK8J1X7I4R4UxIrq1KL8uOLSnNSiw8xSnOwKInz7llwJVxIID2xJDU7NbUgtQgmy8TBKdXA WMtgnHBZK+H46lfWmr9XR12U9p5y9OOu6MA8kUw/gS0b/tVtkfpVdiOrQEbpUo1FmmPfkv7U g9MT1r85dlBh2Q6pqm33rMKfhN1Z/Ga7pZ6qfBST56z5ri7rK0u+vp+5KMLr/AL5srCLV6bs mVmYLJy4UKxxUnO95rxtwlaSfVOuTLE5+pHRVImlOCPRUIu5qDgRAOk/uxrxAgAA X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFmpkkeLIzCtJLcpLzFFi42I5/e/4Vd3zxv0RBl+mKlhsnLGe1eL8+Q3s Fve/HmW0mPJnOZPFpsfXWC02z//DaHF51xw2ixnn9zFZrD1yl93i8Jt2VotVu/4wOnB77Jx1 l91j06pONo871/aweWxeUu/Rt2UVo8fnTXIBbFFuNhmpiSmpRQqpecn5KZl56bZKoSFuuhZK CnmJuam2ShG6viFBSgpliTmlQJ6RARpwcA5wD1bSt0twy7ixgr1gsUDF3ImvWRsYP/F2MXJy SAiYSHSe3c4KYYtJXLi3nq2LkYtDSGAJo0TDgy/sEE4Tk8TSU4sZQarYBAwlut52gVWJCLQz Sry+fY0JxGEW2MIk0bXpIjtIlbCAo8S74/tYQGwWAVWJtw9fM3cxcnDwCnhIXLtqALFOTuLk sclgqzkFPCW2PD3EDGILAZWcv/GfZQIj7wJGhlWMIqmlxbnpucVGesWJucWleel6yfm5mxiB wb/t2M8tOxi73gUfYhTgYFTi4b0h3BchxJpYVlyZe4hRgoNZSYT3pGp/hBBvSmJlVWpRfnxR aU5q8SFGU6CbJjJLiSbnAyMzryTe0MTQ3NLQyNjCwtzISEmcd+qHK+FCAumJJanZqakFqUUw fUwcnFINjAyvEq7bPjv55Wf619wLElK3b747fOrZp7THGsu7I5jdvyRVibpy79d2+v/z5Y/n jfsPSs0OO+Hl6vX5gVX0357b8+Yd/3tr5bJl/pMfzCtavXmWxAyxxDXrypqmP+PTmOR69PV7 x5COQMu8OJtLJfc1JpdcSv4S3bzUXPNj0IX18oX3p9z0UYhRYinOSDTUYi4qTgQAZy8BLZQC AAA= X-MTR: 20000000000000000@CPGS X-CMS-MailID: 20170130123840eucas1p20025e600860b43b2da81d9063f96e442 X-Msg-Generator: CA X-Sender-IP: 182.198.249.180 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: 20170130123840eucas1p20025e600860b43b2da81d9063f96e442 X-RootMTR: 20170130123840eucas1p20025e600860b43b2da81d9063f96e442 References: <1485779908-32147-1-git-send-email-m.szyprowski@samsung.com> Sender: linux-gpio-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-gpio@vger.kernel.org Convert exisitng lpass-suspend/resume callbacks into runtime PM callbacks. This way Exynos LPASS driver will be ready for use with power domains enabled. LPASS will be runtime resumed/suspended as a result of its child devices runtime PM transitions. Signed-off-by: Marek Szyprowski Acked-by: Krzysztof Kozlowski Acked-by: Sylwester Nawrocki --- drivers/mfd/exynos-lpass.c | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) -- 1.9.1 -- To unsubscribe from this list: send the line "unsubscribe linux-gpio" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html diff --git a/drivers/mfd/exynos-lpass.c b/drivers/mfd/exynos-lpass.c index 9dbbedad916f..6d735e22acda 100644 --- a/drivers/mfd/exynos-lpass.c +++ b/drivers/mfd/exynos-lpass.c @@ -22,6 +22,7 @@ #include #include #include +#include #include #include @@ -132,6 +133,8 @@ static int exynos_lpass_probe(struct platform_device *pdev) } platform_set_drvdata(pdev, lpass); + pm_runtime_set_active(dev); + pm_runtime_enable(dev); exynos_lpass_enable(lpass); return of_platform_populate(dev->of_node, NULL, NULL, dev); @@ -141,7 +144,9 @@ static int exynos_lpass_remove(struct platform_device *pdev) { struct exynos_lpass *lpass = platform_get_drvdata(pdev); - exynos_lpass_disable(lpass); + pm_runtime_disable(&pdev->dev); + if (!pm_runtime_status_suspended(&pdev->dev)) + exynos_lpass_disable(lpass); regmap_exit(lpass->top); return 0; @@ -165,8 +170,11 @@ static int __maybe_unused exynos_lpass_resume(struct device *dev) return 0; } -static SIMPLE_DEV_PM_OPS(lpass_pm_ops, exynos_lpass_suspend, - exynos_lpass_resume); +static const struct dev_pm_ops lpass_pm_ops = { + SET_RUNTIME_PM_OPS(exynos_lpass_suspend, exynos_lpass_resume, NULL) + SET_LATE_SYSTEM_SLEEP_PM_OPS(pm_runtime_force_suspend, + pm_runtime_force_resume) +}; static const struct of_device_id exynos_lpass_of_match[] = { { .compatible = "samsung,exynos5433-lpass" },