mirror of
https://github.com/hardkernel/linux.git
synced 2026-06-07 03:15:31 +09:00
ALSA: vx: Don't try to update capture stream before running
[ Upstream commit ed3c177d96 ]
The update of stream costs significantly, and we should avoid it
unless the stream really has started. Check pipe->running flag
instead of pipe->prepared.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Sasha Levin <alexander.levin@verizon.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
committed by
Greg Kroah-Hartman
parent
9dc7637700
commit
0f4ea85748
@@ -1015,7 +1015,7 @@ static void vx_pcm_capture_update(struct vx_core *chip, struct snd_pcm_substream
|
||||
int size, space, count;
|
||||
struct snd_pcm_runtime *runtime = subs->runtime;
|
||||
|
||||
if (! pipe->prepared || (chip->chip_status & VX_STAT_IS_STALE))
|
||||
if (!pipe->running || (chip->chip_status & VX_STAT_IS_STALE))
|
||||
return;
|
||||
|
||||
size = runtime->buffer_size - snd_pcm_capture_avail(runtime);
|
||||
|
||||
Reference in New Issue
Block a user