diff options
author | Joe Perches <joe@perches.com> | 2012-05-15 10:11:53 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2012-05-16 01:01:03 -0400 |
commit | f32138319ca6541e65f95f8e17c9cc88ac1baf94 (patch) | |
tree | 20505f3d5955d89d3763a6182052a8e9b37eaf37 /net/ipv6/ah6.c | |
parent | 82251de2a2b7b84987dde104d48a765b63170149 (diff) |
net: ipv6: Standardize prefixes for message logging
Add #define pr_fmt(fmt) as appropriate.
Add "IPv6: " to appropriate files.
Convert printk(KERN_<LEVEL> to pr_<level> (but not KERN_DEBUG).
Standardize on "%s: " not "%s(): " when emitting __func__.
Use "%s: ", __func__ instead of embedding function name.
Coalesce formats, align arguments.
ADDRCONF output is now prefixed with "IPv6: "
Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ipv6/ah6.c')
-rw-r--r-- | net/ipv6/ah6.c | 16 |
1 files changed, 9 insertions, 7 deletions
diff --git a/net/ipv6/ah6.c b/net/ipv6/ah6.c index a9f4156f7c3f..9aa3d010ac5d 100644 --- a/net/ipv6/ah6.c +++ b/net/ipv6/ah6.c | |||
@@ -24,6 +24,8 @@ | |||
24 | * This file is derived from net/ipv4/ah.c. | 24 | * This file is derived from net/ipv4/ah.c. |
25 | */ | 25 | */ |
26 | 26 | ||
27 | #define pr_fmt(fmt) "IPv6: " fmt | ||
28 | |||
27 | #include <crypto/hash.h> | 29 | #include <crypto/hash.h> |
28 | #include <linux/module.h> | 30 | #include <linux/module.h> |
29 | #include <linux/slab.h> | 31 | #include <linux/slab.h> |
@@ -659,9 +661,9 @@ static int ah6_init_state(struct xfrm_state *x) | |||
659 | 661 | ||
660 | if (aalg_desc->uinfo.auth.icv_fullbits/8 != | 662 | if (aalg_desc->uinfo.auth.icv_fullbits/8 != |
661 | crypto_ahash_digestsize(ahash)) { | 663 | crypto_ahash_digestsize(ahash)) { |
662 | printk(KERN_INFO "AH: %s digestsize %u != %hu\n", | 664 | pr_info("AH: %s digestsize %u != %hu\n", |
663 | x->aalg->alg_name, crypto_ahash_digestsize(ahash), | 665 | x->aalg->alg_name, crypto_ahash_digestsize(ahash), |
664 | aalg_desc->uinfo.auth.icv_fullbits/8); | 666 | aalg_desc->uinfo.auth.icv_fullbits/8); |
665 | goto error; | 667 | goto error; |
666 | } | 668 | } |
667 | 669 | ||
@@ -727,12 +729,12 @@ static const struct inet6_protocol ah6_protocol = { | |||
727 | static int __init ah6_init(void) | 729 | static int __init ah6_init(void) |
728 | { | 730 | { |
729 | if (xfrm_register_type(&ah6_type, AF_INET6) < 0) { | 731 | if (xfrm_register_type(&ah6_type, AF_INET6) < 0) { |
730 | printk(KERN_INFO "ipv6 ah init: can't add xfrm type\n"); | 732 | pr_info("%s: can't add xfrm type\n", __func__); |
731 | return -EAGAIN; | 733 | return -EAGAIN; |
732 | } | 734 | } |
733 | 735 | ||
734 | if (inet6_add_protocol(&ah6_protocol, IPPROTO_AH) < 0) { | 736 | if (inet6_add_protocol(&ah6_protocol, IPPROTO_AH) < 0) { |
735 | printk(KERN_INFO "ipv6 ah init: can't add protocol\n"); | 737 | pr_info("%s: can't add protocol\n", __func__); |
736 | xfrm_unregister_type(&ah6_type, AF_INET6); | 738 | xfrm_unregister_type(&ah6_type, AF_INET6); |
737 | return -EAGAIN; | 739 | return -EAGAIN; |
738 | } | 740 | } |
@@ -743,10 +745,10 @@ static int __init ah6_init(void) | |||
743 | static void __exit ah6_fini(void) | 745 | static void __exit ah6_fini(void) |
744 | { | 746 | { |
745 | if (inet6_del_protocol(&ah6_protocol, IPPROTO_AH) < 0) | 747 | if (inet6_del_protocol(&ah6_protocol, IPPROTO_AH) < 0) |
746 | printk(KERN_INFO "ipv6 ah close: can't remove protocol\n"); | 748 | pr_info("%s: can't remove protocol\n", __func__); |
747 | 749 | ||
748 | if (xfrm_unregister_type(&ah6_type, AF_INET6) < 0) | 750 | if (xfrm_unregister_type(&ah6_type, AF_INET6) < 0) |
749 | printk(KERN_INFO "ipv6 ah close: can't remove xfrm type\n"); | 751 | pr_info("%s: can't remove xfrm type\n", __func__); |
750 | 752 | ||
751 | } | 753 | } |
752 | 754 | ||