diff options
author | Yang Yingliang <yangyingliang@huawei.com> | 2014-02-12 04:09:55 -0500 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2014-02-13 18:15:10 -0500 |
commit | 3410f22ea9693ed66e15a0764f20388bf39dd93d (patch) | |
tree | 28a42836a3ddbe35b9fca4ca1d97bbb9ebf91816 /net/socket.c | |
parent | 730c8c69bc8d4640336885e20e719b0842d0fcb2 (diff) |
socket: replace some printk with pr_*
Prefer pr_*(...) to printk(KERN_* ...).
Signed-off-by: Yang Yingliang <yangyingliang@huawei.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/socket.c')
-rw-r--r-- | net/socket.c | 13 |
1 files changed, 6 insertions, 7 deletions
diff --git a/net/socket.c b/net/socket.c index 879933aaed4c..840cffb7119b 100644 --- a/net/socket.c +++ b/net/socket.c | |||
@@ -593,7 +593,7 @@ void sock_release(struct socket *sock) | |||
593 | } | 593 | } |
594 | 594 | ||
595 | if (rcu_dereference_protected(sock->wq, 1)->fasync_list) | 595 | if (rcu_dereference_protected(sock->wq, 1)->fasync_list) |
596 | printk(KERN_ERR "sock_release: fasync list not empty!\n"); | 596 | pr_err("%s: fasync list not empty!\n", __func__); |
597 | 597 | ||
598 | if (test_bit(SOCK_EXTERNALLY_ALLOCATED, &sock->flags)) | 598 | if (test_bit(SOCK_EXTERNALLY_ALLOCATED, &sock->flags)) |
599 | return; | 599 | return; |
@@ -1265,8 +1265,8 @@ int __sock_create(struct net *net, int family, int type, int protocol, | |||
1265 | static int warned; | 1265 | static int warned; |
1266 | if (!warned) { | 1266 | if (!warned) { |
1267 | warned = 1; | 1267 | warned = 1; |
1268 | printk(KERN_INFO "%s uses obsolete (PF_INET,SOCK_PACKET)\n", | 1268 | pr_info("%s uses obsolete (PF_INET,SOCK_PACKET)\n", |
1269 | current->comm); | 1269 | current->comm); |
1270 | } | 1270 | } |
1271 | family = PF_PACKET; | 1271 | family = PF_PACKET; |
1272 | } | 1272 | } |
@@ -2595,8 +2595,7 @@ int sock_register(const struct net_proto_family *ops) | |||
2595 | int err; | 2595 | int err; |
2596 | 2596 | ||
2597 | if (ops->family >= NPROTO) { | 2597 | if (ops->family >= NPROTO) { |
2598 | printk(KERN_CRIT "protocol %d >= NPROTO(%d)\n", ops->family, | 2598 | pr_crit("protocol %d >= NPROTO(%d)\n", ops->family, NPROTO); |
2599 | NPROTO); | ||
2600 | return -ENOBUFS; | 2599 | return -ENOBUFS; |
2601 | } | 2600 | } |
2602 | 2601 | ||
@@ -2610,7 +2609,7 @@ int sock_register(const struct net_proto_family *ops) | |||
2610 | } | 2609 | } |
2611 | spin_unlock(&net_family_lock); | 2610 | spin_unlock(&net_family_lock); |
2612 | 2611 | ||
2613 | printk(KERN_INFO "NET: Registered protocol family %d\n", ops->family); | 2612 | pr_info("NET: Registered protocol family %d\n", ops->family); |
2614 | return err; | 2613 | return err; |
2615 | } | 2614 | } |
2616 | EXPORT_SYMBOL(sock_register); | 2615 | EXPORT_SYMBOL(sock_register); |
@@ -2638,7 +2637,7 @@ void sock_unregister(int family) | |||
2638 | 2637 | ||
2639 | synchronize_rcu(); | 2638 | synchronize_rcu(); |
2640 | 2639 | ||
2641 | printk(KERN_INFO "NET: Unregistered protocol family %d\n", family); | 2640 | pr_info("NET: Unregistered protocol family %d\n", family); |
2642 | } | 2641 | } |
2643 | EXPORT_SYMBOL(sock_unregister); | 2642 | EXPORT_SYMBOL(sock_unregister); |
2644 | 2643 | ||