public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Matthias Kaehlcke <mka@chromium.org>
To: Doug Anderson <dianders@chromium.org>
Cc: Andy Gross <agross@kernel.org>,
	Bjorn Andersson <bjorn.andersson@linaro.org>,
	Rob Herring <robh+dt@kernel.org>,
	linux-arm-msm <linux-arm-msm@vger.kernel.org>,
	"open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS" 
	<devicetree@vger.kernel.org>, LKML <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH] arm64: dts: qcom: sc7180-trogdor: Make pp3300_a the default supply for pp3300_hub
Date: Thu, 5 Nov 2020 10:28:35 -0800	[thread overview]
Message-ID: <20201105182835.GB3079843@google.com> (raw)
In-Reply-To: <CAD=FV=W=L=gjue69UCnC-xbkQYwMaqCUoaGGJsarLxxjagZPpA@mail.gmail.com>

On Thu, Nov 05, 2020 at 07:57:42AM -0800, Doug Anderson wrote:
> Hi,
> 
> On Wed, Nov 4, 2020 at 5:55 PM Matthias Kaehlcke <mka@chromium.org> wrote:
> >
> > > > diff --git a/arch/arm64/boot/dts/qcom/sc7180-trogdor.dtsi b/arch/arm64/boot/dts/qcom/sc7180-trogdor.dtsi
> > > > index bf875589d364..2d64e75a2d6d 100644
> > > > --- a/arch/arm64/boot/dts/qcom/sc7180-trogdor.dtsi
> > > > +++ b/arch/arm64/boot/dts/qcom/sc7180-trogdor.dtsi
> > > > @@ -174,6 +174,21 @@ pp3300_fp_tp: pp3300-fp-tp-regulator {
> > > >                 vin-supply = <&pp3300_a>;
> > > >         };
> > > >
> > > > +       pp3300_hub: pp3300-hub {
> > > > +               compatible = "regulator-fixed";
> > > > +               regulator-name = "pp3300_hub";
> > > > +
> > > > +               regulator-min-microvolt = <3300000>;
> > > > +               regulator-max-microvolt = <3300000>;
> > > > +
> > > > +               gpio = <&tlmm 84 GPIO_ACTIVE_HIGH>;
> > > > +               enable-active-high;
> > > > +               pinctrl-names = "default";
> > > > +               pinctrl-0 = <&en_pp3300_hub>;
> > > > +
> > > > +               vin-supply = <&pp3300_a>;
> > >
> > > You're leaving things in a bit of an inconsistent state here.  The
> > > "pp3300_hub_7c" is always_on / boot_on.  This new one isn't.
> >
> > Actually the new "pp3300_hub" it is also on at boot, the Chrome OS bootloader
> > asserts the GPIO.
> >
> > > I know this is slightly more complicated due to the fact that downstream we
> > > have a way to control the hub power but didn't quite get that resolved
> > > upstream, but the way you have it now, on new hardware upstream will
> > > power off the hub but also keep "pp3300_hub_7c" powered on for no
> > > reason.  Seems like that should be fixed?
> >
> > Our EEs told me that it would be ok in terms of power to keep "pp3300_hub_7c"
> > powered, since there would be no significant power consumption without load.
> >
> > In any case unused RPMH regulators are switched off by the kernel ~30s after
> > boot, so I think we are ok:
> >
> > [   31.202219] ldo7: disabling
> >
> > The above is from the l7c regulator on a Lazor rev2.
> 
> I assume this is with the downstream codebase, though?  With what you
> have posted upstream I don't think ldo7 will ever get disabled because
> it's marked "always-on"?
>
> Similarly, with what you've posted upstream I think your new
> "pp3300_hub" _will_ get disabled ~30 seconds after boot because it's
> not marked "always-on" and it has no clients.

Ah, now I see what you mean, thanks for the clarification. I associated
the ~30 seconds disabling with the RPMH regulators, but you're right, it's
generic regulator behavior (regulator_late_cleanup()).

So yeah, it seems some reshuffling of "always-on" and "boot-on" properties
is needed.

      reply	other threads:[~2020-11-05 18:28 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-11-03 18:38 [PATCH] arm64: dts: qcom: sc7180-trogdor: Make pp3300_a the default supply for pp3300_hub Matthias Kaehlcke
2020-11-05  0:29 ` Doug Anderson
2020-11-05  1:55   ` Matthias Kaehlcke
2020-11-05 15:57     ` Doug Anderson
2020-11-05 18:28       ` Matthias Kaehlcke [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20201105182835.GB3079843@google.com \
    --to=mka@chromium.org \
    --cc=agross@kernel.org \
    --cc=bjorn.andersson@linaro.org \
    --cc=devicetree@vger.kernel.org \
    --cc=dianders@chromium.org \
    --cc=linux-arm-msm@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=robh+dt@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox