diff options
author | Jakub Kicinski <kuba@kernel.org> | 2020-11-13 01:54:48 +0100 |
---|---|---|
committer | Jakub Kicinski <kuba@kernel.org> | 2020-11-13 01:54:48 +0100 |
commit | e1d9d7b91302593d1951fcb12feddda6fb58a3c0 (patch) | |
tree | 25662dfcceb84414d66f6c90714883b1542c0ea5 /drivers/usb/serial/cyberjack.c | |
parent | selftests: set conf.all.rp_filter=0 in bareudp.sh (diff) | |
parent | Merge tag 'net-5.10-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/net... (diff) | |
download | linux-e1d9d7b91302593d1951fcb12feddda6fb58a3c0.tar.xz linux-e1d9d7b91302593d1951fcb12feddda6fb58a3c0.zip |
Merge https://git.kernel.org/pub/scm/linux/kernel/git/netdev/net
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Diffstat (limited to 'drivers/usb/serial/cyberjack.c')
-rw-r--r-- | drivers/usb/serial/cyberjack.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/drivers/usb/serial/cyberjack.c b/drivers/usb/serial/cyberjack.c index 821970609695..2e40908963da 100644 --- a/drivers/usb/serial/cyberjack.c +++ b/drivers/usb/serial/cyberjack.c @@ -357,11 +357,12 @@ static void cyberjack_write_bulk_callback(struct urb *urb) struct device *dev = &port->dev; int status = urb->status; unsigned long flags; + bool resubmitted = false; - set_bit(0, &port->write_urbs_free); if (status) { dev_dbg(dev, "%s - nonzero write bulk status received: %d\n", __func__, status); + set_bit(0, &port->write_urbs_free); return; } @@ -394,6 +395,8 @@ static void cyberjack_write_bulk_callback(struct urb *urb) goto exit; } + resubmitted = true; + dev_dbg(dev, "%s - priv->wrsent=%d\n", __func__, priv->wrsent); dev_dbg(dev, "%s - priv->wrfilled=%d\n", __func__, priv->wrfilled); @@ -410,6 +413,8 @@ static void cyberjack_write_bulk_callback(struct urb *urb) exit: spin_unlock_irqrestore(&priv->lock, flags); + if (!resubmitted) + set_bit(0, &port->write_urbs_free); usb_serial_port_softint(port); } |