diff options
author | Ingo Molnar <mingo@kernel.org> | 2013-04-08 11:43:30 +0200 |
---|---|---|
committer | Ingo Molnar <mingo@kernel.org> | 2013-04-08 11:43:30 +0200 |
commit | 529801898b24544f93532217ce18a7ebbb2b8c4f (patch) | |
tree | c51c8fd808e6cff15cabb1a9ac29be0661942384 /sound/usb/card.c | |
parent | b847d0501afec4c7b12eb276aec10a2834f953ea (diff) | |
parent | 23995bbee01d75f09f72b1380bd6045a5b02947b (diff) |
Merge branch 'for-tip' of git://git.kernel.org/pub/scm/linux/kernel/git/rric/oprofile into perf/core
Pull IBM zEnterprise EC12 support patchlet from Robert Richter.
Signed-off-by: Ingo Molnar <mingo@kernel.org>
Diffstat (limited to 'sound/usb/card.c')
-rw-r--r-- | sound/usb/card.c | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/sound/usb/card.c b/sound/usb/card.c index 803953a9bff3..2da8ad75fd96 100644 --- a/sound/usb/card.c +++ b/sound/usb/card.c @@ -244,6 +244,21 @@ static int snd_usb_create_streams(struct snd_usb_audio *chip, int ctrlif) usb_ifnum_to_if(dev, ctrlif)->intf_assoc; if (!assoc) { + /* + * Firmware writers cannot count to three. So to find + * the IAD on the NuForce UDH-100, also check the next + * interface. + */ + struct usb_interface *iface = + usb_ifnum_to_if(dev, ctrlif + 1); + if (iface && + iface->intf_assoc && + iface->intf_assoc->bFunctionClass == USB_CLASS_AUDIO && + iface->intf_assoc->bFunctionProtocol == UAC_VERSION_2) + assoc = iface->intf_assoc; + } + + if (!assoc) { snd_printk(KERN_ERR "Audio class v2 interfaces need an interface association\n"); return -EINVAL; } |