summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJohan Hovold <johan@kernel.org>2017-03-16 17:13:46 +0100
committerJohan Hovold <johan@kernel.org>2017-03-28 11:00:12 +0200
commit6a1eaf19f525ed9e4fa09ed1f05c6502a90b4ccb (patch)
treeec370866521f85ac6857c99df5f8a3f05ae36530
parentd760557d38ba62a8fe91dec5e32acb4fdf52d9d4 (diff)
downloadlinux-6a1eaf19f525ed9e4fa09ed1f05c6502a90b4ccb.tar.gz
linux-6a1eaf19f525ed9e4fa09ed1f05c6502a90b4ccb.tar.bz2
linux-6a1eaf19f525ed9e4fa09ed1f05c6502a90b4ccb.zip
USB: serial: mos7720: always require an interrupt endpoint
This driver have treated the interrupt endpoint as optional despite it always being present (according to the datasheet). Let's consider it mandatory instead. Signed-off-by: Johan Hovold <johan@kernel.org>
-rw-r--r--drivers/usb/serial/mos7720.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/usb/serial/mos7720.c b/drivers/usb/serial/mos7720.c
index eabea0bc1a04..b1f6b275e7c1 100644
--- a/drivers/usb/serial/mos7720.c
+++ b/drivers/usb/serial/mos7720.c
@@ -1923,8 +1923,7 @@ static int mos7720_startup(struct usb_serial *serial)
if (product == MOSCHIP_DEVICE_ID_7715) {
struct urb *urb = serial->port[0]->interrupt_in_urb;
- if (urb)
- urb->complete = mos7715_interrupt_callback;
+ urb->complete = mos7715_interrupt_callback;
#ifdef CONFIG_USB_SERIAL_MOS7715_PARPORT
ret_val = mos7715_parport_init(serial);
@@ -2025,6 +2024,7 @@ static struct usb_serial_driver moschip7720_2port_driver = {
.id_table = id_table,
.num_bulk_in = 2,
.num_bulk_out = 2,
+ .num_interrupt_in = 1,
.calc_num_ports = mos77xx_calc_num_ports,
.open = mos7720_open,
.close = mos7720_close,