From: Stephen Rothwell <sfr@canb.auug.org.au>
To: Steven Rostedt <rostedt@goodmis.org>
Cc: Chuck Lever <chuck.lever@oracle.com>,
Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
Linux Next Mailing List <linux-next@vger.kernel.org>
Subject: Re: linux-next: manual merge of the ftrace tree with the nfsd tree
Date: Wed, 16 Mar 2022 14:09:24 +1100 [thread overview]
Message-ID: <20220316140924.0f4252b3@canb.auug.org.au> (raw)
In-Reply-To: <20220315145828.413e9301@canb.auug.org.au>
[-- Attachment #1: Type: text/plain, Size: 3922 bytes --]
Hi Stephen,
On Tue, 15 Mar 2022 14:58:28 +1100 Stephen Rothwell <sfr@canb.auug.org.au> wrote:
>
> However, my x86_64 allmodconfig build then failed like this:
>
> In file included from include/trace/define_custom_trace.h:55,
> from samples/trace_events/trace_custom_sched.h:95,
> from samples/trace_events/trace_custom_sched.c:24:
> samples/trace_events/./trace_custom_sched.h: In function 'ftrace_test_custom_probe_sched_switch':
> include/trace/trace_custom_events.h:178:42: error: passing argument 1 of 'check_trace_callback_type_sched_switch' from incompatible pointer type [-Werror=incompatible-pointer-types]
> 178 | check_trace_callback_type_##call(trace_custom_event_raw_event_##template); \
> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> | |
> | void (*)(void *, bool, struct task_struct *, struct task_struct *) {aka void (*)(void *, _Bool, struct task_struct *, struct task_struct *)}
> include/trace/trace_custom_events.h:34:9: note: in expansion of macro 'DEFINE_CUSTOM_EVENT'
> 34 | DEFINE_CUSTOM_EVENT(name, name, PARAMS(proto), PARAMS(args));
> | ^~~~~~~~~~~~~~~~~~~
> samples/trace_events/./trace_custom_sched.h:21:1: note: in expansion of macro 'TRACE_CUSTOM_EVENT'
> 21 | TRACE_CUSTOM_EVENT(sched_switch,
> | ^~~~~~~~~~~~~~~~~~
> In file included from include/linux/trace_events.h:11,
> from samples/trace_events/trace_custom_sched.c:10:
> include/linux/tracepoint.h:279:49: note: expected 'void (*)(void *, bool, unsigned int, struct task_struct *, struct task_struct *)' {aka 'void (*)(void *, _Bool, unsigned int, struct task_struct *, struct task_struct *)'} but argument is of type 'void (*)(void *, bool, struct task_struct *, struct task_struct *)' {aka 'void (*)(void *, _Bool, struct task_struct *, struct task_struct *)'}
> 279 | check_trace_callback_type_##name(void (*cb)(data_proto)) \
> | ~~~~~~~^~~~~~~~~~~~~~~
> include/linux/tracepoint.h:419:9: note: in expansion of macro '__DECLARE_TRACE'
> 419 | __DECLARE_TRACE(name, PARAMS(proto), PARAMS(args), \
> | ^~~~~~~~~~~~~~~
> include/linux/tracepoint.h:553:9: note: in expansion of macro 'DECLARE_TRACE'
> 553 | DECLARE_TRACE(name, PARAMS(proto), PARAMS(args))
> | ^~~~~~~~~~~~~
> include/trace/events/sched.h:222:1: note: in expansion of macro 'TRACE_EVENT'
> 222 | TRACE_EVENT(sched_switch,
> | ^~~~~~~~~~~
>
> So I gave up and uses the ftrace tree from next-20220310 for today.
>
> I am going to need some help with this mess, please.
Thanks for the example merge. The extra merge resolution patch ended
up this:
From: Stephen Rothwell <sfr@canb.auug.org.au>
Date: Wed, 16 Mar 2022 14:01:59 +1100
Subject: [PATCH] fixup for "sched/tracing: Don't re-read p->state when emitting sched_switch event"
Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
---
samples/trace_events/trace_custom_sched.h | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/samples/trace_events/trace_custom_sched.h b/samples/trace_events/trace_custom_sched.h
index a3d14de6a2e5..9fdd8e7c2a45 100644
--- a/samples/trace_events/trace_custom_sched.h
+++ b/samples/trace_events/trace_custom_sched.h
@@ -25,10 +25,11 @@ TRACE_CUSTOM_EVENT(sched_switch,
* that the custom event is using.
*/
TP_PROTO(bool preempt,
+ unsigned int prev_state,
struct task_struct *prev,
struct task_struct *next),
- TP_ARGS(preempt, prev, next),
+ TP_ARGS(preempt, prev_state, prev, next),
/*
* The next fields are where the customization happens.
--
2.34.1
--
Cheers,
Stephen Rothwell
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 488 bytes --]
prev parent reply other threads:[~2022-03-16 3:09 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-03-15 3:58 linux-next: manual merge of the ftrace tree with the nfsd tree Stephen Rothwell
2022-03-15 13:33 ` Chuck Lever III
2022-03-15 14:15 ` Steven Rostedt
2022-03-15 17:31 ` Steven Rostedt
2022-03-15 17:33 ` Chuck Lever III
2022-03-16 3:09 ` Stephen Rothwell [this message]
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=20220316140924.0f4252b3@canb.auug.org.au \
--to=sfr@canb.auug.org.au \
--cc=chuck.lever@oracle.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-next@vger.kernel.org \
--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