mirror of
https://github.com/hardkernel/linux.git
synced 2026-06-05 02:21:52 +09:00
ALSA: usb-audio: Less restriction for low-latency playback mode
commit53451b6da8upstream. The recent support for the improved low-latency playback mode applied the SNDRV_PCM_INFO_EXPLICIT_SYNC flag for the target streams, but this was a slight overkill. The use of the flag above disables effectively both PCM status and control mmaps, while basically what we want to track is only about the appl_ptr update. For less restriction, use a more proper flag, SNDRV_PCM_INFO_SYNC_APPLPTR instead, which disables only the control mmap. Fixes:d5f871f89e("ALSA: usb-audio: Improved lowlatency playback support") Link: https://lore.kernel.org/r/20211011103650.10182-1-tiwai@suse.de Signed-off-by: Takashi Iwai <tiwai@suse.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
committed by
Greg Kroah-Hartman
parent
c7ac29edfb
commit
2cea047b74
@@ -1095,7 +1095,7 @@ static int snd_usb_pcm_open(struct snd_pcm_substream *substream)
|
||||
/* need an explicit sync to catch applptr update in low-latency mode */
|
||||
if (direction == SNDRV_PCM_STREAM_PLAYBACK &&
|
||||
as->chip->lowlatency)
|
||||
runtime->hw.info |= SNDRV_PCM_INFO_EXPLICIT_SYNC;
|
||||
runtime->hw.info |= SNDRV_PCM_INFO_SYNC_APPLPTR;
|
||||
runtime->private_data = subs;
|
||||
subs->pcm_substream = substream;
|
||||
/* runtime PM is also done there */
|
||||
|
||||
Reference in New Issue
Block a user