linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Srinivas Kandagatla <srinivas.kandagatla@linaro.org>
To: bjorn.andersson@linaro.org, Mark Brown <broonie@kernel.org>
Cc: linux-kernel@vger.kernel.org, Liam Girdwood <lgirdwood@gmail.com>,
	linux-arm-msm@vger.kernel.org,
	Srinivas Kandagatla <srinivas.kandagatla@linaro.org>
Subject: [RFC PATCH v1 3/3] regulator: qcom_smd: add linear range to pm8941 lnldo
Date: Thu,  2 Jun 2016 11:23:16 +0100	[thread overview]
Message-ID: <1464862996-3147-4-git-send-email-srinivas.kandagatla@linaro.org> (raw)
In-Reply-To: <1464862996-3147-1-git-send-email-srinivas.kandagatla@linaro.org>

This patch converts a fixed voltage pm8941 lnldo to a single step
linear range regulator, so that we could use the same list_volatage
callback without BUG_ON from regulator core.

Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org>
---
 drivers/regulator/qcom_smd-regulator.c | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/drivers/regulator/qcom_smd-regulator.c b/drivers/regulator/qcom_smd-regulator.c
index b11b627..09c688d 100644
--- a/drivers/regulator/qcom_smd-regulator.c
+++ b/drivers/regulator/qcom_smd-regulator.c
@@ -246,7 +246,10 @@ static const struct regulator_desc pm8941_nldo = {
 };
 
 static const struct regulator_desc pm8941_lnldo = {
-	.fixed_uV = 1740000,
+	.linear_ranges = (struct regulator_linear_range[]) {
+		REGULATOR_LINEAR_RANGE(1740000, 0, 0, 1740000),
+	},
+	.n_linear_ranges = 1,
 	.n_voltages = 1,
 	.ops = &rpm_smps_ldo_ops,
 };
-- 
2.8.2

  parent reply	other threads:[~2016-06-02 10:23 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-06-02 10:23 [RFC PATCH v1 0/3] regulator: qcom_smd: add list_voltage callback support Srinivas Kandagatla
2016-06-02 10:23 ` [RFC PATCH v1 1/3] regulator: helpers: consider constriants in list_voltage_linear_range Srinivas Kandagatla
2016-06-02 11:05   ` Mark Brown
2016-06-02 11:53     ` Srinivas Kandagatla
2016-06-02 10:23 ` [RFC PATCH v1 2/3] regulator: qcom_smd: add list_voltage callback Srinivas Kandagatla
2016-06-03 10:40   ` Mark Brown
2016-06-03 11:24     ` Srinivas Kandagatla
2016-06-13 15:48   ` Applied "regulator: qcom_smd: add list_voltage callback" to the regulator tree Mark Brown
2016-06-02 10:23 ` Srinivas Kandagatla [this message]
2016-06-02 14:49   ` [RFC PATCH v1 3/3] regulator: qcom_smd: add linear range to pm8941 lnldo Mark Brown
2016-06-02 14:57     ` Srinivas Kandagatla
2016-06-02 15:50       ` Mark Brown
2016-06-02 16:04         ` Bjorn Andersson
2016-06-02 16:24           ` 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=1464862996-3147-4-git-send-email-srinivas.kandagatla@linaro.org \
    --to=srinivas.kandagatla@linaro.org \
    --cc=bjorn.andersson@linaro.org \
    --cc=broonie@kernel.org \
    --cc=lgirdwood@gmail.com \
    --cc=linux-arm-msm@vger.kernel.org \
    --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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).