Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 2ab8e744 authored by Richard Fitzgerald's avatar Richard Fitzgerald Committed by Mark Brown
Browse files

ASoC: arizona: No need to update_bits when writing AEC clock control



The bits in the ARIZONA_CLOCK_CONTROL register only respond to writes of
a '1', a write of '0' is ignored. So there's no need to use update_bits.
We can do a simple write to set bits.

Signed-off-by: default avatarRichard Fitzgerald <rf@opensource.wolfsonmicro.com>
Signed-off-by: default avatarMark Brown <broonie@kernel.org>
parent 8e42db1e
Loading
Loading
Loading
Loading
+1 −2
Original line number Original line Diff line number Diff line
@@ -1124,7 +1124,6 @@ int arizona_anc_ev(struct snd_soc_dapm_widget *w,
		   int event)
		   int event)
{
{
	struct snd_soc_codec *codec = snd_soc_dapm_to_codec(w->dapm);
	struct snd_soc_codec *codec = snd_soc_dapm_to_codec(w->dapm);
	unsigned int mask = 0x3 << w->shift;
	unsigned int val;
	unsigned int val;


	switch (event) {
	switch (event) {
@@ -1138,7 +1137,7 @@ int arizona_anc_ev(struct snd_soc_dapm_widget *w,
		return 0;
		return 0;
	}
	}


	snd_soc_update_bits(codec, ARIZONA_CLOCK_CONTROL, mask, val);
	snd_soc_write(codec, ARIZONA_CLOCK_CONTROL, val);


	return 0;
	return 0;
}
}