summaryrefslogtreecommitdiff
path: root/drivers
diff options
context:
space:
mode:
authorHans de Goede <hdegoede@redhat.com>2014-07-25 22:01:27 +0200
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2014-10-09 12:23:49 -0700
commitd751f8815f9ada8fb6d0b3ca54fcde2a61b5b950 (patch)
tree085f650d9d277ba97b540f01745e13aa261ad1e7 /drivers
parentd9d4dc60d6a31906483d620a2ce0552f7a921df9 (diff)
uas: Log a warning when we cannot use uas because the hcd lacks streams
commit 43508be512661c905d0320ee73e0b65ef36d2459 upstream. So that an user who wants to use uas can see why he is not getting uas. Also move the check down so that we don't warn if there are other reasons why uas cannot work. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/usb/storage/uas-detect.h12
1 files changed, 9 insertions, 3 deletions
diff --git a/drivers/usb/storage/uas-detect.h b/drivers/usb/storage/uas-detect.h
index 618b41791744..503ac5c8d80f 100644
--- a/drivers/usb/storage/uas-detect.h
+++ b/drivers/usb/storage/uas-detect.h
@@ -64,9 +64,6 @@ static int uas_use_uas_driver(struct usb_interface *intf,
if (flags & US_FL_IGNORE_UAS)
return 0;
- if (udev->speed >= USB_SPEED_SUPER && !hcd->can_do_streams)
- return 0;
-
alt = uas_find_uas_alt_setting(intf);
if (alt < 0)
return 0;
@@ -84,5 +81,14 @@ static int uas_use_uas_driver(struct usb_interface *intf,
return 0;
}
+ if (udev->speed >= USB_SPEED_SUPER && !hcd->can_do_streams) {
+ dev_warn(&udev->dev,
+ "USB controller %s does not support streams, which are required by the UAS driver.\n",
+ hcd_to_bus(hcd)->bus_name);
+ dev_warn(&udev->dev,
+ "Please try an other USB controller if you wish to use UAS.\n");
+ return 0;
+ }
+
return 1;
}