[ALSA] usb-audio - Fix the minimum period size per transfer mode
The minimal period size is 125us for high-speed mode while
1ms for full-speed mode.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Jaroslav Kysela <perex@suse.cz>
diff --git a/sound/usb/usbaudio.c b/sound/usb/usbaudio.c
index b6d8863..78efcff 100644
--- a/sound/usb/usbaudio.c
+++ b/sound/usb/usbaudio.c
@@ -1879,7 +1879,9 @@
/* set the period time minimum 1ms */
snd_pcm_hw_constraint_minmax(runtime, SNDRV_PCM_HW_PARAM_PERIOD_TIME,
- 1000 * MIN_PACKS_URB,
+ snd_usb_get_speed(subs->dev) == USB_SPEED_FULL ?
+
+ 1000 * MIN_PACKS_URB : 125 * MIN_PACKS_URB,
/*(nrpacks * MAX_URBS) * 1000*/ UINT_MAX);
if (check_hw_params_convention(subs)) {