All of lore.kernel.org
 help / color / mirror / Atom feed
From: Mark Brown <broonie@kernel.org>
To: Maxime Ripard <maxime.ripard@free-electrons.com>
Cc: Mathieu Poirier <mathieu.poirier@linaro.org>,
	Chen-Yu Tsai <wens@csie.org>, Liam Girdwood <lgirdwood@gmail.com>,
	"devicetree@vger.kernel.org" <devicetree@vger.kernel.org>,
	"linux-arm-kernel@lists.infradead.org" 
	<linux-arm-kernel@lists.infradead.org>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH 1/2] regulator: Add coupled regulator
Date: Tue, 1 Dec 2015 18:58:52 +0000	[thread overview]
Message-ID: <20151201185852.GO1929@sirena.org.uk> (raw)
In-Reply-To: <20151201140436.GQ29263@lukather>

[-- Attachment #1: Type: text/plain, Size: 1143 bytes --]

On Tue, Dec 01, 2015 at 03:04:36PM +0100, Maxime Ripard wrote:
> On Mon, Nov 30, 2015 at 10:17:45AM -0700, Mathieu Poirier wrote:
> > On 30 November 2015 at 08:29, Maxime Ripard

> > > +       for (i = 0; i < creg->n_regulators; i++) {
> > > +               ret = regulator_disable(creg->regulators[i]);
> > > +               if (ret)
> > > +                       break;
> > > +       }

> > What happens to the other regulators when an element of the chain
> > fails to disable?  Should they be powered on again?

> That's actually a very good question, and I don't have a good answer
> to it. I guess the safest approach would be to roll back and do the
> opposite operation on the one we previously enabled / disabled.

> I wonder whether it might damage the hardware or not though.

> Mark?

Yeah, I'd expect us to try to unwind everything - presumably if the
supplies are partially enabled we'll not be able to satisfy the power
demands of whatever is connected (otherwise why would you create such an
innovative hardware design?) and it'll also mean that the refcounting
will be off if we ever try to do anything with the supply again.

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 473 bytes --]

WARNING: multiple messages have this Message-ID (diff)
From: Mark Brown <broonie-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>
To: Maxime Ripard
	<maxime.ripard-wi1+55ScJUtKEb57/3fJTNBPR1lH4CV8@public.gmane.org>
Cc: Mathieu Poirier
	<mathieu.poirier-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org>,
	Chen-Yu Tsai <wens-jdAy2FN1RRM@public.gmane.org>,
	Liam Girdwood <lgirdwood-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>,
	"devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org"
	<devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org>,
	"linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org"
	<linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org>,
	"linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org"
	<linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org>
Subject: Re: [PATCH 1/2] regulator: Add coupled regulator
Date: Tue, 1 Dec 2015 18:58:52 +0000	[thread overview]
Message-ID: <20151201185852.GO1929@sirena.org.uk> (raw)
In-Reply-To: <20151201140436.GQ29263@lukather>

[-- Attachment #1: Type: text/plain, Size: 1143 bytes --]

On Tue, Dec 01, 2015 at 03:04:36PM +0100, Maxime Ripard wrote:
> On Mon, Nov 30, 2015 at 10:17:45AM -0700, Mathieu Poirier wrote:
> > On 30 November 2015 at 08:29, Maxime Ripard

> > > +       for (i = 0; i < creg->n_regulators; i++) {
> > > +               ret = regulator_disable(creg->regulators[i]);
> > > +               if (ret)
> > > +                       break;
> > > +       }

> > What happens to the other regulators when an element of the chain
> > fails to disable?  Should they be powered on again?

> That's actually a very good question, and I don't have a good answer
> to it. I guess the safest approach would be to roll back and do the
> opposite operation on the one we previously enabled / disabled.

> I wonder whether it might damage the hardware or not though.

> Mark?

Yeah, I'd expect us to try to unwind everything - presumably if the
supplies are partially enabled we'll not be able to satisfy the power
demands of whatever is connected (otherwise why would you create such an
innovative hardware design?) and it'll also mean that the refcounting
will be off if we ever try to do anything with the supply again.

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 473 bytes --]

WARNING: multiple messages have this Message-ID (diff)
From: broonie@kernel.org (Mark Brown)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH 1/2] regulator: Add coupled regulator
Date: Tue, 1 Dec 2015 18:58:52 +0000	[thread overview]
Message-ID: <20151201185852.GO1929@sirena.org.uk> (raw)
In-Reply-To: <20151201140436.GQ29263@lukather>

On Tue, Dec 01, 2015 at 03:04:36PM +0100, Maxime Ripard wrote:
> On Mon, Nov 30, 2015 at 10:17:45AM -0700, Mathieu Poirier wrote:
> > On 30 November 2015 at 08:29, Maxime Ripard

> > > +       for (i = 0; i < creg->n_regulators; i++) {
> > > +               ret = regulator_disable(creg->regulators[i]);
> > > +               if (ret)
> > > +                       break;
> > > +       }

> > What happens to the other regulators when an element of the chain
> > fails to disable?  Should they be powered on again?

> That's actually a very good question, and I don't have a good answer
> to it. I guess the safest approach would be to roll back and do the
> opposite operation on the one we previously enabled / disabled.

> I wonder whether it might damage the hardware or not though.

> Mark?

Yeah, I'd expect us to try to unwind everything - presumably if the
supplies are partially enabled we'll not be able to satisfy the power
demands of whatever is connected (otherwise why would you create such an
innovative hardware design?) and it'll also mean that the refcounting
will be off if we ever try to do anything with the supply again.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 473 bytes
Desc: not available
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20151201/ae881dca/attachment-0001.sig>

  reply	other threads:[~2015-12-01 18:59 UTC|newest]

Thread overview: 24+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-11-30 15:29 [PATCH 0/2] regulator: Add support for parallel regulators Maxime Ripard
2015-11-30 15:29 ` Maxime Ripard
2015-11-30 15:29 ` Maxime Ripard
2015-11-30 15:29 ` [PATCH 1/2] regulator: Add coupled regulator Maxime Ripard
2015-11-30 15:29   ` Maxime Ripard
2015-11-30 16:41   ` Mark Brown
2015-11-30 16:41     ` Mark Brown
2015-11-30 17:17   ` Mathieu Poirier
2015-11-30 17:17     ` Mathieu Poirier
2015-11-30 17:17     ` Mathieu Poirier
2015-12-01 14:04     ` Maxime Ripard
2015-12-01 14:04       ` Maxime Ripard
2015-12-01 14:04       ` Maxime Ripard
2015-12-01 18:58       ` Mark Brown [this message]
2015-12-01 18:58         ` Mark Brown
2015-12-01 18:58         ` Mark Brown
2015-11-30 19:06   ` Javier Martinez Canillas
2015-11-30 19:06     ` Javier Martinez Canillas
2015-11-30 19:06     ` Javier Martinez Canillas
2015-12-01 21:30     ` Maxime Ripard
2015-12-01 21:30       ` Maxime Ripard
2015-12-01 21:30       ` Maxime Ripard
2015-11-30 15:29 ` [PATCH 2/2] ARM: sunxi: chip: Add Wifi chip Maxime Ripard
2015-11-30 15:29   ` Maxime Ripard

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=20151201185852.GO1929@sirena.org.uk \
    --to=broonie@kernel.org \
    --cc=devicetree@vger.kernel.org \
    --cc=lgirdwood@gmail.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mathieu.poirier@linaro.org \
    --cc=maxime.ripard@free-electrons.com \
    --cc=wens@csie.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.