uas: Add the posibilty to blacklist uas devices from using the uas driver
Once we start supporting uas hardware, and as more and more uas devices become available, we will likely start seeing broken devices. This patch prepares for the inevitable need for blacklisting those devices from using the uas driver (they will use usb-storage instead). Signed-off-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Sarah Sharp <sarah.a.sharp@linux.intel.com>
This commit is contained in:

committed by
Sarah Sharp

parent
a82b76f7fa
commit
79b4c06112
@@ -38,3 +38,14 @@ static int uas_find_uas_alt_setting(struct usb_interface *intf)
|
||||
|
||||
return -ENODEV;
|
||||
}
|
||||
|
||||
static int uas_use_uas_driver(struct usb_interface *intf,
|
||||
const struct usb_device_id *id)
|
||||
{
|
||||
unsigned long flags = id->driver_info;
|
||||
|
||||
if (flags & US_FL_IGNORE_UAS)
|
||||
return 0;
|
||||
|
||||
return uas_find_uas_alt_setting(intf) >= 0;
|
||||
}
|
||||
|
Reference in New Issue
Block a user