linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Claudiu Beznea <claudiu.beznea@microchip.com>
To: <lgirdwood@gmail.com>, <broonie@kernel.org>
Cc: <s.hauer@pengutronix.de>, <ttynkkynen@nvidia.com>,
	<linus.walleij@linaro.org>, <axel.lin@ingics.com>,
	<linux-kernel@vger.kernel.org>,
	<linux-arm-kernel@lists.infradead.org>,
	Claudiu Beznea <claudiu.beznea@microchip.com>
Subject: [PATCH v3 3/6] regulator: mcp16502: add linear_min_sel
Date: Fri, 13 Nov 2020 17:21:07 +0200	[thread overview]
Message-ID: <1605280870-32432-4-git-send-email-claudiu.beznea@microchip.com> (raw)
In-Reply-To: <1605280870-32432-1-git-send-email-claudiu.beznea@microchip.com>

Selectors b/w zero and VDD_LOW_SEL are not valid. Use linear_min_sel.

Fixes: 919261c03e7ca ("regulator: mcp16502: add regulator driver for MCP16502")
Signed-off-by: Claudiu Beznea <claudiu.beznea@microchip.com>
---
 drivers/regulator/mcp16502.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/regulator/mcp16502.c b/drivers/regulator/mcp16502.c
index 6d0ad74935b3..ab78f831f5bf 100644
--- a/drivers/regulator/mcp16502.c
+++ b/drivers/regulator/mcp16502.c
@@ -93,6 +93,7 @@ static unsigned int mcp16502_of_map_mode(unsigned int mode)
 		.owner			= THIS_MODULE,			\
 		.n_voltages		= MCP16502_VSEL + 1,		\
 		.linear_ranges		= _ranges,			\
+		.linear_min_sel		= VDD_LOW_SEL,			\
 		.n_linear_ranges	= ARRAY_SIZE(_ranges),		\
 		.of_match		= of_match_ptr(_name),		\
 		.of_map_mode		= mcp16502_of_map_mode,		\
-- 
2.7.4


  parent reply	other threads:[~2020-11-13 15:21 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-11-13 15:21 [PATCH v3 0/6] regulator: mcp16502: add support for ramp delay Claudiu Beznea
2020-11-13 15:21 ` [PATCH v3 1/6] regulator: core: validate selector against linear_min_sel Claudiu Beznea
2020-11-24  9:36   ` Jon Hunter
2020-11-24 11:14     ` Claudiu.Beznea
2020-11-24 13:41       ` Jon Hunter
2020-11-25 10:46         ` Claudiu.Beznea
2020-11-24 14:11       ` Mark Brown
2020-11-25 11:34         ` [PATCH] regulator: core: return zero for selectors lower than linear_min_sel Claudiu Beznea
2020-11-25 17:03           ` Mark Brown
2020-11-13 15:21 ` [PATCH v3 2/6] regulator: core: do not continue if selector match Claudiu Beznea
2020-11-13 16:11   ` Mark Brown
2020-11-13 15:21 ` Claudiu Beznea [this message]
2020-11-13 15:21 ` [PATCH v3 4/6] regulator: mcp16502: adapt for get/set on other registers Claudiu Beznea
2020-11-13 15:21 ` [PATCH v3 5/6] regulator: mcp16502: add support for ramp delay Claudiu Beznea
2020-11-13 15:21 ` [PATCH v3 6/6] regulator: mcp16502: remove void documentation of struct mcp16502 Claudiu Beznea
2020-11-13 17:14 ` [PATCH v3 0/6] regulator: mcp16502: add support for ramp delay Mark Brown
2020-12-01 13: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=1605280870-32432-4-git-send-email-claudiu.beznea@microchip.com \
    --to=claudiu.beznea@microchip.com \
    --cc=axel.lin@ingics.com \
    --cc=broonie@kernel.org \
    --cc=lgirdwood@gmail.com \
    --cc=linus.walleij@linaro.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=s.hauer@pengutronix.de \
    --cc=ttynkkynen@nvidia.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;
as well as URLs for NNTP newsgroup(s).