From patchwork Mon Jan 5 11:48:45 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Krzysztof Kozlowski X-Patchwork-Id: 5567091 Return-Path: X-Original-To: patchwork-linux-samsung-soc@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork1.web.kernel.org (Postfix) with ESMTP id AA65E9F357 for ; Mon, 5 Jan 2015 11:51:33 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id CC3012014A for ; Mon, 5 Jan 2015 11:51:32 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 3514320165 for ; Mon, 5 Jan 2015 11:51:31 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753287AbbAELuz (ORCPT ); Mon, 5 Jan 2015 06:50:55 -0500 Received: from mailout4.w1.samsung.com ([210.118.77.14]:41973 "EHLO mailout4.w1.samsung.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753451AbbAELuy (ORCPT ); Mon, 5 Jan 2015 06:50:54 -0500 Received: from eucpsbgm2.samsung.com (unknown [203.254.199.245]) by mailout4.w1.samsung.com (Oracle Communications Messaging Server 7u4-24.01(7.0.4.24.0) 64bit (built Nov 17 2011)) with ESMTP id <0NHP00IN6D3GMVA0@mailout4.w1.samsung.com>; Mon, 05 Jan 2015 11:54:52 +0000 (GMT) X-AuditID: cbfec7f5-b7fc86d0000066b7-bf-54aa7a9b21f1 Received: from eusync1.samsung.com ( [203.254.199.211]) by eucpsbgm2.samsung.com (EUCPMTA) with SMTP id 9B.71.26295.B9A7AA45; Mon, 05 Jan 2015 11:50:51 +0000 (GMT) Received: from AMDC1943.digital.local ([106.116.151.171]) by eusync1.samsung.com (Oracle Communications Messaging Server 7u4-23.01(7.0.4.23.0) 64bit (built Aug 10 2011)) with ESMTPA id <0NHP00IYMCWKJI90@eusync1.samsung.com>; Mon, 05 Jan 2015 11:50:50 +0000 (GMT) From: Krzysztof Kozlowski To: Liam Girdwood , Mark Brown , linux-kernel@vger.kernel.org, Kukjin Kim , devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-samsung-soc@vger.kernel.org Cc: Kyungmin Park , Bartlomiej Zolnierkiewicz , Krzysztof Kozlowski Subject: [PATCH v5 5/5] ARM: dts: exynos4412-trats: Switch max77686 regulators to GPIO control Date: Mon, 05 Jan 2015 12:48:45 +0100 Message-id: <1420458525-22576-6-git-send-email-k.kozlowski@samsung.com> X-Mailer: git-send-email 1.9.1 In-reply-to: <1420458525-22576-1-git-send-email-k.kozlowski@samsung.com> References: <1420458525-22576-1-git-send-email-k.kozlowski@samsung.com> X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFmpmluLIzCtJLcpLzFFi42I5/e/4Zd3ZVatCDC52yFhsnLGe1WLqwyds FvOPnGO1eP3C0KL/8Wtmi7NNb9gtvl3pYLLY9Pgaq8XlXXPYLGac38fkwOWxc9Zddo9NqzrZ PDYvqffo27KK0ePzJrkA1igum5TUnMyy1CJ9uwSujDcrzrIUPJGouD31C0sD4xHhLkZODgkB E4kJry+zQdhiEhfurQeyuTiEBJYySvzum8kM4fQxSWxbd5IJpIpNwFhi8/IlYFUiAh8YJVZN +sEK4jALTGOUuHDqO1ALB4ewQIJE92slkAYWAVWJ8z+vM4KEeQXcJe5/zYfYJidx8thkVhCb U8BDouvpJ2YQWwioZNrOZuYJjLwLGBlWMYqmliYXFCel5xrpFSfmFpfmpesl5+duYoQE3Ncd jEuPWR1iFOBgVOLh9TixMkSINbGsuDL3EKMEB7OSCO+r9FUhQrwpiZVVqUX58UWlOanFhxiZ ODilGhhvHPW6XC7xfN23f0dvxhTcvX5ZRiT8nkyEaACL9pqsk+YLt7XEhs2WTk90Dvg7vatn 6dWVVpee7rWJPel04vfxnhVXDrGtEtA7w7Azdo/9/bDLL/5NuR5257Bhn8MGs62H1RtP88sv 6Xo6I7hxIZOSn/f5rom/FKKfZpXt8L1/KkDaUexLquh8JZbijERDLeai4kQAl40D5BYCAAA= Sender: linux-samsung-soc-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-samsung-soc@vger.kernel.org X-Spam-Status: No, score=-6.9 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, T_RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Remove fixed regulators (duplicating what max77686 provides) and add GPIO enable control to max77686 regulators. This gives the system full control over those regulators. Previously the state of such regulators was a mixture of what max77686 driver set over I2C and what regulator-fixed set through GPIO. Removal of 'regulator-always-on' from CAM_ISP_CORE_1.2V (buck9) allows disabling it when it is not used. Previously this regulator was always enabled because its enable state is a OR of: - ENB9 GPIO (turned always on by regulator-fixed), - BUCK9EN field in BUCK9CTRL register (off by max77686 through I2C). Signed-off-by: Krzysztof Kozlowski --- arch/arm/boot/dts/exynos4412-trats2.dts | 25 +++++-------------------- 1 file changed, 5 insertions(+), 20 deletions(-) diff --git a/arch/arm/boot/dts/exynos4412-trats2.dts b/arch/arm/boot/dts/exynos4412-trats2.dts index 405d4f337e89..186c210680c1 100644 --- a/arch/arm/boot/dts/exynos4412-trats2.dts +++ b/arch/arm/boot/dts/exynos4412-trats2.dts @@ -58,15 +58,6 @@ #address-cells = <1>; #size-cells = <0>; - vemmc_reg: regulator-0 { - compatible = "regulator-fixed"; - regulator-name = "VMEM_VDD_2.8V"; - regulator-min-microvolt = <2800000>; - regulator-max-microvolt = <2800000>; - gpio = <&gpk0 2 0>; - enable-active-high; - }; - cam_io_reg: voltage-regulator-1 { compatible = "regulator-fixed"; regulator-name = "CAM_SENSOR_A"; @@ -94,16 +85,6 @@ enable-active-high; }; - cam_isp_core_reg: voltage-regulator-4 { - compatible = "regulator-fixed"; - regulator-name = "CAM_ISP_CORE_1.2V_EN"; - regulator-min-microvolt = <1200000>; - regulator-max-microvolt = <1200000>; - gpio = <&gpm0 3 0>; - enable-active-high; - regulator-always-on; - }; - ps_als_reg: voltage-regulator-5 { compatible = "regulator-fixed"; regulator-name = "LED_A_3.0V"; @@ -405,6 +386,7 @@ regulator-name = "VTF_2.8V"; regulator-min-microvolt = <2800000>; regulator-max-microvolt = <2800000>; + maxim,ena-gpios = <&gpy2 0 GPIO_ACTIVE_HIGH>; }; ldo22_reg: ldo22 { @@ -412,6 +394,7 @@ regulator-name = "VMEM_VDD_2.8V"; regulator-min-microvolt = <2800000>; regulator-max-microvolt = <2800000>; + maxim,ena-gpios = <&gpk0 2 GPIO_ACTIVE_HIGH>; }; ldo23_reg: ldo23 { @@ -518,6 +501,7 @@ regulator-name = "VMEM_VDDF_3.0V"; regulator-min-microvolt = <2850000>; regulator-max-microvolt = <2850000>; + maxim,ena-gpios = <&gpk0 2 GPIO_ACTIVE_HIGH>; }; buck9_reg: buck9 { @@ -525,6 +509,7 @@ regulator-name = "CAM_ISP_CORE_1.2V"; regulator-min-microvolt = <1000000>; regulator-max-microvolt = <1200000>; + maxim,ena-gpios = <&gpm0 3 GPIO_ACTIVE_HIGH>; }; }; }; @@ -587,7 +572,7 @@ broken-cd; non-removable; card-detect-delay = <200>; - vmmc-supply = <&vemmc_reg>; + vmmc-supply = <&ldo22_reg>; clock-frequency = <400000000>; samsung,dw-mshc-ciu-div = <0>; samsung,dw-mshc-sdr-timing = <2 3>;