aboutsummaryrefslogtreecommitdiffstats
path: root/sound/usb
diff options
context:
space:
mode:
Diffstat (limited to 'sound/usb')
-rw-r--r--sound/usb/stream.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/sound/usb/stream.c b/sound/usb/stream.c
index 8951f77a7201..7db2f8958e79 100644
--- a/sound/usb/stream.c
+++ b/sound/usb/stream.c
@@ -393,6 +393,14 @@ static int parse_uac_endpoint_attributes(struct snd_usb_audio *chip,
393 if (!csep && altsd->bNumEndpoints >= 2) 393 if (!csep && altsd->bNumEndpoints >= 2)
394 csep = snd_usb_find_desc(alts->endpoint[1].extra, alts->endpoint[1].extralen, NULL, USB_DT_CS_ENDPOINT); 394 csep = snd_usb_find_desc(alts->endpoint[1].extra, alts->endpoint[1].extralen, NULL, USB_DT_CS_ENDPOINT);
395 395
396 /*
397 * If we can't locate the USB_DT_CS_ENDPOINT descriptor in the extra
398 * bytes after the first endpoint, go search the entire interface.
399 * Some devices have it directly *before* the standard endpoint.
400 */
401 if (!csep)
402 csep = snd_usb_find_desc(alts->extra, alts->extralen, NULL, USB_DT_CS_ENDPOINT);
403
396 if (!csep || csep->bLength < 7 || 404 if (!csep || csep->bLength < 7 ||
397 csep->bDescriptorSubtype != UAC_EP_GENERAL) { 405 csep->bDescriptorSubtype != UAC_EP_GENERAL) {
398 snd_printk(KERN_WARNING "%d:%u:%d : no or invalid" 406 snd_printk(KERN_WARNING "%d:%u:%d : no or invalid"