From: Sergey Senozhatsky <sergey.senozhatsky.work@gmail.com>
To: Stephen Rothwell <sfr@canb.auug.org.au>,
Steven Rostedt <rostedt@goodmis.org>
Cc: linux-next@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: linux-next: Tree for Nov 2
Date: Mon, 2 Nov 2015 14:58:16 +0900 [thread overview]
Message-ID: <20151102055816.GA434@swordfish> (raw)
In-Reply-To: <20151102154017.6817486c@canb.auug.org.au>
On (11/02/15 15:40), Stephen Rothwell wrote:
> Hi all,
>
> Changes since 20151101:
>
Hi,
unregister_trace_sched_switch/register_trace_prio_sched_switch/etc.
(see the log below. 80-cols unfriendly. sorry.)
expect proto to contain 'bool preempt'
TRACE_EVENT(sched_switch,
TP_PROTO(bool preempt,
struct task_struct *prev,
struct task_struct *next),
event_filter_pid_sched_switch_probe_post() and
event_filter_pid_sched_switch_probe_pre() are missing it.
which results in:
kernel/trace/trace_events.c: In function ‘__ftrace_clear_event_pids’:
kernel/trace/trace_events.c:579:32: warning: passing argument 1 of ‘unregister_trace_sched_switch’ from incompatible pointer type [-Wincompatible-pointer-types]
unregister_trace_sched_switch(event_filter_pid_sched_switch_probe_pre, tr);
^
In file included from include/trace/events/sched.h:8:0,
from kernel/trace/trace_events.c:25:
include/linux/tracepoint.h:223:2: note: expected ‘void (*)(void *, bool, struct task_struct *, struct task_struct *) {aka void (*)(void *, _Bool, struct task_struct *, struct task_struct *)}’ but argument is of type ‘void (*)(void *, struct task_struct *, struct task_struct *)’
unregister_trace_##name(void (*probe)(data_proto), void *data) \
^
include/linux/tracepoint.h:357:3: note: in expansion of macro ‘__DECLARE_TRACE’
__DECLARE_TRACE(name, PARAMS(proto), PARAMS(args), 1, \
^
include/linux/tracepoint.h:491:2: note: in expansion of macro ‘DECLARE_TRACE’
DECLARE_TRACE(name, PARAMS(proto), PARAMS(args))
^
include/trace/events/sched.h:124:1: note: in expansion of macro ‘TRACE_EVENT’
TRACE_EVENT(sched_switch,
^
kernel/trace/trace_events.c:580:32: warning: passing argument 1 of ‘unregister_trace_sched_switch’ from incompatible pointer type [-Wincompatible-pointer-types]
unregister_trace_sched_switch(event_filter_pid_sched_switch_probe_post, tr);
^
In file included from include/trace/events/sched.h:8:0,
from kernel/trace/trace_events.c:25:
include/linux/tracepoint.h:223:2: note: expected ‘void (*)(void *, bool, struct task_struct *, struct task_struct *) {aka void (*)(void *, _Bool, struct task_struct *, struct task_struct *)}’ but argument is of type ‘void (*)(void *, struct task_struct *, struct task_struct *)’
unregister_trace_##name(void (*probe)(data_proto), void *data) \
^
include/linux/tracepoint.h:357:3: note: in expansion of macro ‘__DECLARE_TRACE’
__DECLARE_TRACE(name, PARAMS(proto), PARAMS(args), 1, \
^
include/linux/tracepoint.h:491:2: note: in expansion of macro ‘DECLARE_TRACE’
DECLARE_TRACE(name, PARAMS(proto), PARAMS(args))
^
include/trace/events/sched.h:124:1: note: in expansion of macro ‘TRACE_EVENT’
TRACE_EVENT(sched_switch,
^
kernel/trace/trace_events.c: In function ‘ftrace_event_pid_write’:
kernel/trace/trace_events.c:1723:36: warning: passing argument 1 of ‘register_trace_prio_sched_switch’ from incompatible pointer type [-Wincompatible-pointer-types]
register_trace_prio_sched_switch(event_filter_pid_sched_switch_probe_pre,
^
In file included from include/trace/events/sched.h:8:0,
from kernel/trace/trace_events.c:25:
include/linux/tracepoint.h:216:2: note: expected ‘void (*)(void *, bool, struct task_struct *, struct task_struct *) {aka void (*)(void *, _Bool, struct task_struct *, struct task_struct *)}’ but argument is of type ‘void (*)(void *, struct task_struct *, struct task_struct *)’
register_trace_prio_##name(void (*probe)(data_proto), void *data,\
^
include/linux/tracepoint.h:357:3: note: in expansion of macro ‘__DECLARE_TRACE’
__DECLARE_TRACE(name, PARAMS(proto), PARAMS(args), 1, \
^
include/linux/tracepoint.h:491:2: note: in expansion of macro ‘DECLARE_TRACE’
DECLARE_TRACE(name, PARAMS(proto), PARAMS(args))
^
include/trace/events/sched.h:124:1: note: in expansion of macro ‘TRACE_EVENT’
TRACE_EVENT(sched_switch,
^
kernel/trace/trace_events.c:1725:36: warning: passing argument 1 of ‘register_trace_prio_sched_switch’ from incompatible pointer type [-Wincompatible-pointer-types]
register_trace_prio_sched_switch(event_filter_pid_sched_switch_probe_post,
^
In file included from include/trace/events/sched.h:8:0,
from kernel/trace/trace_events.c:25:
include/linux/tracepoint.h:216:2: note: expected ‘void (*)(void *, bool, struct task_struct *, struct task_struct *) {aka void (*)(void *, _Bool, struct task_struct *, struct task_struct *)}’ but argument is of type ‘void (*)(void *, struct task_struct *, struct task_struct *)’
register_trace_prio_##name(void (*probe)(data_proto), void *data,\
^
include/linux/tracepoint.h:357:3: note: in expansion of macro ‘__DECLARE_TRACE’
__DECLARE_TRACE(name, PARAMS(proto), PARAMS(args), 1, \
^
include/linux/tracepoint.h:491:2: note: in expansion of macro ‘DECLARE_TRACE’
DECLARE_TRACE(name, PARAMS(proto), PARAMS(args))
^
include/trace/events/sched.h:124:1: note: in expansion of macro ‘TRACE_EVENT’
TRACE_EVENT(sched_switch,
something like this, I guess.
===8<===8<===8<===8<===
Add missing 'bool preempt' argument as required by
sched_switch's trace event proto:
: TRACE_EVENT(sched_switch,
:
: TP_PROTO(bool preempt,
: struct task_struct *prev,
: struct task_struct *next),
...
to event_filter_pid_sched_switch_probe_post() and
event_filter_pid_sched_switch_probe_pre() functions.
kernel/trace/trace_events.c: In function ‘__ftrace_clear_event_pids’:
kernel/trace/trace_events.c:579:32: warning: passing argument 1 of
‘unregister_trace_sched_switch’ from incompatible pointer type
[-Wincompatible-pointer-types]
unregister_trace_sched_switch(event_filter_pid_sched_switch_probe_pre, tr);
^
In file included from include/trace/events/sched.h:8:0,
from kernel/trace/trace_events.c:25:
include/linux/tracepoint.h:223:2: note: expected
‘void (*)(void *, bool, struct task_struct *, struct task_struct *)
{aka void (*)(void *, _Bool, struct task_struct *, struct task_struct *)}’
but argument is of type
‘void (*)(void *, struct task_struct *, struct task_struct *)’
unregister_trace_##name(void (*probe)(data_proto), void *data) \
^
include/linux/tracepoint.h:357:3: note: in expansion of macro ‘__DECLARE_TRACE’
__DECLARE_TRACE(name, PARAMS(proto), PARAMS(args), 1, \
^
include/linux/tracepoint.h:491:2: note: in expansion of macro ‘DECLARE_TRACE’
DECLARE_TRACE(name, PARAMS(proto), PARAMS(args))
^
include/trace/events/sched.h:124:1: note: in expansion of macro ‘TRACE_EVENT’
TRACE_EVENT(sched_switch,
^
Signed-off-by: Sergey Senozhatsky <sergey.senozhatsky@gmail.com>
---
kernel/trace/trace_events.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/kernel/trace/trace_events.c b/kernel/trace/trace_events.c
index fb0261e..0d86f0c 100644
--- a/kernel/trace/trace_events.c
+++ b/kernel/trace/trace_events.c
@@ -506,7 +506,7 @@ check_ignore_pid(struct trace_pid_list *filtered_pids, struct task_struct *task)
}
static void
-event_filter_pid_sched_switch_probe_pre(void *data,
+event_filter_pid_sched_switch_probe_pre(void *data, bool preempt,
struct task_struct *prev, struct task_struct *next)
{
struct trace_array *tr = data;
@@ -520,7 +520,7 @@ event_filter_pid_sched_switch_probe_pre(void *data,
}
static void
-event_filter_pid_sched_switch_probe_post(void *data,
+event_filter_pid_sched_switch_probe_post(void *data, bool preempt,
struct task_struct *prev, struct task_struct *next)
{
struct trace_array *tr = data;
--
2.6.2.402.g2635c2b
next prev parent reply other threads:[~2015-11-02 5:57 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-11-02 4:40 linux-next: Tree for Nov 2 Stephen Rothwell
2015-11-02 5:58 ` Sergey Senozhatsky [this message]
2015-11-02 6:30 ` Stephen Rothwell
2015-11-02 14:33 ` Steven Rostedt
-- strict thread matches above, loose matches on Subject: below --
2023-11-02 2:13 Stephen Rothwell
2022-11-02 4:31 Stephen Rothwell
2021-11-02 8:15 Stephen Rothwell
2020-11-02 5:28 Stephen Rothwell
2018-11-02 3:30 Stephen Rothwell
2018-11-02 10:44 ` Miguel Ojeda
2018-11-02 13:22 ` Stephen Rothwell
2018-11-02 13:57 ` Miguel Ojeda
2017-11-02 9:02 Stephen Rothwell
2012-11-02 6:15 Stephen Rothwell
2012-11-02 6:15 ` Stephen Rothwell
2011-11-02 5:54 Stephen Rothwell
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=20151102055816.GA434@swordfish \
--to=sergey.senozhatsky.work@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-next@vger.kernel.org \
--cc=rostedt@goodmis.org \
--cc=sfr@canb.auug.org.au \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.