diff options
author | Joe Perches <joe@perches.com> | 2010-01-26 06:40:00 -0500 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2010-01-27 00:15:56 -0500 |
commit | 99824461ea72ca0044cc6508f02c0e1cabf37ba5 (patch) | |
tree | 8672e525869778c9d4c12fe3982306387995bf2a /net/atm/br2684.c | |
parent | b747caf365b4121903b26d1cd65454c7bc607184 (diff) |
net/atm: Convert printk to pr_<level>
Add #define pr_fmt(fmt) KBUILD_MODNAME ":%s: " fmt, __func__
Remove function names from output
Use single line pr_debug instead of broken multiple uses without newline
Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/atm/br2684.c')
-rw-r--r-- | net/atm/br2684.c | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/net/atm/br2684.c b/net/atm/br2684.c index c9230c398697..d72b1a579911 100644 --- a/net/atm/br2684.c +++ b/net/atm/br2684.c | |||
@@ -6,6 +6,8 @@ | |||
6 | * Eric Kinzie, 2006-2007, US Naval Research Laboratory | 6 | * Eric Kinzie, 2006-2007, US Naval Research Laboratory |
7 | */ | 7 | */ |
8 | 8 | ||
9 | #define pr_fmt(fmt) KBUILD_MODNAME ":%s: " fmt, __func__ | ||
10 | |||
9 | #include <linux/module.h> | 11 | #include <linux/module.h> |
10 | #include <linux/init.h> | 12 | #include <linux/init.h> |
11 | #include <linux/kernel.h> | 13 | #include <linux/kernel.h> |
@@ -148,7 +150,7 @@ static void br2684_pop(struct atm_vcc *vcc, struct sk_buff *skb) | |||
148 | struct br2684_vcc *brvcc = BR2684_VCC(vcc); | 150 | struct br2684_vcc *brvcc = BR2684_VCC(vcc); |
149 | struct net_device *net_dev = skb->dev; | 151 | struct net_device *net_dev = skb->dev; |
150 | 152 | ||
151 | pr_debug("br2684_pop(vcc %p ; net_dev %p )\n", vcc, net_dev); | 153 | pr_debug("(vcc %p ; net_dev %p )\n", vcc, net_dev); |
152 | brvcc->old_pop(vcc, skb); | 154 | brvcc->old_pop(vcc, skb); |
153 | 155 | ||
154 | if (!net_dev) | 156 | if (!net_dev) |
@@ -244,7 +246,7 @@ static netdev_tx_t br2684_start_xmit(struct sk_buff *skb, | |||
244 | struct br2684_dev *brdev = BRPRIV(dev); | 246 | struct br2684_dev *brdev = BRPRIV(dev); |
245 | struct br2684_vcc *brvcc; | 247 | struct br2684_vcc *brvcc; |
246 | 248 | ||
247 | pr_debug("br2684_start_xmit, skb_dst(skb)=%p\n", skb_dst(skb)); | 249 | pr_debug("skb_dst(skb)=%p\n", skb_dst(skb)); |
248 | read_lock(&devs_lock); | 250 | read_lock(&devs_lock); |
249 | brvcc = pick_outgoing_vcc(skb, brdev); | 251 | brvcc = pick_outgoing_vcc(skb, brdev); |
250 | if (brvcc == NULL) { | 252 | if (brvcc == NULL) { |
@@ -352,7 +354,7 @@ static void br2684_push(struct atm_vcc *atmvcc, struct sk_buff *skb) | |||
352 | struct net_device *net_dev = brvcc->device; | 354 | struct net_device *net_dev = brvcc->device; |
353 | struct br2684_dev *brdev = BRPRIV(net_dev); | 355 | struct br2684_dev *brdev = BRPRIV(net_dev); |
354 | 356 | ||
355 | pr_debug("br2684_push\n"); | 357 | pr_debug("\n"); |
356 | 358 | ||
357 | if (unlikely(skb == NULL)) { | 359 | if (unlikely(skb == NULL)) { |
358 | /* skb==NULL means VCC is being destroyed */ | 360 | /* skb==NULL means VCC is being destroyed */ |
@@ -479,8 +481,7 @@ static int br2684_regvcc(struct atm_vcc *atmvcc, void __user * arg) | |||
479 | write_lock_irq(&devs_lock); | 481 | write_lock_irq(&devs_lock); |
480 | net_dev = br2684_find_dev(&be.ifspec); | 482 | net_dev = br2684_find_dev(&be.ifspec); |
481 | if (net_dev == NULL) { | 483 | if (net_dev == NULL) { |
482 | printk(KERN_ERR | 484 | pr_err("tried to attach to non-existant device\n"); |
483 | "br2684: tried to attach to non-existant device\n"); | ||
484 | err = -ENXIO; | 485 | err = -ENXIO; |
485 | goto error; | 486 | goto error; |
486 | } | 487 | } |
@@ -503,8 +504,7 @@ static int br2684_regvcc(struct atm_vcc *atmvcc, void __user * arg) | |||
503 | err = -EINVAL; | 504 | err = -EINVAL; |
504 | goto error; | 505 | goto error; |
505 | } | 506 | } |
506 | pr_debug("br2684_regvcc vcc=%p, encaps=%d, brvcc=%p\n", atmvcc, | 507 | pr_debug("vcc=%p, encaps=%d, brvcc=%p\n", atmvcc, be.encaps, brvcc); |
507 | be.encaps, brvcc); | ||
508 | if (list_empty(&brdev->brvccs) && !brdev->mac_was_set) { | 508 | if (list_empty(&brdev->brvccs) && !brdev->mac_was_set) { |
509 | unsigned char *esi = atmvcc->dev->esi; | 509 | unsigned char *esi = atmvcc->dev->esi; |
510 | if (esi[0] | esi[1] | esi[2] | esi[3] | esi[4] | esi[5]) | 510 | if (esi[0] | esi[1] | esi[2] | esi[3] | esi[4] | esi[5]) |
@@ -595,7 +595,7 @@ static int br2684_create(void __user * arg) | |||
595 | struct atm_newif_br2684 ni; | 595 | struct atm_newif_br2684 ni; |
596 | enum br2684_payload payload; | 596 | enum br2684_payload payload; |
597 | 597 | ||
598 | pr_debug("br2684_create\n"); | 598 | pr_debug("\n"); |
599 | 599 | ||
600 | if (copy_from_user(&ni, arg, sizeof ni)) { | 600 | if (copy_from_user(&ni, arg, sizeof ni)) { |
601 | return -EFAULT; | 601 | return -EFAULT; |
@@ -624,7 +624,7 @@ static int br2684_create(void __user * arg) | |||
624 | /* open, stop, do_ioctl ? */ | 624 | /* open, stop, do_ioctl ? */ |
625 | err = register_netdev(netdev); | 625 | err = register_netdev(netdev); |
626 | if (err < 0) { | 626 | if (err < 0) { |
627 | printk(KERN_ERR "br2684_create: register_netdev failed\n"); | 627 | pr_err("register_netdev failed\n"); |
628 | free_netdev(netdev); | 628 | free_netdev(netdev); |
629 | return err; | 629 | return err; |
630 | } | 630 | } |