aboutsummaryrefslogtreecommitdiffstats
path: root/sound/usb/card.c
diff options
context:
space:
mode:
Diffstat (limited to 'sound/usb/card.c')
-rw-r--r--sound/usb/card.c17
1 files changed, 12 insertions, 5 deletions
diff --git a/sound/usb/card.c b/sound/usb/card.c
index 498a2d8fa4b..4aa4678e0a0 100644
--- a/sound/usb/card.c
+++ b/sound/usb/card.c
@@ -216,6 +216,11 @@ static int snd_usb_create_streams(struct snd_usb_audio *chip, int ctrlif)
216 } 216 }
217 217
218 switch (protocol) { 218 switch (protocol) {
219 default:
220 snd_printdd(KERN_WARNING "unknown interface protocol %#02x, assuming v1\n",
221 protocol);
222 /* fall through */
223
219 case UAC_VERSION_1: { 224 case UAC_VERSION_1: {
220 struct uac1_ac_header_descriptor *h1 = control_header; 225 struct uac1_ac_header_descriptor *h1 = control_header;
221 226
@@ -253,10 +258,6 @@ static int snd_usb_create_streams(struct snd_usb_audio *chip, int ctrlif)
253 258
254 break; 259 break;
255 } 260 }
256
257 default:
258 snd_printk(KERN_ERR "unknown protocol version 0x%02x\n", protocol);
259 return -EINVAL;
260 } 261 }
261 262
262 return 0; 263 return 0;
@@ -480,7 +481,13 @@ static void *snd_usb_audio_probe(struct usb_device *dev,
480 goto __error; 481 goto __error;
481 } 482 }
482 483
483 chip->ctrl_intf = alts; 484 /*
485 * For devices with more than one control interface, we assume the
486 * first contains the audio controls. We might need a more specific
487 * check here in the future.
488 */
489 if (!chip->ctrl_intf)
490 chip->ctrl_intf = alts;
484 491
485 if (err > 0) { 492 if (err > 0) {
486 /* create normal USB audio interfaces */ 493 /* create normal USB audio interfaces */