Re: [PATCH v3 4/4] regulator: core: Add voltage support for sync_state() callbacks

2020-07-21 Thread Mark Brown
On Mon, Jul 20, 2020 at 08:24:59PM -0700, Saravana Kannan wrote: > Btw, going a tangent, why is regulator_set_voltage() not dependent on > a consumer's regulator enable request? If they don't care if the > regulator goes off, do they really care if the voltage goes lower? > What's the reason

Re: [PATCH v3 4/4] regulator: core: Add voltage support for sync_state() callbacks

2020-07-20 Thread Saravana Kannan
On Mon, Jul 20, 2020 at 7:35 AM Mark Brown wrote: > > On Wed, Jul 15, 2020 at 09:20:53PM -0700, Saravana Kannan wrote: > > > - if (!handoff) > > + if (!handoff) { > > regulator_disable(rdev->boot_limits); > > - else > > +

Re: [PATCH v3 4/4] regulator: core: Add voltage support for sync_state() callbacks

2020-07-20 Thread Mark Brown
On Wed, Jul 15, 2020 at 09:20:53PM -0700, Saravana Kannan wrote: > - if (!handoff) > + if (!handoff) { > regulator_disable(rdev->boot_limits); > - else > + regulator_set_voltage(rdev->boot_limits, 0, INT_MAX); > + } else { >

[PATCH v3 4/4] regulator: core: Add voltage support for sync_state() callbacks

2020-07-15 Thread Saravana Kannan
Consider the following example: - regulator-X is provided by device-X. - regulator-X is a supplier to device-A, device-B and device-C. - device-A is off/inactive from boot. - device-B and device-C are left on/active by the bootloader - regulator-X is left on boot by the bootloader at 2000 mV to