From: "Paul E. McKenney" <paulmck@linux.vnet.ibm.com>
To: linux-kernel@vger.kernel.org
Cc: mingo@kernel.org, laijs@cn.fujitsu.com, dipankar@in.ibm.com,
akpm@linux-foundation.org, mathieu.desnoyers@efficios.com,
josh@joshtriplett.org, niv@us.ibm.com, tglx@linutronix.de,
peterz@infradead.org, rostedt@goodmis.org, dhowells@redhat.com,
edumazet@google.com, darren@dvhart.com, fweisbec@gmail.com,
sbw@mit.edu, "Paul E. McKenney" <paulmck@linux.vnet.ibm.com>
Subject: [PATCH tip/core/rcu 09/10] rcu: Avoid sparse warnings in rcu_nocb_wake trace event
Date: Tue, 24 Sep 2013 18:42:38 -0700 [thread overview]
Message-ID: <1380073359-31959-9-git-send-email-paulmck@linux.vnet.ibm.com> (raw)
In-Reply-To: <1380073359-31959-1-git-send-email-paulmck@linux.vnet.ibm.com>
From: "Paul E. McKenney" <paulmck@linux.vnet.ibm.com>
The event-tracing macros do not like bool tracing arguments, so this
commit makes them be of type char. This change has the knock-on effect
of making it illegal to pass a pointer into one of these arguments, so
also change rcutiny's first call to trace_rcu_batch_end() to convert
from pointer to boolean, prefixing with "!!".
Reported-by: kbuild test robot <fengguang.wu@intel.com>
Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com>
---
include/trace/events/rcu.h | 10 +++++-----
kernel/rcutiny.c | 2 +-
2 files changed, 6 insertions(+), 6 deletions(-)
diff --git a/include/trace/events/rcu.h b/include/trace/events/rcu.h
index a087d82..aca3822 100644
--- a/include/trace/events/rcu.h
+++ b/include/trace/events/rcu.h
@@ -591,17 +591,17 @@ TRACE_EVENT(rcu_invoke_kfree_callback,
TRACE_EVENT(rcu_batch_end,
TP_PROTO(const char *rcuname, int callbacks_invoked,
- bool cb, bool nr, bool iit, bool risk),
+ char cb, char nr, char iit, char risk),
TP_ARGS(rcuname, callbacks_invoked, cb, nr, iit, risk),
TP_STRUCT__entry(
__field(const char *, rcuname)
__field(int, callbacks_invoked)
- __field(bool, cb)
- __field(bool, nr)
- __field(bool, iit)
- __field(bool, risk)
+ __field(char, cb)
+ __field(char, nr)
+ __field(char, iit)
+ __field(char, risk)
),
TP_fast_assign(
diff --git a/kernel/rcutiny.c b/kernel/rcutiny.c
index 9ed6075..80b6e27 100644
--- a/kernel/rcutiny.c
+++ b/kernel/rcutiny.c
@@ -273,7 +273,7 @@ static void __rcu_process_callbacks(struct rcu_ctrlblk *rcp)
if (&rcp->rcucblist == rcp->donetail) {
RCU_TRACE(trace_rcu_batch_start(rcp->name, 0, 0, -1));
RCU_TRACE(trace_rcu_batch_end(rcp->name, 0,
- ACCESS_ONCE(rcp->rcucblist),
+ !!ACCESS_ONCE(rcp->rcucblist),
need_resched(),
is_idle_task(current),
false));
--
1.8.1.5
next prev parent reply other threads:[~2013-09-25 1:44 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-09-25 1:42 [PATCH tip/core/rcu 0/10] Grace-period-related changes for 3.13 Paul E. McKenney
2013-09-25 1:42 ` [PATCH tip/core/rcu 01/10] rcu: Improve grace-period start logic Paul E. McKenney
2013-09-25 1:42 ` [PATCH tip/core/rcu 02/10] rcu: Prevent spurious-wakeup DoS attack on rcu_gp_kthread() Paul E. McKenney
2013-09-25 1:42 ` [PATCH tip/core/rcu 03/10] rcu: Flag lockless access to ->gp_flags with ACCESS_ONCE() Paul E. McKenney
2013-09-25 1:42 ` [PATCH tip/core/rcu 04/10] rcu: Add tracing to rcu_gp_kthread() Paul E. McKenney
2013-09-25 1:42 ` [PATCH tip/core/rcu 05/10] rcu: Add tracing of normal (non-NOCB) grace-period requests Paul E. McKenney
2013-09-25 1:42 ` [PATCH tip/core/rcu 06/10] rcu: Add tracing for rcuo no-CBs CPU wakeup handshake Paul E. McKenney
2013-09-25 1:42 ` [PATCH tip/core/rcu 07/10] rcu: Distinguish between NOCB and non-NOCB rcu_callback trace events Paul E. McKenney
2013-09-25 1:42 ` [PATCH tip/core/rcu 08/10] rcu: Track rcu_nocb_kthread()'s sleeping and awakening Paul E. McKenney
2013-09-25 1:42 ` Paul E. McKenney [this message]
2013-09-25 1:42 ` [PATCH tip/core/rcu 10/10] sched, rcu: Make RCU use resched_cpu() Paul E. McKenney
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=1380073359-31959-9-git-send-email-paulmck@linux.vnet.ibm.com \
--to=paulmck@linux.vnet.ibm.com \
--cc=akpm@linux-foundation.org \
--cc=darren@dvhart.com \
--cc=dhowells@redhat.com \
--cc=dipankar@in.ibm.com \
--cc=edumazet@google.com \
--cc=fweisbec@gmail.com \
--cc=josh@joshtriplett.org \
--cc=laijs@cn.fujitsu.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mathieu.desnoyers@efficios.com \
--cc=mingo@kernel.org \
--cc=niv@us.ibm.com \
--cc=peterz@infradead.org \
--cc=rostedt@goodmis.org \
--cc=sbw@mit.edu \
--cc=tglx@linutronix.de \
/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
all inboxes | Powered by JetHome®