Skip to content

Commit bb72b1d

Browse files
mcdermjpelwell
authored andcommitted
ASoC: tlv320aic32x4: Register clocks before registering component
Commit 1ca1156 upstream Clock registration must be performed before the component is registered. aic32x4_component_probe attempts to get all the clocks right off the bat. If the component is registered before the clocks there is a race condition where the clocks may not be registered by the time aic32x4_componet_probe actually runs. Fixes: d1c859d ("ASoC: codec: tlv3204: Increased maximum supported channels") Cc: stable@vger.kernel.org Signed-off-by: Annaliese McDermond <nh6z@nh6z.net> Link: https://lore.kernel.org/r/0101017889850206-dcac4cce-8cc8-4a21-80e9-4e4bef44b981-000000@us-west-2.amazonses.com Signed-off-by: Mark Brown <broonie@kernel.org>
1 parent 911edcc commit bb72b1d

1 file changed

Lines changed: 4 additions & 4 deletions

File tree

‎sound/soc/codecs/tlv320aic32x4.c‎

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1243,17 +1243,17 @@ int aic32x4_probe(struct device *dev, struct regmap *regmap)
12431243
if (ret)
12441244
goto err_disable_regulators;
12451245

1246+
ret = aic32x4_register_clocks(dev, aic32x4->mclk_name);
1247+
if (ret)
1248+
goto err_disable_regulators;
1249+
12461250
ret = devm_snd_soc_register_component(dev,
12471251
&soc_component_dev_aic32x4, &aic32x4_dai, 1);
12481252
if (ret) {
12491253
dev_err(dev, "Failed to register component\n");
12501254
goto err_disable_regulators;
12511255
}
12521256

1253-
ret = aic32x4_register_clocks(dev, aic32x4->mclk_name);
1254-
if (ret)
1255-
goto err_disable_regulators;
1256-
12571257
return 0;
12581258

12591259
err_disable_regulators:

0 commit comments

Comments
 (0)