Skip to content

Commit 0c95666

Browse files
AxelLinbroonie
authored andcommitted
ASoC: rt5665: Fix missing mutex_unlock in rt5665_calibrate
Reported-by: Julia Lawall <julia.lawall@lip6.fr> Signed-off-by: Axel Lin <axel.lin@ingics.com> Signed-off-by: Mark Brown <broonie@kernel.org>
1 parent 33ada14 commit 0c95666

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

sound/soc/codecs/rt5665.c

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4587,7 +4587,7 @@ static void rt5665_calibrate(struct rt5665_priv *rt5665)
45874587
pr_err("HP Calibration Failure\n");
45884588
regmap_write(rt5665->regmap, RT5665_RESET, 0);
45894589
regcache_cache_bypass(rt5665->regmap, false);
4590-
return;
4590+
goto out_unlock;
45914591
}
45924592

45934593
count++;
@@ -4606,7 +4606,7 @@ static void rt5665_calibrate(struct rt5665_priv *rt5665)
46064606
pr_err("MONO Calibration Failure\n");
46074607
regmap_write(rt5665->regmap, RT5665_RESET, 0);
46084608
regcache_cache_bypass(rt5665->regmap, false);
4609-
return;
4609+
goto out_unlock;
46104610
}
46114611

46124612
count++;
@@ -4621,6 +4621,7 @@ static void rt5665_calibrate(struct rt5665_priv *rt5665)
46214621
regmap_write(rt5665->regmap, RT5665_BIAS_CUR_CTRL_8, 0xa602);
46224622
regmap_write(rt5665->regmap, RT5665_ASRC_8, 0x0120);
46234623

4624+
out_unlock:
46244625
mutex_unlock(&rt5665->calibrate_mutex);
46254626
}
46264627

0 commit comments

Comments
 (0)