diff options
author | Huang Shijie <shijie.huang@arm.com> | 2016-08-03 16:46:06 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2016-08-04 08:50:07 -0400 |
commit | 468b88956c3317de6cf2317374faf671f950724b (patch) | |
tree | 1265808a8a80f55192abc7891a43dc2140df8877 | |
parent | e708c1488bca54b901c4c3e73462ab2decdb8209 (diff) |
samples/jprobe: convert the printk to pr_info/pr_err
We prefer to use the pr_* to print out the log now, this patch converts
the printk to pr_info. In the error path, use the pr_err to replace the
printk.
Link: http://lkml.kernel.org/r/1464143083-3877-2-git-send-email-shijie.huang@arm.com
Signed-off-by: Huang Shijie <shijie.huang@arm.com>
Cc: Petr Mladek <pmladek@suse.com>
Cc: Steve Capper <steve.capper@arm.com>
Cc: Ananth N Mavinakayanahalli <ananth@linux.vnet.ibm.com>
Cc: Anil S Keshavamurthy <anil.s.keshavamurthy@intel.com>
Cc: Masami Hiramatsu <mhiramat@kernel.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
-rw-r--r-- | samples/kprobes/jprobe_example.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/samples/kprobes/jprobe_example.c b/samples/kprobes/jprobe_example.c index c3108bb15789..e3c0a40909f7 100644 --- a/samples/kprobes/jprobe_example.c +++ b/samples/kprobes/jprobe_example.c | |||
@@ -48,10 +48,10 @@ static int __init jprobe_init(void) | |||
48 | 48 | ||
49 | ret = register_jprobe(&my_jprobe); | 49 | ret = register_jprobe(&my_jprobe); |
50 | if (ret < 0) { | 50 | if (ret < 0) { |
51 | printk(KERN_INFO "register_jprobe failed, returned %d\n", ret); | 51 | pr_err("register_jprobe failed, returned %d\n", ret); |
52 | return -1; | 52 | return -1; |
53 | } | 53 | } |
54 | printk(KERN_INFO "Planted jprobe at %p, handler addr %p\n", | 54 | pr_info("Planted jprobe at %p, handler addr %p\n", |
55 | my_jprobe.kp.addr, my_jprobe.entry); | 55 | my_jprobe.kp.addr, my_jprobe.entry); |
56 | return 0; | 56 | return 0; |
57 | } | 57 | } |
@@ -59,7 +59,7 @@ static int __init jprobe_init(void) | |||
59 | static void __exit jprobe_exit(void) | 59 | static void __exit jprobe_exit(void) |
60 | { | 60 | { |
61 | unregister_jprobe(&my_jprobe); | 61 | unregister_jprobe(&my_jprobe); |
62 | printk(KERN_INFO "jprobe at %p unregistered\n", my_jprobe.kp.addr); | 62 | pr_info("jprobe at %p unregistered\n", my_jprobe.kp.addr); |
63 | } | 63 | } |
64 | 64 | ||
65 | module_init(jprobe_init) | 65 | module_init(jprobe_init) |