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

Commit 278047fd authored by Mark Brown's avatar Mark Brown
Browse files

ASoC: Don't tell applications about msbits unless we're ignoring input



On the off chance that an application both pays attention and gets
confused.

Signed-off-by: default avatarMark Brown <broonie@opensource.wolfsonmicro.com>
parent 09452f23
Loading
Loading
Loading
Loading
+5 −3
Original line number Original line Diff line number Diff line
@@ -85,9 +85,11 @@ static void soc_pcm_apply_msb(struct snd_pcm_substream *substream,
		return;
		return;


	for (i = 0; i < ARRAY_SIZE(sample_sizes); i++) {
	for (i = 0; i < ARRAY_SIZE(sample_sizes); i++) {
		ret = snd_pcm_hw_constraint_msbits(substream->runtime,
		if (bits >= sample_sizes[i])
						   0, sample_sizes[i],
			continue;
						   bits);

		ret = snd_pcm_hw_constraint_msbits(substream->runtime, 0,
						   sample_sizes[i], bits);
		if (ret != 0)
		if (ret != 0)
			dev_warn(dai->dev,
			dev_warn(dai->dev,
				 "Failed to set MSB %d/%d: %d\n",
				 "Failed to set MSB %d/%d: %d\n",