Re: [PATCH v7] regulator: fixed: Convert to use GPIO descriptor only
From: Mark Brown
Date: Fri Oct 12 2018 - 12:17:26 EST
On Fri, Oct 12, 2018 at 04:58:38PM +0300, Andy Shevchenko wrote:
> On Fri, Oct 12, 2018 at 1:45 PM Russell King - ARM Linux
> > Given that DT describes the hardware, not the software implementation,
> > it must not change just because we move from GPIO numbers to GPIO
> > descriptors.
> > The existing DT description is reasonable, and introducing ficticious
> > regulators in DT to work around the implementation is not reasonable.
> If there is no way to detect shared use of GPIO line for regulators
> (*) from current DT description, DT description should be updated to
> reflect, yes, hardware.
> (*) Not familiar with the guts of DT descriptive language, don't know
> if there are some ways to do a such without additional flags or so.
You can detect this via resolving the GPIOs and seeing if it points back
to something that's already in use for an enable. This isn't ideal
especially if you want to do it up front but it is doable. You could
also just assume anything might end up being shared and rather than
doing it up front which is easier and probably about as good.
Attachment:
signature.asc
Description: PGP signature