* [PATCH net-next] ipv6: convert printk call to pr_err macro
@ 2015-02-27 1:14 Ian Morris
2015-02-27 2:39 ` Joe Perches
0 siblings, 1 reply; 2+ messages in thread
From: Ian Morris @ 2015-02-27 1:14 UTC (permalink / raw)
To: netdev; +Cc: Ian Morris
change a printk(KERN_ERR to a pr_err macro. No changes detected by
objdiff.
Signed-off-by: Ian Morris <ipm@chirality.org.uk>
---
net/ipv6/exthdrs_core.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/net/ipv6/exthdrs_core.c b/net/ipv6/exthdrs_core.c
index 8af3eb5..2f2945d 100644
--- a/net/ipv6/exthdrs_core.c
+++ b/net/ipv6/exthdrs_core.c
@@ -198,7 +198,7 @@ int ipv6_find_hdr(const struct sk_buff *skb, unsigned int *offset,
ip6 = skb_header_pointer(skb, *offset, sizeof(_ip6), &_ip6);
if (!ip6 || (ip6->version != 6)) {
- printk(KERN_ERR "IPv6 header not found\n");
+ pr_err("IPv6 header not found\n");
return -EBADMSG;
}
start = *offset + sizeof(struct ipv6hdr);
--
1.9.1
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH net-next] ipv6: convert printk call to pr_err macro
2015-02-27 1:14 [PATCH net-next] ipv6: convert printk call to pr_err macro Ian Morris
@ 2015-02-27 2:39 ` Joe Perches
0 siblings, 0 replies; 2+ messages in thread
From: Joe Perches @ 2015-02-27 2:39 UTC (permalink / raw)
To: Ian Morris; +Cc: netdev
On Fri, 2015-02-27 at 01:14 +0000, Ian Morris wrote:
> change a printk(KERN_ERR to a pr_err macro. No changes detected by
> objdiff.
[]
> diff --git a/net/ipv6/exthdrs_core.c b/net/ipv6/exthdrs_core.c
[]
> @@ -198,7 +198,7 @@ int ipv6_find_hdr(const struct sk_buff *skb, unsigned int *offset,
>
> ip6 = skb_header_pointer(skb, *offset, sizeof(_ip6), &_ip6);
> if (!ip6 || (ip6->version != 6)) {
> - printk(KERN_ERR "IPv6 header not found\n");
> + pr_err("IPv6 header not found\n");
Hello Ian.
I presume this message is very rare, (is it even possible?)
but I also think it'd be better to use
netdev_err(skb->dev, "IPv6 header not found\n");
so that the network device can be easily identified.
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2015-02-27 2:39 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-02-27 1:14 [PATCH net-next] ipv6: convert printk call to pr_err macro Ian Morris
2015-02-27 2:39 ` Joe Perches
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).