From 49ae25b03c8622e381e4e54d066cd4ee2dbcc3e2 Mon Sep 17 00:00:00 2001 From: Greg Kroah-Hartman Date: Wed, 19 Sep 2012 09:46:14 +0000 Subject: USB: remove dbg() usage in USB networking drivers The dbg() USB macro is so old, it predates me. The USB networking drivers are the last hold-out using this macro, and we want to get rid of it, so replace the usage of it with the proper netdev_dbg() or dev_dbg() (depending on the context) calls. Some places we end up using a local variable for the debug call, so also convert the other existing dev_* calls to use it as well, to save tiny amounts of code space. Signed-off-by: Greg Kroah-Hartman Signed-off-by: David S. Miller --- drivers/net/usb/gl620a.c | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) (limited to 'drivers/net/usb/gl620a.c') diff --git a/drivers/net/usb/gl620a.c b/drivers/net/usb/gl620a.c index db3c8021f2a3..a7e3f4e55bf3 100644 --- a/drivers/net/usb/gl620a.c +++ b/drivers/net/usb/gl620a.c @@ -91,7 +91,9 @@ static int genelink_rx_fixup(struct usbnet *dev, struct sk_buff *skb) // get the packet count of the received skb count = le32_to_cpu(header->packet_count); if (count > GL_MAX_TRANSMIT_PACKETS) { - dbg("genelink: invalid received packet count %u", count); + netdev_dbg(dev->net, + "genelink: invalid received packet count %u\n", + count); return 0; } @@ -107,7 +109,8 @@ static int genelink_rx_fixup(struct usbnet *dev, struct sk_buff *skb) // this may be a broken packet if (size > GL_MAX_PACKET_LEN) { - dbg("genelink: invalid rx length %d", size); + netdev_dbg(dev->net, "genelink: invalid rx length %d\n", + size); return 0; } @@ -133,7 +136,8 @@ static int genelink_rx_fixup(struct usbnet *dev, struct sk_buff *skb) skb_pull(skb, 4); if (skb->len > GL_MAX_PACKET_LEN) { - dbg("genelink: invalid rx length %d", skb->len); + netdev_dbg(dev->net, "genelink: invalid rx length %d\n", + skb->len); return 0; } return 1; -- cgit v1.2.3