From: Jaegeuk Kim <jaegeuk@kernel.org>
To: Kajetan Puchalski <kajetan.puchalski@arm.com>
Cc: "open list:TRACING" <linux-kernel@vger.kernel.org>,
Steven Rostedt <rostedt@goodmis.org>,
"open list:F2FS FILE SYSTEM"
<linux-f2fs-devel@lists.sourceforge.net>,
jstultz@google.com, Masami Hiramatsu <mhiramat@kernel.org>,
qyousef@google.com, Douglas RAILLARD <douglas.raillard@arm.com>,
lukasz.luba@arm.com,
"open list:TRACING" <linux-trace-kernel@vger.kernel.org>
Subject: Re: [f2fs-dev] [PATCH] f2fs: Fix f2fs_truncate_partial_nodes ftrace event
Date: Mon, 14 Aug 2023 13:37:36 -0700 [thread overview]
Message-ID: <ZNqQkDm0YschY+WI@google.com> (raw)
In-Reply-To: <ZNo8hoR2V3Zo14+l@e126311.manchester.arm.com>
On 08/14, Kajetan Puchalski wrote:
> On Mon, Aug 14, 2023 at 02:32:53PM +0100, Kajetan Puchalski wrote:
> > On Mon, Mar 06, 2023 at 12:25:49PM +0000, Douglas RAILLARD wrote:
> > > From: Douglas Raillard <douglas.raillard@arm.com>
> > >
> > > Fix the nid_t field so that its size is correctly reported in the text
> > > format embedded in trace.dat files. As it stands, it is reported as
> > > being of size 4:
> > >
> > > field:nid_t nid[3]; offset:24; size:4; signed:0;
> > >
> > > Instead of 12:
> > >
> > > field:nid_t nid[3]; offset:24; size:12; signed:0;
> > >
> > > This also fixes the reported offset of subsequent fields so that they
> > > match with the actual struct layout.
> > >
> > >
> > > Signed-off-by: Douglas Raillard <douglas.raillard@arm.com>
> > > ---
> > > include/trace/events/f2fs.h | 2 +-
> > > 1 file changed, 1 insertion(+), 1 deletion(-)
> > >
> > > diff --git a/include/trace/events/f2fs.h b/include/trace/events/f2fs.h
> > > index 31d994e6b4ca..8d053838d6cf 100644
> > > --- a/include/trace/events/f2fs.h
> > > +++ b/include/trace/events/f2fs.h
> > > @@ -512,7 +512,7 @@ TRACE_EVENT(f2fs_truncate_partial_nodes,
> > > TP_STRUCT__entry(
> > > __field(dev_t, dev)
> > > __field(ino_t, ino)
> > > - __field(nid_t, nid[3])
> > > + __array(nid_t, nid, 3)
> > > __field(int, depth)
> > > __field(int, err)
> > > ),
> > > --
> > > 2.25.1
> >
> > Hi,
> >
> > Just wanted to flag that I noticed this breaks Perfetto tracing on
> > Android, at least as of Android 13. I'm not sure if it's been fixed in newer
> > versions. Looks like the version of Perfetto in Android 13 is expecting
> > the previous (ie broken) field format to be there and its entire ftrace
> > collector fails as a result:
> >
> > E/perfetto( 3532): ranslation_table.cc:133 Failed to infer ftrace field type for "f2fs_truncate_partial_nodes.nid" (type:"nid_t nid[3]" size:12 signed:0) (errno: 2, No such file or directory)
> > I/perfetto( 3640): probes.cc:65 Hard resetting ftrace state.
> >
> > For my own purposes I just reverted these two:
> > * 0b04d4c0542e8573a837b1d81b94209e48723b25 (f2fs: Fix f2fs_truncate_partial_nodes ftrace event)
> > * f82e7ca019dfad3b006fd3b772f7ac569672db55 (tracing: Error if a trace event has an array for a __field()
> >
> > and now it works fine so not the biggest deal but this should probably
> > be addressed, I imagine more likely on the Perfetto side.
>
> Added context here, it is just caused by the parser implementation in Perfetto
> being pretty lacking:
>
> https://github.com/google/perfetto/blob/c36c70c1d4a72eafdd257f7a63e55f49fbc3df3d/src/traced/probes/ftrace/proto_translation_table.cc#L255
Hi, I believe this was fixed by
https://android-review.git.corp.google.com/c/platform/external/perfetto/+/2587146
_______________________________________________
Linux-f2fs-devel mailing list
Linux-f2fs-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/linux-f2fs-devel
WARNING: multiple messages have this Message-ID (diff)
From: Jaegeuk Kim <jaegeuk@kernel.org>
To: Kajetan Puchalski <kajetan.puchalski@arm.com>
Cc: Douglas RAILLARD <douglas.raillard@arm.com>,
Chao Yu <chao@kernel.org>, Steven Rostedt <rostedt@goodmis.org>,
Masami Hiramatsu <mhiramat@kernel.org>,
"open list:F2FS FILE SYSTEM"
<linux-f2fs-devel@lists.sourceforge.net>,
"open list:TRACING" <linux-kernel@vger.kernel.org>,
"open list:TRACING" <linux-trace-kernel@vger.kernel.org>,
jstultz@google.com, qyousef@google.com, lukasz.luba@arm.com
Subject: Re: [PATCH] f2fs: Fix f2fs_truncate_partial_nodes ftrace event
Date: Mon, 14 Aug 2023 13:37:36 -0700 [thread overview]
Message-ID: <ZNqQkDm0YschY+WI@google.com> (raw)
In-Reply-To: <ZNo8hoR2V3Zo14+l@e126311.manchester.arm.com>
On 08/14, Kajetan Puchalski wrote:
> On Mon, Aug 14, 2023 at 02:32:53PM +0100, Kajetan Puchalski wrote:
> > On Mon, Mar 06, 2023 at 12:25:49PM +0000, Douglas RAILLARD wrote:
> > > From: Douglas Raillard <douglas.raillard@arm.com>
> > >
> > > Fix the nid_t field so that its size is correctly reported in the text
> > > format embedded in trace.dat files. As it stands, it is reported as
> > > being of size 4:
> > >
> > > field:nid_t nid[3]; offset:24; size:4; signed:0;
> > >
> > > Instead of 12:
> > >
> > > field:nid_t nid[3]; offset:24; size:12; signed:0;
> > >
> > > This also fixes the reported offset of subsequent fields so that they
> > > match with the actual struct layout.
> > >
> > >
> > > Signed-off-by: Douglas Raillard <douglas.raillard@arm.com>
> > > ---
> > > include/trace/events/f2fs.h | 2 +-
> > > 1 file changed, 1 insertion(+), 1 deletion(-)
> > >
> > > diff --git a/include/trace/events/f2fs.h b/include/trace/events/f2fs.h
> > > index 31d994e6b4ca..8d053838d6cf 100644
> > > --- a/include/trace/events/f2fs.h
> > > +++ b/include/trace/events/f2fs.h
> > > @@ -512,7 +512,7 @@ TRACE_EVENT(f2fs_truncate_partial_nodes,
> > > TP_STRUCT__entry(
> > > __field(dev_t, dev)
> > > __field(ino_t, ino)
> > > - __field(nid_t, nid[3])
> > > + __array(nid_t, nid, 3)
> > > __field(int, depth)
> > > __field(int, err)
> > > ),
> > > --
> > > 2.25.1
> >
> > Hi,
> >
> > Just wanted to flag that I noticed this breaks Perfetto tracing on
> > Android, at least as of Android 13. I'm not sure if it's been fixed in newer
> > versions. Looks like the version of Perfetto in Android 13 is expecting
> > the previous (ie broken) field format to be there and its entire ftrace
> > collector fails as a result:
> >
> > E/perfetto( 3532): ranslation_table.cc:133 Failed to infer ftrace field type for "f2fs_truncate_partial_nodes.nid" (type:"nid_t nid[3]" size:12 signed:0) (errno: 2, No such file or directory)
> > I/perfetto( 3640): probes.cc:65 Hard resetting ftrace state.
> >
> > For my own purposes I just reverted these two:
> > * 0b04d4c0542e8573a837b1d81b94209e48723b25 (f2fs: Fix f2fs_truncate_partial_nodes ftrace event)
> > * f82e7ca019dfad3b006fd3b772f7ac569672db55 (tracing: Error if a trace event has an array for a __field()
> >
> > and now it works fine so not the biggest deal but this should probably
> > be addressed, I imagine more likely on the Perfetto side.
>
> Added context here, it is just caused by the parser implementation in Perfetto
> being pretty lacking:
>
> https://github.com/google/perfetto/blob/c36c70c1d4a72eafdd257f7a63e55f49fbc3df3d/src/traced/probes/ftrace/proto_translation_table.cc#L255
Hi, I believe this was fixed by
https://android-review.git.corp.google.com/c/platform/external/perfetto/+/2587146
next prev parent reply other threads:[~2023-08-14 20:37 UTC|newest]
Thread overview: 26+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-03-06 12:25 [f2fs-dev] [PATCH] f2fs: Fix f2fs_truncate_partial_nodes ftrace event Douglas RAILLARD
2023-03-06 12:25 ` Douglas RAILLARD
2023-03-06 12:51 ` [f2fs-dev] " Mukesh Ojha
2023-03-06 12:51 ` Mukesh Ojha
2023-03-06 16:15 ` [f2fs-dev] " Steven Rostedt
2023-03-06 16:15 ` Steven Rostedt
2023-03-06 17:25 ` [f2fs-dev] " Steven Rostedt
2023-03-06 17:25 ` Steven Rostedt
2023-03-07 6:01 ` [f2fs-dev] " Chao Yu
2023-03-07 6:01 ` Chao Yu
2023-03-07 17:40 ` [f2fs-dev] " patchwork-bot+f2fs
2023-03-07 17:40 ` patchwork-bot+f2fs
2023-03-28 23:03 ` Steven Rostedt
2023-03-28 23:03 ` Steven Rostedt
2023-03-29 0:36 ` Jaegeuk Kim
2023-03-29 0:36 ` Jaegeuk Kim
2023-03-29 1:01 ` Steven Rostedt
2023-03-29 1:01 ` Steven Rostedt
2023-03-29 17:41 ` Linus Torvalds
2023-03-29 17:41 ` Linus Torvalds
2023-08-14 13:32 ` Kajetan Puchalski
2023-08-14 13:32 ` Kajetan Puchalski
2023-08-14 14:39 ` [f2fs-dev] " Kajetan Puchalski
2023-08-14 14:39 ` Kajetan Puchalski
2023-08-14 20:37 ` Jaegeuk Kim [this message]
2023-08-14 20:37 ` Jaegeuk Kim
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=ZNqQkDm0YschY+WI@google.com \
--to=jaegeuk@kernel.org \
--cc=douglas.raillard@arm.com \
--cc=jstultz@google.com \
--cc=kajetan.puchalski@arm.com \
--cc=linux-f2fs-devel@lists.sourceforge.net \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-trace-kernel@vger.kernel.org \
--cc=lukasz.luba@arm.com \
--cc=mhiramat@kernel.org \
--cc=qyousef@google.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 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.