From: Xu Wang <vulab@iscas.ac.cn>
To: rostedt@goodmis.org, mingo@redhat.com
Cc: linux-kernel@vger.kernel.org
Subject: [PATCH] tracing: Use WARN(1,...)
Date: Fri, 26 Feb 2021 09:44:26 +0000 [thread overview]
Message-ID: <20210226094426.49016-1-vulab@iscas.ac.cn> (raw)
Use WARN(1,...) rather than printk followed by WARN_ON(1).
Signed-off-by: Xu Wang <vulab@iscas.ac.cn>
---
kernel/trace/trace.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/kernel/trace/trace.c b/kernel/trace/trace.c
index 526fd5ac2ba8..a556b8c00a9f 100644
--- a/kernel/trace/trace.c
+++ b/kernel/trace/trace.c
@@ -1957,7 +1957,7 @@ static int run_tracer_selftest(struct tracer *type)
tr->current_trace = saved_tracer;
if (ret) {
/* Add the warning after printing 'FAILED' */
- WARN(1, KERN_CONT "FAILED!\n");
+ WARN(1, "FAILED!\n");
return -1;
}
/* Only reset on passing, to avoid touching corrupted buffers */
--
2.17.1
next reply other threads:[~2021-02-26 9:45 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-02-26 9:44 Xu Wang [this message]
2021-02-26 14:40 ` [PATCH] tracing: Use WARN(1,...) Steven Rostedt
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20210226094426.49016-1-vulab@iscas.ac.cn \
--to=vulab@iscas.ac.cn \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@redhat.com \
--cc=rostedt@goodmis.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).