Unverified Commit 592ab393 authored by Martin Povišer's avatar Martin Povišer Committed by Mark Brown
Browse files

ASoC: tas2764: Reinit cache on part reset



When the part is reset in component_probe, do not forget to reinit the
regcache, otherwise the cache can get out of sync with the part's
actual state. This fix is similar to commit 0a0342ed
("ASoC: tas2770: Reinit regcache on reset") which concerned the
tas2770 driver.

Fixes: 827ed8a0 ("ASoC: tas2764: Add the driver for the TAS2764")
Reviewed-by: default avatarNeal Gompa <neal@gompa.dev>
Signed-off-by: default avatarMartin Povišer <povik+lin@cutebit.org>
Signed-off-by: default avatarJames Calligeros <jcalligeros99@gmail.com>
Link: https://patch.msgid.link/20250406-apple-codec-changes-v5-3-50a00ec850a3@gmail.com


Signed-off-by: default avatarMark Brown <broonie@kernel.org>
parent 7699892a
Loading
Loading
Loading
Loading
+3 −0
Original line number Diff line number Diff line
@@ -546,6 +546,8 @@ static uint8_t sn012776_bop_presets[] = {
	0x06, 0x3e, 0x37, 0x30, 0xff, 0xe6
};

static const struct regmap_config tas2764_i2c_regmap;

static int tas2764_codec_probe(struct snd_soc_component *component)
{
	struct tas2764_priv *tas2764 = snd_soc_component_get_drvdata(component);
@@ -559,6 +561,7 @@ static int tas2764_codec_probe(struct snd_soc_component *component)
	}

	tas2764_reset(tas2764);
	regmap_reinit_cache(tas2764->regmap, &tas2764_i2c_regmap);

	if (tas2764->irq) {
		ret = snd_soc_component_write(tas2764->component, TAS2764_INT_MASK0, 0xff);