linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* Re: [patch] regulator: core: don't disable regulator on init if boot_on set
       [not found] <CAFY_6qpOCiuDbRWYChvkJ5V13vUap9+x+N2HHjrCy4emghwXwQ@mail.gmail.com>
@ 2016-10-08 11:23 ` Mark Brown
  0 siblings, 0 replies; only message in thread
From: Mark Brown @ 2016-10-08 11:23 UTC (permalink / raw)
  To: Samuel Morris; +Cc: lgirdwood, linux-kernel

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

On Fri, Oct 07, 2016 at 11:28:13AM -0400, Samuel Morris wrote:

> Even though the core has been told the hardware is on with the boot_on
> constraint, it turns it off anyway during regulator_late_cleanup(). This

All that constraint does is tell the framework what the initial setting
is, nothing more - it's there for regulators where we don't have the
ability to read back the initial state due to hardware limitations.

> potentially causes problems for devices not tracked by the regulator
> framework

If the system needs the regulator to be always on you should flag it as
such, you shouldn't rely on some other consumer coming along that
happens to need the regulator enabling - there's no guarantee the user
will enable that consumer or that the consumer power management won't be
improved in the future causing it to not keep the regulator enabled
constantly.

> that rely on that device being powered at boot. Resources are also

If you have consumers that aren't integrated into the regulator
framework you need to use always on.

> needlessly wasted disabling and later reenabling the device when the first
> consumer of the regulator calls regulator_enable().

This is expected, we have no way of telling if a driver for the device
will ever load so at some point we have to power idle regulators off if
we don't want to waste power on them (it is common for systems to have
idle regulators due to inflexibility in PMIC configuration).  The extra
overhead of reenabling is generally trivial.

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

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2016-10-08 11:23 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <CAFY_6qpOCiuDbRWYChvkJ5V13vUap9+x+N2HHjrCy4emghwXwQ@mail.gmail.com>
2016-10-08 11:23 ` [patch] regulator: core: don't disable regulator on init if boot_on set Mark Brown

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).