linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 0/2] regulator: da9121: bug fixes
@ 2020-12-07 17:15 Adam Ward
  2020-12-07 17:15 ` [PATCH 1/2] regulator: da9121: Remove uninitialised string variable Adam Ward
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Adam Ward @ 2020-12-07 17:15 UTC (permalink / raw)
  To: Mark Brown
  Cc: Liam Girdwood, Vincent Whitchurch, linux-kernel, Support Opensource

This patch fixes a couple of bugs in the DA9121 driver.
One in an uninialised string I forgot to remove when changing to of_parse_cb()
The other is an index for an optional DT property which overflows


Adam Ward (2):
  regulator: da9121: Remove uninitialised string variable
  regulator: da9121: Fix index used for DT property

 drivers/regulator/da9121-regulator.c | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

-- 
1.9.1


^ permalink raw reply	[flat|nested] 4+ messages in thread

* [PATCH 1/2] regulator: da9121: Remove uninitialised string variable
  2020-12-07 17:15 [PATCH 0/2] regulator: da9121: bug fixes Adam Ward
@ 2020-12-07 17:15 ` Adam Ward
  2020-12-07 17:15 ` [PATCH 2/2] regulator: da9121: Fix index used for DT property Adam Ward
  2020-12-08 17:10 ` [PATCH 0/2] regulator: da9121: bug fixes Mark Brown
  2 siblings, 0 replies; 4+ messages in thread
From: Adam Ward @ 2020-12-07 17:15 UTC (permalink / raw)
  To: Mark Brown
  Cc: Liam Girdwood, Vincent Whitchurch, linux-kernel, Support Opensource

Erroneously left in when switched to using of_parse_cb()

Signed-off-by: Adam Ward <Adam.Ward.opensource@diasemi.com>
---
 drivers/regulator/da9121-regulator.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/drivers/regulator/da9121-regulator.c b/drivers/regulator/da9121-regulator.c
index db1c2cc..ed68259 100644
--- a/drivers/regulator/da9121-regulator.c
+++ b/drivers/regulator/da9121-regulator.c
@@ -816,7 +816,6 @@ static int da9121_check_device_type(struct i2c_client *i2c, struct da9121 *chip)
 	u32 variant_id;
 	u8 variant_mrc, variant_vrc;
 	char *type;
-	const char *name;
 	bool config_match = false;
 	int ret = 0;
 
@@ -867,7 +866,7 @@ static int da9121_check_device_type(struct i2c_client *i2c, struct da9121 *chip)
 		 device_id, variant_id, type);
 
 	if (!config_match) {
-		dev_err(chip->dev, "Device tree configuration '%s' does not match detected device.\n", name);
+		dev_err(chip->dev, "Device tree configuration does not match detected device.\n");
 		ret = -EINVAL;
 		goto error;
 	}
-- 
1.9.1


^ permalink raw reply related	[flat|nested] 4+ messages in thread

* [PATCH 2/2] regulator: da9121: Fix index used for DT property
  2020-12-07 17:15 [PATCH 0/2] regulator: da9121: bug fixes Adam Ward
  2020-12-07 17:15 ` [PATCH 1/2] regulator: da9121: Remove uninitialised string variable Adam Ward
@ 2020-12-07 17:15 ` Adam Ward
  2020-12-08 17:10 ` [PATCH 0/2] regulator: da9121: bug fixes Mark Brown
  2 siblings, 0 replies; 4+ messages in thread
From: Adam Ward @ 2020-12-07 17:15 UTC (permalink / raw)
  To: Mark Brown
  Cc: Liam Girdwood, Vincent Whitchurch, linux-kernel, Support Opensource

Signed-off-by: Adam Ward <Adam.Ward.opensource@diasemi.com>
---
 drivers/regulator/da9121-regulator.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/regulator/da9121-regulator.c b/drivers/regulator/da9121-regulator.c
index ed68259..9d5b02f 100644
--- a/drivers/regulator/da9121-regulator.c
+++ b/drivers/regulator/da9121-regulator.c
@@ -381,7 +381,7 @@ static int da9121_of_parse_cb(struct device_node *np,
 		uint32_t ripple_reg;
 		int ret;
 
-		if (of_property_read_u32(da9121_matches[pdata->num_buck].of_node,
+		if (of_property_read_u32(da9121_matches[pdata->num_buck-1].of_node,
 				"dlg,ripple-cancel", &ripple_cancel)) {
 			if (pdata->num_buck > 1)
 				ripple_reg = DA9xxx_REG_BUCK_BUCK2_7;
-- 
1.9.1


^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [PATCH 0/2] regulator: da9121: bug fixes
  2020-12-07 17:15 [PATCH 0/2] regulator: da9121: bug fixes Adam Ward
  2020-12-07 17:15 ` [PATCH 1/2] regulator: da9121: Remove uninitialised string variable Adam Ward
  2020-12-07 17:15 ` [PATCH 2/2] regulator: da9121: Fix index used for DT property Adam Ward
@ 2020-12-08 17:10 ` Mark Brown
  2 siblings, 0 replies; 4+ messages in thread
From: Mark Brown @ 2020-12-08 17:10 UTC (permalink / raw)
  To: Adam Ward
  Cc: Liam Girdwood, linux-kernel, Support Opensource, Vincent Whitchurch

On Mon, 7 Dec 2020 17:15:14 +0000, Adam Ward wrote:
> This patch fixes a couple of bugs in the DA9121 driver.
> One in an uninialised string I forgot to remove when changing to of_parse_cb()
> The other is an index for an optional DT property which overflows
> 
> 
> Adam Ward (2):
>   regulator: da9121: Remove uninitialised string variable
>   regulator: da9121: Fix index used for DT property
> 
> [...]

Applied to

   https://git.kernel.org/pub/scm/linux/kernel/git/broonie/regulator.git for-next

Thanks!

[1/2] regulator: da9121: Remove uninitialised string variable
      commit: 416c29e9ce1347ba9a4ef7aeb4f30c8d9a3ada49
[2/2] regulator: da9121: Fix index used for DT property
      commit: 9536ce63705952be5214544e3b048c78f932e794

All being well this means that it will be integrated into the linux-next
tree (usually sometime in the next 24 hours) and sent to Linus during
the next merge window (or sooner if it is a bug fix), however if
problems are discovered then the patch may be dropped or reverted.

You may get further e-mails resulting from automated or manual testing
and review of the tree, please engage with people reporting problems and
send followup patches addressing any issues that are reported if needed.

If any updates are required or you are submitting further changes they
should be sent as incremental updates against current git, existing
patches will not be replaced.

Please add any relevant lists and maintainers to the CCs when replying
to this mail.

Thanks,
Mark

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2020-12-08 17:12 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-12-07 17:15 [PATCH 0/2] regulator: da9121: bug fixes Adam Ward
2020-12-07 17:15 ` [PATCH 1/2] regulator: da9121: Remove uninitialised string variable Adam Ward
2020-12-07 17:15 ` [PATCH 2/2] regulator: da9121: Fix index used for DT property Adam Ward
2020-12-08 17:10 ` [PATCH 0/2] regulator: da9121: bug fixes Mark Brown

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).