]> git.karo-electronics.de Git - linux-beck.git/commitdiff
xhci: use usb_ss_max_streams in xhci_check_streams_endpoint
authorHans de Goede <hdegoede@redhat.com>
Fri, 4 Oct 2013 15:05:55 +0000 (17:05 +0200)
committerSarah Sharp <sarah.a.sharp@linux.intel.com>
Tue, 4 Mar 2014 23:38:02 +0000 (15:38 -0800)
The ss_ep_comp bmAttributes filed can contain more info then just the
streams, use usb_ss_max_streams to properly get max streams.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Sarah Sharp <sarah.a.sharp@linux.intel.com>
drivers/usb/host/xhci.c

index c3fa32a905ec8e2b525af3b94a95e16e4b6c8eaf..6cb9c2235a0bfda07190232475548e8090be414b 100644 (file)
@@ -2971,7 +2971,7 @@ static int xhci_check_streams_endpoint(struct xhci_hcd *xhci,
        ret = xhci_check_args(xhci_to_hcd(xhci), udev, ep, 1, true, __func__);
        if (ret <= 0)
                return -EINVAL;
-       if (ep->ss_ep_comp.bmAttributes == 0) {
+       if (usb_ss_max_streams(&ep->ss_ep_comp) == 0) {
                xhci_warn(xhci, "WARN: SuperSpeed Endpoint Companion"
                                " descriptor for ep 0x%x does not support streams\n",
                                ep->desc.bEndpointAddress);