Commit efbe27b3 authored by Oliver Neukum's avatar Oliver Neukum Committed by Greg Kroah-Hartman

cdc-acm: cleaning up debug in data submission path

Further cleanup making the debug messages more precise, useful
and removing mere trace points.
Signed-off-by: default avatarOliver Neukum <oneukum@suse.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 46e75075
...@@ -415,8 +415,9 @@ static void acm_read_bulk_callback(struct urb *urb) ...@@ -415,8 +415,9 @@ static void acm_read_bulk_callback(struct urb *urb)
unsigned long flags; unsigned long flags;
int status = urb->status; int status = urb->status;
dev_vdbg(&acm->data->dev, "%s - urb %d, len %d\n", __func__, dev_vdbg(&acm->data->dev, "got urb %d, len %d, status %d\n",
rb->index, urb->actual_length); rb->index, urb->actual_length,
status);
if (!acm->dev) { if (!acm->dev) {
set_bit(rb->index, &acm->read_urbs_free); set_bit(rb->index, &acm->read_urbs_free);
...@@ -426,8 +427,6 @@ static void acm_read_bulk_callback(struct urb *urb) ...@@ -426,8 +427,6 @@ static void acm_read_bulk_callback(struct urb *urb)
if (status) { if (status) {
set_bit(rb->index, &acm->read_urbs_free); set_bit(rb->index, &acm->read_urbs_free);
dev_dbg(&acm->data->dev, "%s - non-zero urb status: %d\n",
__func__, status);
if ((status != -ENOENT) || (urb->actual_length == 0)) if ((status != -ENOENT) || (urb->actual_length == 0))
return; return;
} }
...@@ -462,8 +461,7 @@ static void acm_write_bulk(struct urb *urb) ...@@ -462,8 +461,7 @@ static void acm_write_bulk(struct urb *urb)
int status = urb->status; int status = urb->status;
if (status || (urb->actual_length != urb->transfer_buffer_length)) if (status || (urb->actual_length != urb->transfer_buffer_length))
dev_vdbg(&acm->data->dev, "%s - len %d/%d, status %d\n", dev_vdbg(&acm->data->dev, "wrote len %d/%d, status %d\n",
__func__,
urb->actual_length, urb->actual_length,
urb->transfer_buffer_length, urb->transfer_buffer_length,
status); status);
...@@ -478,8 +476,6 @@ static void acm_softint(struct work_struct *work) ...@@ -478,8 +476,6 @@ static void acm_softint(struct work_struct *work)
{ {
struct acm *acm = container_of(work, struct acm, work); struct acm *acm = container_of(work, struct acm, work);
dev_vdbg(&acm->data->dev, "%s\n", __func__);
tty_port_tty_wakeup(&acm->port); tty_port_tty_wakeup(&acm->port);
} }
...@@ -674,7 +670,7 @@ static int acm_tty_write(struct tty_struct *tty, ...@@ -674,7 +670,7 @@ static int acm_tty_write(struct tty_struct *tty,
if (!count) if (!count)
return 0; return 0;
dev_vdbg(&acm->data->dev, "%s - count %d\n", __func__, count); dev_vdbg(&acm->data->dev, "%d bytes from tty layer\n", count);
spin_lock_irqsave(&acm->write_lock, flags); spin_lock_irqsave(&acm->write_lock, flags);
wbn = acm_wb_alloc(acm); wbn = acm_wb_alloc(acm);
...@@ -691,7 +687,7 @@ static int acm_tty_write(struct tty_struct *tty, ...@@ -691,7 +687,7 @@ static int acm_tty_write(struct tty_struct *tty,
} }
count = (count > acm->writesize) ? acm->writesize : count; count = (count > acm->writesize) ? acm->writesize : count;
dev_vdbg(&acm->data->dev, "%s - write %d\n", __func__, count); dev_vdbg(&acm->data->dev, "writing %d bytes\n", count);
memcpy(wb->buf, buf, count); memcpy(wb->buf, buf, count);
wb->len = count; wb->len = count;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment