Skip to content

Commit

Permalink
USB: generic.c: remove dbg() tracing calls
Browse files Browse the repository at this point in the history
dbg() was used a lot a long time ago to trace code flow.  Now that we have
ftrace, this isn't needed at all, so remove these calls.

Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
  • Loading branch information
Greg Kroah-Hartman committed May 3, 2012
1 parent c0a56a2 commit de5789e
Showing 1 changed file with 0 additions and 22 deletions.
22 changes: 0 additions & 22 deletions drivers/usb/serial/generic.c
Original file line number Diff line number Diff line change
Expand Up @@ -117,8 +117,6 @@ int usb_serial_generic_open(struct tty_struct *tty, struct usb_serial_port *port
int result = 0;
unsigned long flags;

dbg("%s - port %d", __func__, port->number);

/* clear the throttle flags */
spin_lock_irqsave(&port->lock, flags);
port->throttled = 0;
Expand All @@ -139,8 +137,6 @@ static void generic_cleanup(struct usb_serial_port *port)
unsigned long flags;
int i;

dbg("%s - port %d", __func__, port->number);

if (serial->dev) {
/* shutdown any bulk transfers that might be going on */
if (port->bulk_out_size) {
Expand All @@ -160,7 +156,6 @@ static void generic_cleanup(struct usb_serial_port *port)

void usb_serial_generic_close(struct usb_serial_port *port)
{
dbg("%s - port %d", __func__, port->number);
generic_cleanup(port);
}
EXPORT_SYMBOL_GPL(usb_serial_generic_close);
Expand Down Expand Up @@ -248,8 +243,6 @@ int usb_serial_generic_write(struct tty_struct *tty,
{
int result;

dbg("%s - port %d", __func__, port->number);

/* only do something if we have a bulk out endpoint */
if (!port->bulk_out_size)
return -ENODEV;
Expand All @@ -272,8 +265,6 @@ int usb_serial_generic_write_room(struct tty_struct *tty)
unsigned long flags;
int room;

dbg("%s - port %d", __func__, port->number);

if (!port->bulk_out_size)
return 0;

Expand All @@ -291,8 +282,6 @@ int usb_serial_generic_chars_in_buffer(struct tty_struct *tty)
unsigned long flags;
int chars;

dbg("%s - port %d", __func__, port->number);

if (!port->bulk_out_size)
return 0;

Expand Down Expand Up @@ -334,8 +323,6 @@ int usb_serial_generic_submit_read_urbs(struct usb_serial_port *port,
int res;
int i;

dbg("%s - port %d", __func__, port->number);

for (i = 0; i < ARRAY_SIZE(port->read_urbs); ++i) {
res = usb_serial_generic_submit_read_urb(port, i, mem_flags);
if (res)
Expand Down Expand Up @@ -423,8 +410,6 @@ void usb_serial_generic_write_bulk_callback(struct urb *urb)
int status = urb->status;
int i;

dbg("%s - port %d", __func__, port->number);

for (i = 0; i < ARRAY_SIZE(port->write_urbs); ++i)
if (port->write_urbs[i] == urb)
break;
Expand Down Expand Up @@ -453,8 +438,6 @@ void usb_serial_generic_throttle(struct tty_struct *tty)
struct usb_serial_port *port = tty->driver_data;
unsigned long flags;

dbg("%s - port %d", __func__, port->number);

/* Set the throttle request flag. It will be picked up
* by usb_serial_generic_read_bulk_callback(). */
spin_lock_irqsave(&port->lock, flags);
Expand All @@ -468,8 +451,6 @@ void usb_serial_generic_unthrottle(struct tty_struct *tty)
struct usb_serial_port *port = tty->driver_data;
int was_throttled;

dbg("%s - port %d", __func__, port->number);

/* Clear the throttle flags */
spin_lock_irq(&port->lock);
was_throttled = port->throttled;
Expand Down Expand Up @@ -565,8 +546,6 @@ void usb_serial_generic_disconnect(struct usb_serial *serial)
{
int i;

dbg("%s", __func__);

/* stop reads and writes on all ports */
for (i = 0; i < serial->num_ports; ++i)
generic_cleanup(serial->port[i]);
Expand All @@ -575,5 +554,4 @@ EXPORT_SYMBOL_GPL(usb_serial_generic_disconnect);

void usb_serial_generic_release(struct usb_serial *serial)
{
dbg("%s", __func__);
}

0 comments on commit de5789e

Please sign in to comment.