From: Mark Brown <broonie@kernel.org>
To: Chanwoo Choi <cw00.choi@samsung.com>
Cc: lgirdwood@gmail.com, grant.likely@linaro.org, robh+dt@kernel.org,
kyungmin.park@samsung.com, k.kozlowski@samsung.com,
linux-kernel@vger.kernel.org, devicetree@vger.kernel.org
Subject: Re: [PATCHv4 1/2] regulator: of: Add support for parsing regulator_state for suspend state
Date: Thu, 4 Sep 2014 23:49:48 +0100 [thread overview]
Message-ID: <20140904224948.GX29327@sirena.org.uk> (raw)
In-Reply-To: <1408343223-4043-2-git-send-email-cw00.choi@samsung.com>
[-- Attachment #1: Type: text/plain, Size: 1179 bytes --]
On Mon, Aug 18, 2014 at 03:27:02PM +0900, Chanwoo Choi wrote:
> + suspend_uV = of_get_property(suspend_np, "regulator-volt",
> + NULL);
> + if (suspend_uV) {
> + suspend_state->uV = be32_to_cpu(*suspend_uV);
> +
> + if (suspend_state->uV < constraints->min_uV)
> + suspend_state->uV = constraints->min_uV;
> + if (suspend_state->uV > constraints->max_uV)
> + suspend_state->uV = constraints->max_uV;
> + }
A few things here. One is that this will fail if we don't have a
voltage range specified at runtime. It is possible that the user needs
to override the voltage in suspend mode but not at runtime. Perhaps we
want to make them specify the runtime voltage anyway but if we do then
the binding needs to say that this is mandatory even if it's just
restating the hardware default.
It's also not clear to me that the suspend voltage needs to be in the
range that we can vary at runtime, especially if we're not giving
permission for runtime variation. From that point of view we should
probably just not check, but if we are going to check we should print a
warning that we're doing it so people know that what they set in the DT
isn't being followed.
[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 819 bytes --]
next prev parent reply other threads:[~2014-09-04 22:50 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-08-18 6:27 [PATCHv4 0/2] regulator: of: Add support for pasing regulator " Chanwoo Choi
2014-08-18 6:27 ` [PATCHv4 1/2] regulator: of: Add support for parsing regulator_state for " Chanwoo Choi
2014-09-04 22:49 ` Mark Brown [this message]
2014-09-29 0:40 ` Chanwoo Choi
2014-08-18 6:27 ` [PATCHv4 2/2] dt-bindings: regulator: Add regulator suspend state for PM state Chanwoo Choi
2014-09-04 22:53 ` 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=20140904224948.GX29327@sirena.org.uk \
--to=broonie@kernel.org \
--cc=cw00.choi@samsung.com \
--cc=devicetree@vger.kernel.org \
--cc=grant.likely@linaro.org \
--cc=k.kozlowski@samsung.com \
--cc=kyungmin.park@samsung.com \
--cc=lgirdwood@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=robh+dt@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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
Powered by JetHome