public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Ivaylo Dimitrov <ivo.g.dimitrov.75@gmail.com>
To: Mark Brown <broonie@kernel.org>
Cc: Sebastian Reichel <sre@kernel.org>,
	tony@atomide.com, lgirdwood@gmail.com,
	linux-omap@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] regulator: twl: Enable regulators over the powerbus as well
Date: Fri, 25 Mar 2016 18:50:18 +0200	[thread overview]
Message-ID: <56F56C4A.7070502@gmail.com> (raw)
In-Reply-To: <20160325161954.GA5028@sirena.org.uk>



On 25.03.2016 18:19, Mark Brown wrote:
> On Fri, Mar 25, 2016 at 06:09:27PM +0200, Ivaylo Dimitrov wrote:
>
>> Ok, so you say that regulator framework should call twl4030reg_set_mode(),
>> but it doesn't. If that is the case, then the bug is in the regulator
>> framework, a similar one to what you've fixed in "regulator: core: Always
>> flag voltage constraints as appliable".
>
> What makes you claim that this is a bug in the framework?  Does anything
> in the machine configuration say that changing the modes is allowed?
>

My understanding is that regulator core have to make sure an enabled 
regulator to be in REGULATOR_STATUS_NORMAL. Now it enables the 
regulator, but does not make it in REGULATOR_STATUS_NORMAL. There are 3 
places set_mode() is called in regulator/core.c - in drms_uA_update(), 
in regulator_set_mode() and in set_machine_constraints(). 
set_machine_constraints() calls set_mode() only if there is initial mode 
for that regulator. I can't find a call to regulator_set_mode() anywhere 
in the tree.

 From the documentation:

"regulator-initial-mode: initial operating mode...."

Does the above imply that every regulator present in the system must 
have "initial-mode" defined even if it is "always-on" regulator?

Also, who puts a regulator out of REGULATOR_STATUS_NORMAL if there are 
no more consumers?

It might be that I am not getting the logic behind.

Ivo

  reply	other threads:[~2016-03-25 16:51 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-03-23 19:22 [PATCH] regulator: twl: Enable regulators over the powerbus as well Ivaylo Dimitrov
2016-03-25 11:17 ` Mark Brown
2016-03-25 15:02   ` Sebastian Reichel
2016-03-25 15:54     ` Mark Brown
2016-03-25 16:09       ` Ivaylo Dimitrov
2016-03-25 16:19         ` Mark Brown
2016-03-25 16:50           ` Ivaylo Dimitrov [this message]
2016-03-25 17:05             ` Mark Brown
2016-03-25 17:22               ` Ivaylo Dimitrov
2016-03-25 18:20                 ` Mark Brown
2016-03-25 20:19                   ` Sebastian Reichel
2016-03-25 22:28                     ` Mark Brown
2016-03-26  6:18                       ` Ivaylo Dimitrov
2016-03-25 16:47       ` Sebastian Reichel
2016-03-25 17:23         ` Mark Brown

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=56F56C4A.7070502@gmail.com \
    --to=ivo.g.dimitrov.75@gmail.com \
    --cc=broonie@kernel.org \
    --cc=lgirdwood@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-omap@vger.kernel.org \
    --cc=sre@kernel.org \
    --cc=tony@atomide.com \
    /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