All of lore.kernel.org
 help / color / mirror / Atom feed
From: Mark Brown <broonie@kernel.org>
To: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Cc: "linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	"Hunter, Adrian" <adrian.hunter@intel.com>
Subject: Re: Regulator probe
Date: Tue, 6 Sep 2016 11:24:07 +0100	[thread overview]
Message-ID: <20160906102407.GF3950@sirena.org.uk> (raw)
In-Reply-To: <1473091312.11323.20.camel@linux.intel.com>

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

On Mon, Sep 05, 2016 at 07:01:52PM +0300, Andy Shevchenko wrote:
> On Thu, 2016-09-01 at 18:02 +0100, Mark Brown wrote:

> > Anyway if that's the case then it should all be working already then
> > unless SFI goes down the ACPI code paths or someone changed SFI since
> > SFI won't flag as having full costraints and therefore any missing
> > regulator will report as deferring.

> But it's a real burden to describe in platform code _every_ regulators
> that device driver may need (for example, "vqmmc" is optional and even
> "vmmc" is optional for 2 out of 3 SDHCI host controllers!).

Nothing says you have to describe all regulators, you just need to tell
the core you have told it about everything you're going to tell it
about.  Until you do that the core has to assume that something may come
along later and describe that supply.

> >   If that is indeed the case you've
> > probably got a broken consumer driver that's not handing probe
> > deferrals.

> It has, but see above, for 3 SDHCI controllers I have to provide 5 dummy
> regulators and 1 real vs. just 1 real.

The core will substitute in the dummies once it knows that everything is
described, you don't need to do it manually unless you have to provide
information like voltages.

> > > Basically you mean we have not call
> > > regulator_has_full_constraints()?
> > > In that case we have to provide stubs for all expected regulators,
> > > in
> > > case of SDHCI one real and one dummy, who knows how many them in the
> > > drivers, but for each we have to provide that. Am I right? 

> > You have to either not call regulator_has_full_constraints() or supply
> > all the mappings for device supplies before you register a device.  If
> > you don't call regulator_has_full_constraints() missing regulators
> > will
> > always defer so you would need to provide a fixed voltage regulator
> > for
> > it.

> It would be plenty of dummy regulators.

If and only if you don't provide the mappings.

> > It would be a lot more sensible than SFI, it's so limited you're
> > basically just using board files but with the limitations of having to
> > do bits of it through firmware and then join the two up which seems
> > like
> > the worst of both worlds.

> I dunno if DT has any means of coexistence with e820 BIOS where PCI
> devices are enumerated natively.

Of course it does, DT based systems support enumerable buses like USB
and PCI.  Enumerating via BIOS is no different really.

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

  reply	other threads:[~2016-09-06 10:32 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-09-01 14:53 Regulator probe Andy Shevchenko
2016-09-01 15:38 ` Mark Brown
2016-09-01 16:15   ` Andy Shevchenko
2016-09-01 17:02     ` Mark Brown
2016-09-05 16:01       ` Andy Shevchenko
2016-09-06 10:24         ` Mark Brown [this message]
2016-09-07 14:24           ` Andy Shevchenko
2016-09-09 12:17             ` Mark Brown
2016-09-09 12:55               ` Andy Shevchenko
2016-09-09 15:29                 ` Mark Brown
2016-09-09 16:10                   ` Andy Shevchenko
2016-09-09 16:38                     ` Mark Brown
2016-09-09 17:04                       ` Andy Shevchenko
2016-09-09 17:18                         ` Mark Brown
2016-09-10 11:03                       ` Andy Shevchenko
2016-09-12 15:27                         ` Mark Brown
2016-09-12 16:01                           ` Andy Shevchenko

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=20160906102407.GF3950@sirena.org.uk \
    --to=broonie@kernel.org \
    --cc=adrian.hunter@intel.com \
    --cc=andriy.shevchenko@linux.intel.com \
    --cc=linux-kernel@vger.kernel.org \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.