Skip to content

Commit

Permalink
USB: serial: option: use mass-storage class define
Browse files Browse the repository at this point in the history
Use the USB class define rather than a magic number when refusing to
bind to mass-storage interfaces.

Reviewed-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Johan Hovold <johan@kernel.org>
  • Loading branch information
Johan Hovold committed Mar 19, 2018
1 parent a0bf2ef commit 9b284d8
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/usb/serial/option.c
Original file line number Diff line number Diff line change
Expand Up @@ -1978,7 +1978,7 @@ static int option_probe(struct usb_serial *serial,
unsigned long device_flags = id->driver_info;

/* Never bind to the CD-Rom emulation interface */
if (iface_desc->bInterfaceClass == 0x08)
if (iface_desc->bInterfaceClass == USB_CLASS_MASS_STORAGE)
return -ENODEV;

/*
Expand Down

0 comments on commit 9b284d8

Please sign in to comment.