{
struct snd_pcm_hardware *hw = &runtime->hw;
- soc_pcm_hw_init(hw);
soc_pcm_hw_update_rate(hw, stream);
soc_pcm_hw_update_chan(hw, stream);
- soc_pcm_hw_update_format(hw, stream);
+ if (runtime->hw.formats)
+ runtime->hw.formats &= stream->formats;
+ else
+ runtime->hw.formats = stream->formats;
}
static void dpcm_runtime_merge_format(struct snd_pcm_substream *substream,
static void dpcm_set_fe_runtime(struct snd_pcm_substream *substream)
{
struct snd_pcm_runtime *runtime = substream->runtime;
+ struct snd_pcm_hardware *hw = &runtime->hw;
struct snd_soc_pcm_runtime *rtd = asoc_substream_to_rtd(substream);
struct snd_soc_dai *cpu_dai;
int i;
+ soc_pcm_hw_init(hw);
+
for_each_rtd_cpu_dais(rtd, i, cpu_dai) {
/*
* Skip CPUs which don't support the current stream