Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp490868imu; Tue, 27 Nov 2018 01:40:16 -0800 (PST) X-Google-Smtp-Source: AJdET5f2MV0DJDVFmk7zTrwW6u+PY6caHAYyD+epTzP6KuYpPA/QM/t1hUvId94QOiE3/dBrtkcO X-Received: by 2002:a63:dd15:: with SMTP id t21mr27593854pgg.347.1543311616411; Tue, 27 Nov 2018 01:40:16 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1543311616; cv=none; d=google.com; s=arc-20160816; b=rsD0gPH+RBv4LivOlcE05RpYrbwA7i4y4iMJXNBSFnUEb76UIHuVbOVv3tEPepvaZz Us8Z1wZMbWcayyq6DVxVakBGlOvH154iOroseeWC/P/sP0Fj//wALn9rbxgbZXXpGXgE kYn9bmq6Mk9n/ylfp5yiLUvAubPvtXHT4IHIcxKonUifqlLsb+RQ+hyKoU4sWh8hlbWu PdC0+f5XY6PsYzAStlOx+qzJxhyEuJ+JSh7hnVFa9bfo+f3LAwkYTamaE35Fg/hQuCm/ YzFGLTTC1leAz2CUP2z8UQ4kqQiUkT9c1Od2tFdVHNqxVCZh7UUa4lL/JSE613DqxmO+ FQlQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date; bh=RxrH2KYxCf/s4cfyauQqhZYXXCOweCNht/8IwCaMVKk=; b=B8BVEiGi8dFmTkUqe5D5h/AhBjkoUUc6+ernbRgoasj3T4v8Wm/e8eadKxFRHBDxcI JNir7TvgOwFNJBtqHi+w39sebZ+MXthbDJO/irBFJvH1jZDO2fdxwmlXBGRyevYSIRk/ FqEq4rFhZtQQ1Ngrja0QVDr3AjbhMa0Og9PtLZqfg1MPGu7x1k7u12VyvUVk4briJ9Ir 1jk60JG8Jbp98xtSHhCjsXlbjWNZUaUvQLAJmeeWKGSxoaEoTHxF+v9NMPjAch9xy77v Dqco4m+OWMHLi7Pco8t255+Tw/6Nlst0LziZb7skrkC0cGk/JsTByor5UtDKk5OOY4qI s0KA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 34si3300901pgt.455.2018.11.27.01.40.01; Tue, 27 Nov 2018 01:40:16 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-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-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1730309AbeK0UgX (ORCPT + 99 others); Tue, 27 Nov 2018 15:36:23 -0500 Received: from mail.bootlin.com ([62.4.15.54]:60410 "EHLO mail.bootlin.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729387AbeK0UgW (ORCPT ); Tue, 27 Nov 2018 15:36:22 -0500 Received: by mail.bootlin.com (Postfix, from userid 110) id 4207520DC1; Tue, 27 Nov 2018 10:39:02 +0100 (CET) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on mail.bootlin.com X-Spam-Level: X-Spam-Status: No, score=-1.0 required=5.0 tests=ALL_TRUSTED,SHORTCIRCUIT, URIBL_BLOCKED shortcircuit=ham autolearn=disabled version=3.4.2 Received: from localhost (aaubervilliers-681-1-94-205.w90-88.abo.wanadoo.fr [90.88.35.205]) by mail.bootlin.com (Postfix) with ESMTPSA id 0B249207BC; Tue, 27 Nov 2018 10:38:52 +0100 (CET) Date: Tue, 27 Nov 2018 10:38:52 +0100 From: Maxime Ripard To: Priit Laes Cc: Lee Jones , Rob Herring , Mark Rutland , Chen-Yu Tsai , Sebastian Reichel , Hans de Goede , Liam Girdwood , Mark Brown , devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-pm@vger.kernel.org, Olliver Schinagl Subject: Re: [PATCH 09/14] regulator: dts: add full voltage range to LDO4 on the Lime2 Message-ID: <20181127093852.2iavgo4xipjnu25l@flea> References: <0b1aa5b28cb5efe17c04150a181ef1fa4027bc55.1543245984.git-series.plaes@plaes.org> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="s266jt4lvjzpsbth" Content-Disposition: inline In-Reply-To: <0b1aa5b28cb5efe17c04150a181ef1fa4027bc55.1543245984.git-series.plaes@plaes.org> User-Agent: NeoMutt/20180716 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org --s266jt4lvjzpsbth Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Mon, Nov 26, 2018 at 05:27:50PM +0200, Priit Laes wrote: > From: Olliver Schinagl >=20 > With commit b43776d65a33b46092 ("ARM: dts: sunxi: Use axp209.dtsi for > Olinuxino Lime2") we force them an arbitrary 2.8 volts. Granted, for > LDO3 this may be less arbitrary, but for LDO4 this is just wrong. >=20 > In the defense of LDO3, LDO3 is the regulator that feeds port bank E, > which has no other purpose then a CSI/TS interface, however the case > may still be, that the connected IO may be just as well be 3.3 volts. > The big misnomer is however, that the schematic names GPIO-2 pin4 > LDO3_2.8V, rather then VDD-CSI0 or similar. >=20 > This is much worse for LDO4 however, which is not referenced on any > pin, is now set to 2.8 volts, but port bank G can also support various > other peripherals such as UARTS etc. >=20 > By having 2.8 volts however for LDO4, we thus now have peripherals that > no longer function properly all of the time. >=20 > Ideally, we want to set a supply voltage for each port bank, but the > monolithic nature of the sunxi pinctroller currently prevents this and > as such, the board should at least configure the LDO4 with the proper > ranges. >=20 > Until we can set the consumer at the port bank level, a child > device-tree has to do something like: >=20 > ®_ldo4 { > regulator-min-microvolt =3D <3300000>; > regulator-max-microvolt =3D <3300000>; > }; >=20 > While doing this the same way results in the same solution currently, > we force the hack into the final devicetree rather then having it wrong > at the board level. >=20 > Signed-off-by: Olliver Schinagl > Signed-off-by: Priit Laes > --- > arch/arm/boot/dts/sun7i-a20-olinuxino-lime2.dts | 7 ++++--- > 1 file changed, 4 insertions(+), 3 deletions(-) >=20 > diff --git a/arch/arm/boot/dts/sun7i-a20-olinuxino-lime2.dts b/arch/arm/b= oot/dts/sun7i-a20-olinuxino-lime2.dts > index ffafe97..1b9867f 100644 > --- a/arch/arm/boot/dts/sun7i-a20-olinuxino-lime2.dts > +++ b/arch/arm/boot/dts/sun7i-a20-olinuxino-lime2.dts > @@ -250,9 +250,10 @@ > }; > =20 > ®_ldo4 { > - regulator-min-microvolt =3D <2800000>; > - regulator-max-microvolt =3D <2800000>; > - regulator-name =3D "vddio-csi1"; > + regulator-always-on; > + regulator-min-microvolt =3D <1250000>; > + regulator-max-microvolt =3D <3300000>; > + regulator-name =3D "vdd-io-pg"; As we discussed on the U-Boot ML already, this shouldn't be made always-on but tied to the consumer device (the pinctrl one) instead. Maxime --=20 Maxime Ripard, Bootlin Embedded Linux and Kernel engineering https://bootlin.com --s266jt4lvjzpsbth Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iHUEABYIAB0WIQRcEzekXsqa64kGDp7j7w1vZxhRxQUCW/0QrAAKCRDj7w1vZxhR xZZnAPwIkVhLkkgCn/HCrcBTkkjwKsYRgF/IguR7rOKWCTFwbwEAxJShw5bv1q7y rGkR9lCewrTvrbD4r/hWHDcD0z0CZwQ= =gn1w -----END PGP SIGNATURE----- --s266jt4lvjzpsbth--