Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

ALSA: snd-usb: fix next_packet_size calls for pause case

Also fix the calls to next_packet_size() for the pause case. This was
missed in 245baf983 ("ALSA: snd-usb: fix calls to next_packet_size").

Signed-off-by: Daniel Mack <zonque@gmail.com>
Reviewed-by: Takashi Iwai <tiwai@suse.de>
Reported-and-tested-by: Christian Tefzer <ctrefzer@gmx.de>
Cc: stable@kernel.org
[ Taking directly because Takashi is on vacation - Linus ]
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>

authored by

Daniel Mack and committed by
Linus Torvalds
8dce30c8 9a7c5909

+7 -1
+7 -1
sound/usb/endpoint.c
··· 197 197 /* no data provider, so send silence */ 198 198 unsigned int offs = 0; 199 199 for (i = 0; i < ctx->packets; ++i) { 200 - int counts = ctx->packet_size[i]; 200 + int counts; 201 + 202 + if (ctx->packet_size[i]) 203 + counts = ctx->packet_size[i]; 204 + else 205 + counts = snd_usb_endpoint_next_packet_size(ep); 206 + 201 207 urb->iso_frame_desc[i].offset = offs * ep->stride; 202 208 urb->iso_frame_desc[i].length = counts * ep->stride; 203 209 offs += counts;