2022-07-14 10:42:22

by Axel Lin

[permalink] [raw]
Subject: [PATCH] regulator: max597x: Don't return uninitialized variable in .probe

Remove the code checking and returning uninitialized variable.

Signed-off-by: Axel Lin <[email protected]>
---
drivers/regulator/max597x-regulator.c | 3 ---
1 file changed, 3 deletions(-)

diff --git a/drivers/regulator/max597x-regulator.c b/drivers/regulator/max597x-regulator.c
index 5e09aa4213be..03c6027682d8 100644
--- a/drivers/regulator/max597x-regulator.c
+++ b/drivers/regulator/max597x-regulator.c
@@ -453,9 +453,6 @@ static int max597x_regulator_probe(struct platform_device *pdev)
data->num_switches = num_switches;
data->regmap = max597x->regmap;

- if (ret < 0)
- return ret;
-
ret = max597x_adc_range(data->regmap, i, &max597x->irng[i], &max597x->mon_rng[i]);
if (ret < 0)
return ret;
--
2.34.1


2022-07-14 16:16:48

by Mark Brown

[permalink] [raw]
Subject: Re: [PATCH] regulator: max597x: Don't return uninitialized variable in .probe

On Thu, 14 Jul 2022 18:12:12 +0800, Axel Lin wrote:
> Remove the code checking and returning uninitialized variable.
>
>

Applied to

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

Thanks!

[1/1] regulator: max597x: Don't return uninitialized variable in .probe
commit: d1d9d40891f92573ab2aff9bed9293be9b667067

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