Messages in this thread | | | Date | Thu, 16 Apr 2020 15:04:34 +0100 | From | Mark Brown <> | Subject | Re: Multiple regulators for one device [was drm/panfrost: add devfreq regulator support] |
| |
On Thu, Apr 16, 2020 at 02:42:13PM +0100, Steven Price wrote: > On 14/04/2020 20:16, Clément Péron wrote:
> > That's can be reworked and Panfrost can only probe regulator if there > > is no opp-table.
> This is what I was thinking about looking at. But it may make sense instead > to extend the regulator API to allow multiple regualtor_get() calls for a > single device. I haven't had time to dig into how difficult this would be.
To repeat what I said before we don't actively stop this, it's just not something that seems particularly tasteful and the warning does find actual errors. I definitely don't think it's a good idea to extend the API for this.
> Ideally calling regulator_get a second time for the same device would simply > return the same struct regulator object (with a reference count increment).
One of the goals with the distinct struct regulator is to make sure that we track all the user's activity together - if we mix multiple users in there it becomes harder to tell if something is going wrong. [unhandled content-type:application/pgp-signature] | |