diff mbox series

[3/9] arm64: dts: allwinner: pinebook: Remove unused AXP803 regulators

Message ID 20200119163104.13274-3-samuel@sholland.org (mailing list archive)
State Mainlined
Commit 4e0e6a626bf4c35e043b4d547e91447f06139d27
Headers show
Series [1/9] arm64: dts: allwinner: Enable button wakeup on Orange Pi PC2 | expand

Commit Message

Samuel Holland Jan. 19, 2020, 4:30 p.m. UTC
The Pinebook does not use the CSI bus on the A64. In fact it does not
use GPIO port E for anything at all. Thus the following regulators are
not used and do not need voltages set:

 - ALDO1: Connected to VCC-PE only
 - DLDO3: Not connected
 - ELDO3: Not connected

Signed-off-by: Samuel Holland <samuel@sholland.org>
---
 .../boot/dts/allwinner/sun50i-a64-pinebook.dts   | 16 +---------------
 1 file changed, 1 insertion(+), 15 deletions(-)

Comments

Maxime Ripard Jan. 21, 2020, 9:05 a.m. UTC | #1
On Sun, Jan 19, 2020 at 10:30:58AM -0600, Samuel Holland wrote:
> The Pinebook does not use the CSI bus on the A64. In fact it does not
> use GPIO port E for anything at all. Thus the following regulators are
> not used and do not need voltages set:
>
>  - ALDO1: Connected to VCC-PE only
>  - DLDO3: Not connected
>  - ELDO3: Not connected
>
> Signed-off-by: Samuel Holland <samuel@sholland.org>
> ---
>  .../boot/dts/allwinner/sun50i-a64-pinebook.dts   | 16 +---------------
>  1 file changed, 1 insertion(+), 15 deletions(-)
>
> diff --git a/arch/arm64/boot/dts/allwinner/sun50i-a64-pinebook.dts b/arch/arm64/boot/dts/allwinner/sun50i-a64-pinebook.dts
> index ff32ca1a495e..8e7ce6ad28dd 100644
> --- a/arch/arm64/boot/dts/allwinner/sun50i-a64-pinebook.dts
> +++ b/arch/arm64/boot/dts/allwinner/sun50i-a64-pinebook.dts
> @@ -202,9 +202,7 @@
>  };
>
>  &reg_aldo1 {
> -	regulator-min-microvolt = <2800000>;
> -	regulator-max-microvolt = <2800000>;
> -	regulator-name = "vcc-csi";
> +	regulator-name = "vcc-pe";
>  };

If it's connected to PE, I'd expect the voltage to be at 3.3v?

Maxime
Vasily Khoruzhick Jan. 21, 2020, 6:49 p.m. UTC | #2
On Tue, Jan 21, 2020 at 1:05 AM Maxime Ripard <mripard@kernel.org> wrote:
>
> On Sun, Jan 19, 2020 at 10:30:58AM -0600, Samuel Holland wrote:
> > The Pinebook does not use the CSI bus on the A64. In fact it does not
> > use GPIO port E for anything at all. Thus the following regulators are
> > not used and do not need voltages set:
> >
> >  - ALDO1: Connected to VCC-PE only
> >  - DLDO3: Not connected
> >  - ELDO3: Not connected
> >
> > Signed-off-by: Samuel Holland <samuel@sholland.org>
> > ---
> >  .../boot/dts/allwinner/sun50i-a64-pinebook.dts   | 16 +---------------
> >  1 file changed, 1 insertion(+), 15 deletions(-)
> >
> > diff --git a/arch/arm64/boot/dts/allwinner/sun50i-a64-pinebook.dts b/arch/arm64/boot/dts/allwinner/sun50i-a64-pinebook.dts
> > index ff32ca1a495e..8e7ce6ad28dd 100644
> > --- a/arch/arm64/boot/dts/allwinner/sun50i-a64-pinebook.dts
> > +++ b/arch/arm64/boot/dts/allwinner/sun50i-a64-pinebook.dts
> > @@ -202,9 +202,7 @@
> >  };
> >
> >  &reg_aldo1 {
> > -     regulator-min-microvolt = <2800000>;
> > -     regulator-max-microvolt = <2800000>;
> > -     regulator-name = "vcc-csi";
> > +     regulator-name = "vcc-pe";
> >  };
>
> If it's connected to PE, I'd expect the voltage to be at 3.3v?

Commit message says that PE is not used, so we don't need to set it at all.

> Maxime
> _______________________________________________
> linux-arm-kernel mailing list
> linux-arm-kernel@lists.infradead.org
> http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
Samuel Holland Jan. 22, 2020, 3:14 a.m. UTC | #3
On 1/21/20 3:05 AM, Maxime Ripard wrote:
> On Sun, Jan 19, 2020 at 10:30:58AM -0600, Samuel Holland wrote:
>> The Pinebook does not use the CSI bus on the A64. In fact it does not
>> use GPIO port E for anything at all. Thus the following regulators are
>> not used and do not need voltages set:
>>
>>  - ALDO1: Connected to VCC-PE only
>>  - DLDO3: Not connected
>>  - ELDO3: Not connected
>>
>> Signed-off-by: Samuel Holland <samuel@sholland.org>
>> ---
>>  .../boot/dts/allwinner/sun50i-a64-pinebook.dts   | 16 +---------------
>>  1 file changed, 1 insertion(+), 15 deletions(-)
>>
>> diff --git a/arch/arm64/boot/dts/allwinner/sun50i-a64-pinebook.dts b/arch/arm64/boot/dts/allwinner/sun50i-a64-pinebook.dts
>> index ff32ca1a495e..8e7ce6ad28dd 100644
>> --- a/arch/arm64/boot/dts/allwinner/sun50i-a64-pinebook.dts
>> +++ b/arch/arm64/boot/dts/allwinner/sun50i-a64-pinebook.dts
>> @@ -202,9 +202,7 @@
>>  };
>>
>>  &reg_aldo1 {
>> -	regulator-min-microvolt = <2800000>;
>> -	regulator-max-microvolt = <2800000>;
>> -	regulator-name = "vcc-csi";
>> +	regulator-name = "vcc-pe";
>>  };
> 
> If it's connected to PE, I'd expect the voltage to be at 3.3v?

If we provide voltage constraints, the regulator core will enable the regulator
and set its voltage at boot. That seems like a bit of a waste.

I don't think the voltage really matters, since nothing is plugged in to the
port. ALDO1 can't go over 3.3V anyway, so even if it does get turned on for some
reason, nothing will get damaged.

Samuel
Maxime Ripard Jan. 24, 2020, 4:33 p.m. UTC | #4
On Tue, Jan 21, 2020 at 09:14:02PM -0600, Samuel Holland wrote:
> On 1/21/20 3:05 AM, Maxime Ripard wrote:
> > On Sun, Jan 19, 2020 at 10:30:58AM -0600, Samuel Holland wrote:
> >> The Pinebook does not use the CSI bus on the A64. In fact it does not
> >> use GPIO port E for anything at all. Thus the following regulators are
> >> not used and do not need voltages set:
> >>
> >>  - ALDO1: Connected to VCC-PE only
> >>  - DLDO3: Not connected
> >>  - ELDO3: Not connected
> >>
> >> Signed-off-by: Samuel Holland <samuel@sholland.org>
> >> ---
> >>  .../boot/dts/allwinner/sun50i-a64-pinebook.dts   | 16 +---------------
> >>  1 file changed, 1 insertion(+), 15 deletions(-)
> >>
> >> diff --git a/arch/arm64/boot/dts/allwinner/sun50i-a64-pinebook.dts b/arch/arm64/boot/dts/allwinner/sun50i-a64-pinebook.dts
> >> index ff32ca1a495e..8e7ce6ad28dd 100644
> >> --- a/arch/arm64/boot/dts/allwinner/sun50i-a64-pinebook.dts
> >> +++ b/arch/arm64/boot/dts/allwinner/sun50i-a64-pinebook.dts
> >> @@ -202,9 +202,7 @@
> >>  };
> >>
> >>  &reg_aldo1 {
> >> -	regulator-min-microvolt = <2800000>;
> >> -	regulator-max-microvolt = <2800000>;
> >> -	regulator-name = "vcc-csi";
> >> +	regulator-name = "vcc-pe";
> >>  };
> >
> > If it's connected to PE, I'd expect the voltage to be at 3.3v?
>
> If we provide voltage constraints, the regulator core will enable the regulator
> and set its voltage at boot. That seems like a bit of a waste.

I'm not sure the regulator core enables them if there's neither
regulator-boot-on nor regulator-always-on.

> I don't think the voltage really matters, since nothing is plugged in to the
> port. ALDO1 can't go over 3.3V anyway, so even if it does get turned on for some
> reason, nothing will get damaged.

Looking at the schematics, it looks like the PE pins are connected to
the front-facing camera?

Maxime
Vasily Khoruzhick Jan. 24, 2020, 11:11 p.m. UTC | #5
On Fri, Jan 24, 2020 at 8:36 AM Maxime Ripard <maxime@cerno.tech> wrote:
>
> On Tue, Jan 21, 2020 at 09:14:02PM -0600, Samuel Holland wrote:
> > On 1/21/20 3:05 AM, Maxime Ripard wrote:
> > > On Sun, Jan 19, 2020 at 10:30:58AM -0600, Samuel Holland wrote:
> > >> The Pinebook does not use the CSI bus on the A64. In fact it does not
> > >> use GPIO port E for anything at all. Thus the following regulators are
> > >> not used and do not need voltages set:
> > >>
> > >>  - ALDO1: Connected to VCC-PE only
> > >>  - DLDO3: Not connected
> > >>  - ELDO3: Not connected
> > >>
> > >> Signed-off-by: Samuel Holland <samuel@sholland.org>
> > >> ---
> > >>  .../boot/dts/allwinner/sun50i-a64-pinebook.dts   | 16 +---------------
> > >>  1 file changed, 1 insertion(+), 15 deletions(-)
> > >>
> > >> diff --git a/arch/arm64/boot/dts/allwinner/sun50i-a64-pinebook.dts b/arch/arm64/boot/dts/allwinner/sun50i-a64-pinebook.dts
> > >> index ff32ca1a495e..8e7ce6ad28dd 100644
> > >> --- a/arch/arm64/boot/dts/allwinner/sun50i-a64-pinebook.dts
> > >> +++ b/arch/arm64/boot/dts/allwinner/sun50i-a64-pinebook.dts
> > >> @@ -202,9 +202,7 @@
> > >>  };
> > >>
> > >>  &reg_aldo1 {
> > >> -  regulator-min-microvolt = <2800000>;
> > >> -  regulator-max-microvolt = <2800000>;
> > >> -  regulator-name = "vcc-csi";
> > >> +  regulator-name = "vcc-pe";
> > >>  };
> > >
> > > If it's connected to PE, I'd expect the voltage to be at 3.3v?
> >
> > If we provide voltage constraints, the regulator core will enable the regulator
> > and set its voltage at boot. That seems like a bit of a waste.
>
> I'm not sure the regulator core enables them if there's neither
> regulator-boot-on nor regulator-always-on.
>
> > I don't think the voltage really matters, since nothing is plugged in to the
> > port. ALDO1 can't go over 3.3V anyway, so even if it does get turned on for some
> > reason, nothing will get damaged.
>
> Looking at the schematics, it looks like the PE pins are connected to
> the front-facing camera?

The only camera on Pinebook is UVC

>
> Maxime
>
> _______________________________________________
> linux-arm-kernel mailing list
> linux-arm-kernel@lists.infradead.org
> http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
Maxime Ripard Feb. 14, 2020, 3:03 p.m. UTC | #6
On Sun, Jan 19, 2020 at 10:30:58AM -0600, Samuel Holland wrote:
> The Pinebook does not use the CSI bus on the A64. In fact it does not
> use GPIO port E for anything at all. Thus the following regulators are
> not used and do not need voltages set:
>
>  - ALDO1: Connected to VCC-PE only
>  - DLDO3: Not connected
>  - ELDO3: Not connected
>
> Signed-off-by: Samuel Holland <samuel@sholland.org>

Applied, thanks!
Maxime
diff mbox series

Patch

diff --git a/arch/arm64/boot/dts/allwinner/sun50i-a64-pinebook.dts b/arch/arm64/boot/dts/allwinner/sun50i-a64-pinebook.dts
index ff32ca1a495e..8e7ce6ad28dd 100644
--- a/arch/arm64/boot/dts/allwinner/sun50i-a64-pinebook.dts
+++ b/arch/arm64/boot/dts/allwinner/sun50i-a64-pinebook.dts
@@ -202,9 +202,7 @@ 
 };
 
 &reg_aldo1 {
-	regulator-min-microvolt = <2800000>;
-	regulator-max-microvolt = <2800000>;
-	regulator-name = "vcc-csi";
+	regulator-name = "vcc-pe";
 };
 
 &reg_aldo2 {
@@ -267,12 +265,6 @@ 
 	regulator-name = "vcc-edp";
 };
 
-&reg_dldo3 {
-	regulator-min-microvolt = <3300000>;
-	regulator-max-microvolt = <3300000>;
-	regulator-name = "avdd-csi";
-};
-
 &reg_dldo4 {
 	regulator-min-microvolt = <3300000>;
 	regulator-max-microvolt = <3300000>;
@@ -286,12 +278,6 @@ 
 	regulator-name = "cpvdd";
 };
 
-&reg_eldo3 {
-	regulator-min-microvolt = <1800000>;
-	regulator-max-microvolt = <1800000>;
-	regulator-name = "vdd-1v8-csi";
-};
-
 &reg_fldo1 {
 	regulator-min-microvolt = <1200000>;
 	regulator-max-microvolt = <1200000>;