Skip to content

Commit

Permalink
ALSA: hiface: Fix M2Tech hiFace driver sampling rate change
Browse files Browse the repository at this point in the history
Sampling rate changes after first set one are not reflected to the
hardware, while driver and ALSA think the rate has been changed.

Fix the problem by properly stopping the interface at the beginning of
prepare call, allowing new rate to be set to the hardware. This keeps
the hardware in sync with the driver.

Signed-off-by: Jussi Laako <jussi@sonarnerd.net>
Cc: <stable@vger.kernel.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
  • Loading branch information
jlaako authored and tiwai committed Dec 12, 2016
1 parent 0120073 commit 995c6a7
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions sound/usb/hiface/pcm.c
Original file line number Diff line number Diff line change
Expand Up @@ -445,6 +445,8 @@ static int hiface_pcm_prepare(struct snd_pcm_substream *alsa_sub)

mutex_lock(&rt->stream_mutex);

hiface_pcm_stream_stop(rt);

sub->dma_off = 0;
sub->period_off = 0;

Expand Down

0 comments on commit 995c6a7

Please sign in to comment.