Skip to contentSkip to conversation

ASoC: intel: atom: 2 bug-fixes for the atom SST driver

PATCH In review Hans de Goede 2 participants 4 messages Mar 24, 2021

Subsystems (4)
lore
Share & tools
lore
#0 lore raw

v2 cover ASoC: intel: atom: 2 bug-fixes for the atom SST driver

Hi All,

Here is v2 of my bugfix series for the ASoC Intel Atom SST driver.

The patches are unchanged except for adding Pierre-Louis' Acked-By and adding a fixed (subject fixed) version of the Fixes: tag which Pierre-Louis suggested.

The first patch fixes a bug which is causing audio to now work with pipewire and both Fedora and Arch Linux are moving towards using pipewire as the default sound-server.

As such it would be good if we can get these 2 bugfixes added to a 5.12-rc# release.

Regards,

Hans

Hans de Goede (2):
ASoC: intel: atom: Stop advertising non working S24LE support
ASoC: intel: atom: Remove 44100 sample-rate from the media and
deep-buffer DAI descriptions

 sound/soc/intel/atom/sst-mfld-platform-pcm.c | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)
Signature · 1 line
2.30.2
#1 lore raw

PATCH v2 1/2 ASoC: intel: atom: Stop advertising non working S24LE support

The SST firmware's media and deep-buffer inputs are hardcoded to S16LE, the corresponding DAIs don't have a hw_params callback and their prepare callback also does not take the format into account.

So far the advertising of non working S24LE support has not caused issues because pulseaudio defaults to S16LE, but changing pulse-audio's config to use S24LE will result in broken sound.

Pipewire is replacing pulse now and pipewire prefers S24LE over S16LE when available, causing the problem of the broken S24LE support to come to the surface now.

Fixes 098c2cd281409 ("ASoC: Intel: Atom: add 24-bit support for media playback and capture")
---
 sound/soc/intel/atom/sst-mfld-platform-pcm.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)
sound/soc/intel/atom/sst-mfld-platform-pcm.c +3 -3
index 9e9b05883557..aa5dd590ddd5 100644
@@ -488,14 +488,14 @@ static struct snd_soc_dai_driver sst_platform_dai[] = {
 		.channels_min = SST_STEREO,
 		.channels_max = SST_STEREO,
 		.rates = SNDRV_PCM_RATE_44100|SNDRV_PCM_RATE_48000,
-		.formats = SNDRV_PCM_FMTBIT_S16_LE | SNDRV_PCM_FMTBIT_S24_LE,
+		.formats = SNDRV_PCM_FMTBIT_S16_LE,
 	},
 	.capture = {
 		.stream_name = "Headset Capture",
 		.channels_min = 1,
 		.channels_max = 2,
 		.rates = SNDRV_PCM_RATE_44100|SNDRV_PCM_RATE_48000,
-		.formats = SNDRV_PCM_FMTBIT_S16_LE | SNDRV_PCM_FMTBIT_S24_LE,
+		.formats = SNDRV_PCM_FMTBIT_S16_LE,
 	},
 },
 {
@@ -506,7 +506,7 @@ static struct snd_soc_dai_driver sst_platform_dai[] = {
 		.channels_min = SST_STEREO,
 		.channels_max = SST_STEREO,
 		.rates = SNDRV_PCM_RATE_44100|SNDRV_PCM_RATE_48000,
-		.formats = SNDRV_PCM_FMTBIT_S16_LE | SNDRV_PCM_FMTBIT_S24_LE,
+		.formats = SNDRV_PCM_FMTBIT_S16_LE,
 	},
 },
 {
Signature · 1 line
2.30.2
#2 lore raw

PATCH v2 2/2 ASoC: intel: atom: Remove 44100 sample-rate from the media and deep-buffer DAI descriptions

In reply to Hans de Goede

The media and deep-buffer DAIs only support 48000 Hz samplerate, remove the 44100 sample-rate from their descriptions.

---
 sound/soc/intel/atom/sst-mfld-platform-pcm.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)
sound/soc/intel/atom/sst-mfld-platform-pcm.c +3 -3
index aa5dd590ddd5..4124aa2fc247 100644
@@ -487,14 +487,14 @@ static struct snd_soc_dai_driver sst_platform_dai[] = {
 		.stream_name = "Headset Playback",
 		.channels_min = SST_STEREO,
 		.channels_max = SST_STEREO,
-		.rates = SNDRV_PCM_RATE_44100|SNDRV_PCM_RATE_48000,
+		.rates = SNDRV_PCM_RATE_48000,
 		.formats = SNDRV_PCM_FMTBIT_S16_LE,
 	},
 	.capture = {
 		.stream_name = "Headset Capture",
 		.channels_min = 1,
 		.channels_max = 2,
-		.rates = SNDRV_PCM_RATE_44100|SNDRV_PCM_RATE_48000,
+		.rates = SNDRV_PCM_RATE_48000,
 		.formats = SNDRV_PCM_FMTBIT_S16_LE,
 	},
 },
@@ -505,7 +505,7 @@ static struct snd_soc_dai_driver sst_platform_dai[] = {
 		.stream_name = "Deepbuffer Playback",
 		.channels_min = SST_STEREO,
 		.channels_max = SST_STEREO,
-		.rates = SNDRV_PCM_RATE_44100|SNDRV_PCM_RATE_48000,
+		.rates = SNDRV_PCM_RATE_48000,
 		.formats = SNDRV_PCM_FMTBIT_S16_LE,
 	},
 },
Signature · 1 line
2.30.2
maintainer
#3 lore raw
In reply to Hans de Goede
Quoted 11 lines · Hans de Goede

Here is v2 of my bugfix series for the ASoC Intel Atom SST driver.

The patches are unchanged except for adding Pierre-Louis' Acked-By and adding a fixed (subject fixed) version of the Fixes: tag which Pierre-Louis suggested.

The first patch fixes a bug which is causing audio to now work with pipewire and both Fedora and Arch Linux are moving towards using pipewire as the default sound-server.

[...]

Applied to

https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git for-next

Thanks!

[1/2] ASoC: intel: atom: Stop advertising non working S24LE support

      commit: aa65bacdb70e549a81de03ec72338e1047842883
[2/2] ASoC: intel: atom: Remove 44100 sample-rate from the media and deep-buffer DAI descriptions
      commit: 632aeebe1b7a3a8b193d71942a10e66919bebfb8

All being well this means that it will be integrated into the linux-next tree (usually sometime in the next 24 hours) and sent to Linus during the next merge window (or sooner if it is a bug fix), however if problems are discovered then the patch may be dropped or reverted.

You may get further e-mails resulting from automated or manual testing and review of the tree, please engage with people reporting problems and send followup patches addressing any issues that are reported if needed.

If any updates are required or you are submitting further changes they should be sent as incremental updates against current git, existing patches will not be replaced.

Please add any relevant lists and maintainers to the CCs when replying to this mail.

Thanks,
Mark