提交 2fd23293 编写于 作者: T Takashi Sakamoto 提交者: Takashi Iwai

ALSA: oxfw: fix to handle correct stream for PCM playback

When userspace application calls ioctl(2) to configure hardware for PCM
playback substream, ALSA OXFW driver handles incoming AMDTP stream.
In this case, outgoing AMDTP stream should be handled.

This commit fixes the bug for v5.3-rc kernel.

Fixes: 4f380d00 ("ALSA: oxfw: configure packet format in pcm.hw_params callback")
Signed-off-by: NTakashi Sakamoto <o-takashi@sakamocchi.jp>
Signed-off-by: NTakashi Iwai <tiwai@suse.de>
上级 75545304
...@@ -248,7 +248,7 @@ static int pcm_playback_hw_params(struct snd_pcm_substream *substream, ...@@ -248,7 +248,7 @@ static int pcm_playback_hw_params(struct snd_pcm_substream *substream,
unsigned int channels = params_channels(hw_params); unsigned int channels = params_channels(hw_params);
mutex_lock(&oxfw->mutex); mutex_lock(&oxfw->mutex);
err = snd_oxfw_stream_reserve_duplex(oxfw, &oxfw->tx_stream, err = snd_oxfw_stream_reserve_duplex(oxfw, &oxfw->rx_stream,
rate, channels); rate, channels);
if (err >= 0) if (err >= 0)
++oxfw->substreams_count; ++oxfw->substreams_count;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册