mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Stephen Warren <swarren@nvidia.com>
To: "Mark Brown (broonie@opensource.wolfsonmicro.com)" 
	<broonie@opensource.wolfsonmicro.com>,
	"Liam Girdwood (lrg@ti.com)" <lrg@ti.com>,
	Chris Ball <cjb@laptop.org>
Cc: Marek Szyprowski <m.szyprowski@samsung.com>,
	"linux-mmc@vger.kernel.org" <linux-mmc@vger.kernel.org>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>
Subject: sdmmc controllers without vmmc regulator
Date: Fri, 24 Feb 2012 13:35:08 -0800	[thread overview]
Message-ID: <74CDBE0F657A3D45AFBB94109FB122FF17BD8BCD8C@HQMAIL01.nvidia.com> (raw)

sdhci_add_host() calls regulator_get(..., "vmmc"), which under device-
tree calls of_get_regulator(), which contains:

	regnode = of_parse_phandle(dev->of_node, prop_name, 0);

	if (!regnode) {
		dev_warn(dev, "%s property in node %s references invalid phandle",
				prop_name, dev->of_node->full_name);
		return NULL;
	}

Thus if the vmmc-supply property is missing, because a board has no
regulator for a particular SD controller (power is always on), then
the warning is printed.

Can we eliminate this warning in of_get_regulator(), and let clients
Control whether they warn when a regulator isn't found, if they think
one is mandatory? I think I'd prefer this option; it's consistent with
the non-DT path in regulator_dev_lookup().

Or, should I set up dummy regulators in device tree to cover this case,
such that an SD controller's vmmc-supply always points at a valid phandle.
In which case, I'd have to add DT support to the dummy regulator.

Thanks.

-- 
nvpublic


             reply	other threads:[~2012-02-24 21:35 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-02-24 21:35 Stephen Warren [this message]
2012-02-25 11:57 ` Mark Brown

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=74CDBE0F657A3D45AFBB94109FB122FF17BD8BCD8C@HQMAIL01.nvidia.com \
    --to=swarren@nvidia.com \
    --cc=broonie@opensource.wolfsonmicro.com \
    --cc=cjb@laptop.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mmc@vger.kernel.org \
    --cc=lrg@ti.com \
    --cc=m.szyprowski@samsung.com \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®