ALSA: usb-audio: fix selector unit string index accessor
authorDaniel Mack <daniel@caiaq.de>
Mon, 31 May 2010 11:35:39 +0000 (13:35 +0200)
committerTakashi Iwai <tiwai@suse.de>
Mon, 31 May 2010 16:16:31 +0000 (18:16 +0200)
This is another regression from the UAC2 code refactoring.

Signed-off-by: Daniel Mack <daniel@caiaq.de>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
include/linux/usb/audio.h

index 5d646c3887524febf0d39f81d2e7c4a832f875fe..ed5cf92a3c0ffca49a00c435e069412e44839857 100644 (file)
@@ -244,7 +244,7 @@ struct uac_selector_unit_descriptor {
 static inline __u8 uac_selector_unit_iSelector(struct uac_selector_unit_descriptor *desc)
 {
        __u8 *raw = (__u8 *) desc;
-       return raw[9 + desc->bLength - 1];
+       return raw[desc->bLength - 1];
 }
 
 /* 4.3.2.5 Feature Unit Descriptor */