mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH] regulator: adp5055: Fix error code in adp5055_of_parse_cb()
@ 2026-07-10 19:34 Dan Carpenter
  2026-07-14 21:22 ` Mark Brown
  0 siblings, 1 reply; 2+ messages in thread
From: Dan Carpenter @ 2026-07-10 19:34 UTC (permalink / raw)
  To: Alexis Czezar Torreno
  Cc: Liam Girdwood, Mark Brown, linux-kernel, kernel-janitors

This code accidentally returned the wrong variable instead of a negative
error code.  Return -EINVAL.

Fixes: 147b2a96f24e ("regulator: adp5055: Add driver for adp5055")
Signed-off-by: Dan Carpenter <error27@gmail.com>
---
 drivers/regulator/adp5055-regulator.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/regulator/adp5055-regulator.c b/drivers/regulator/adp5055-regulator.c
index a79274d530df..194dcfe4f527 100644
--- a/drivers/regulator/adp5055-regulator.c
+++ b/drivers/regulator/adp5055-regulator.c
@@ -224,7 +224,7 @@ static int adp5055_of_parse_cb(struct device_node *np,
 		adp5055->dvs_limit_upper[id] = pval;
 
 	if (adp5055->dvs_limit_upper[id] > 192000 || adp5055->dvs_limit_upper[id] < 12000)
-		return dev_err_probe(config->dev, adp5055->dvs_limit_upper[id],
+		return dev_err_probe(config->dev, -EINVAL,
 			"Out of range - dvs-limit-upper-microvolt value.");
 
 	ret = of_property_read_u32(np, "adi,dvs-limit-lower-microvolt", &pval);
-- 
2.53.0


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

* Re: [PATCH] regulator: adp5055: Fix error code in adp5055_of_parse_cb()
  2026-07-10 19:34 [PATCH] regulator: adp5055: Fix error code in adp5055_of_parse_cb() Dan Carpenter
@ 2026-07-14 21:22 ` Mark Brown
  0 siblings, 0 replies; 2+ messages in thread
From: Mark Brown @ 2026-07-14 21:22 UTC (permalink / raw)
  To: Alexis Czezar Torreno, Dan Carpenter
  Cc: Liam Girdwood, linux-kernel, kernel-janitors

On Fri, 10 Jul 2026 22:34:44 +0300, Dan Carpenter wrote:
> regulator: adp5055: Fix error code in adp5055_of_parse_cb()

Applied to

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

Thanks!

[1/1] regulator: adp5055: Fix error code in adp5055_of_parse_cb()
      https://git.kernel.org/broonie/regulator/c/153bc959ce0f

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] 2+ messages in thread

end of thread, other threads:[~2026-07-15 11:35 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-07-10 19:34 [PATCH] regulator: adp5055: Fix error code in adp5055_of_parse_cb() Dan Carpenter
2026-07-14 21:22 ` Mark Brown

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox