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

Commit 11cef5f0 authored by Mark Brown's avatar Mark Brown
Browse files

ASoC: Use DC servo startup mode when not doing DCS correction



Devices which do not have a DCS correction applied can use the explicit
DC servo startup mode for optimal startup performance. This most
immediately affects the WM8958.

Signed-off-by: default avatarMark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: default avatarLiam Girdwood <lrg@slimlogic.co.uk>
parent 4b666729
Loading
Loading
Loading
Loading
+14 −6
Original line number Diff line number Diff line
@@ -105,12 +105,20 @@ static void calibrate_dc_servo(struct snd_soc_codec *codec)
		return;
	}

	/* Devices not using a DCS code correction have startup mode */
	if (hubs->dcs_codes) {
		/* Set for 32 series updates */
		snd_soc_update_bits(codec, WM8993_DC_SERVO_1,
				    WM8993_DCS_SERIES_NO_01_MASK,
				    32 << WM8993_DCS_SERIES_NO_01_SHIFT);
		wait_for_dc_servo(codec,
			  WM8993_DCS_TRIG_SERIES_0 | WM8993_DCS_TRIG_SERIES_1);
				  WM8993_DCS_TRIG_SERIES_0 |
				  WM8993_DCS_TRIG_SERIES_1);
	} else {
		wait_for_dc_servo(codec,
				  WM8993_DCS_TRIG_STARTUP_0 |
				  WM8993_DCS_TRIG_STARTUP_1);
	}

	/* Different chips in the family support different readback
	 * methods.