From: Johan Hovold Date: Wed, 7 Mar 2018 10:49:56 +0000 (+0100) Subject: USB: serial: option: use mass-storage class define X-Git-Tag: v4.17-rc1~126^2~7^2~1 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=9b284d8e648b9a6a297409d2adb34bcebf695818;p=thirdparty%2Flinux.git USB: serial: option: use mass-storage class define Use the USB class define rather than a magic number when refusing to bind to mass-storage interfaces. Reviewed-by: Greg Kroah-Hartman Signed-off-by: Johan Hovold --- diff --git a/drivers/usb/serial/option.c b/drivers/usb/serial/option.c index 1f5145d714d6c..c3f252283ab9d 100644 --- a/drivers/usb/serial/option.c +++ b/drivers/usb/serial/option.c @@ -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; /*