regulator: max597x: Don't return uninitialized variable in .probe

Remove the code checking and returning uninitialized variable.

Signed-off-by: Axel Lin <axel.lin@ingics.com>
Link: https://lore.kernel.org/r/20220714101212.502824-1-axel.lin@ingics.com
Signed-off-by: Mark Brown <broonie@kernel.org>
This commit is contained in:
Axel Lin 2022-07-14 18:12:12 +08:00 committed by Mark Brown
parent 0447505739
commit be6bd82351
No known key found for this signature in database
GPG Key ID: 24D68B725D5487D0

View File

@ -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;