* [PATCH] perf: uapi: fix PERF_RECORD_SAMPLE format documentation
@ 2022-07-06 21:06 Michael Pratt
2022-07-08 20:38 ` Namhyung Kim
0 siblings, 1 reply; 3+ messages in thread
From: Michael Pratt @ 2022-07-06 21:06 UTC (permalink / raw)
To: Peter Zijlstra, Ingo Molnar, Arnaldo Carvalho de Melo,
Namhyung Kim, Tejun Heo, Kan Liang, Stephane Eranian
Cc: Mark Rutland, Alexander Shishkin, Jiri Olsa, linux-perf-users,
linux-kernel, Michael Pratt
The documented format of PERF_RECORD_SAMPLE does not match the actual
format emitted by perf_output_sample:
* The cgroup field is missing entirely.
* The data_page_size and code_page_size fields are output before the aux
data, but are documented before.
Fixes: 6546b19f95ac ("perf/core: Add PERF_SAMPLE_CGROUP feature")
Fixes: 8d97e71811aa ("perf/core: Add PERF_SAMPLE_DATA_PAGE_SIZE")
Fixes: 995f088efebe ("perf/core: Add support for PERF_SAMPLE_CODE_PAGE_SIZE")
Signed-off-by: Michael Pratt <mpratt@google.com>
---
include/uapi/linux/perf_event.h | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/include/uapi/linux/perf_event.h b/include/uapi/linux/perf_event.h
index d37629dbad72f..9a0a9a8678558 100644
--- a/include/uapi/linux/perf_event.h
+++ b/include/uapi/linux/perf_event.h
@@ -967,10 +967,11 @@ enum perf_event_type {
* { u64 abi; # enum perf_sample_regs_abi
* u64 regs[weight(mask)]; } && PERF_SAMPLE_REGS_INTR
* { u64 phys_addr;} && PERF_SAMPLE_PHYS_ADDR
- * { u64 size;
- * char data[size]; } && PERF_SAMPLE_AUX
+ * { u64 cgroup;} && PERF_SAMPLE_CGROUP
* { u64 data_page_size;} && PERF_SAMPLE_DATA_PAGE_SIZE
* { u64 code_page_size;} && PERF_SAMPLE_CODE_PAGE_SIZE
+ * { u64 size;
+ * char data[size]; } && PERF_SAMPLE_AUX
* };
*/
PERF_RECORD_SAMPLE = 9,
--
2.37.0.rc0.161.g10f37bed90-goog
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] perf: uapi: fix PERF_RECORD_SAMPLE format documentation
2022-07-06 21:06 [PATCH] perf: uapi: fix PERF_RECORD_SAMPLE format documentation Michael Pratt
@ 2022-07-08 20:38 ` Namhyung Kim
2022-08-10 13:28 ` Arnaldo Carvalho de Melo
0 siblings, 1 reply; 3+ messages in thread
From: Namhyung Kim @ 2022-07-08 20:38 UTC (permalink / raw)
To: Michael Pratt
Cc: Peter Zijlstra, Ingo Molnar, Arnaldo Carvalho de Melo, Tejun Heo,
Kan Liang, Stephane Eranian, Mark Rutland, Alexander Shishkin,
Jiri Olsa, linux-perf-users, linux-kernel
Hello,
On Wed, Jul 6, 2022 at 2:06 PM Michael Pratt <mpratt@google.com> wrote:
>
> The documented format of PERF_RECORD_SAMPLE does not match the actual
> format emitted by perf_output_sample:
>
> * The cgroup field is missing entirely.
> * The data_page_size and code_page_size fields are output before the aux
> data, but are documented before.
>
> Fixes: 6546b19f95ac ("perf/core: Add PERF_SAMPLE_CGROUP feature")
> Fixes: 8d97e71811aa ("perf/core: Add PERF_SAMPLE_DATA_PAGE_SIZE")
> Fixes: 995f088efebe ("perf/core: Add support for PERF_SAMPLE_CODE_PAGE_SIZE")
> Signed-off-by: Michael Pratt <mpratt@google.com>
Acked-by: Namhyung Kim <namhyung@kernel.org>
Thanks,
Namhyung
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] perf: uapi: fix PERF_RECORD_SAMPLE format documentation
2022-07-08 20:38 ` Namhyung Kim
@ 2022-08-10 13:28 ` Arnaldo Carvalho de Melo
0 siblings, 0 replies; 3+ messages in thread
From: Arnaldo Carvalho de Melo @ 2022-08-10 13:28 UTC (permalink / raw)
To: Namhyung Kim
Cc: Michael Pratt, Peter Zijlstra, Ingo Molnar, Tejun Heo, Kan Liang,
Stephane Eranian, Mark Rutland, Alexander Shishkin, Jiri Olsa,
linux-perf-users, linux-kernel
Em Fri, Jul 08, 2022 at 01:38:08PM -0700, Namhyung Kim escreveu:
> Hello,
>
> On Wed, Jul 6, 2022 at 2:06 PM Michael Pratt <mpratt@google.com> wrote:
> >
> > The documented format of PERF_RECORD_SAMPLE does not match the actual
> > format emitted by perf_output_sample:
> >
> > * The cgroup field is missing entirely.
> > * The data_page_size and code_page_size fields are output before the aux
> > data, but are documented before.
> >
> > Fixes: 6546b19f95ac ("perf/core: Add PERF_SAMPLE_CGROUP feature")
> > Fixes: 8d97e71811aa ("perf/core: Add PERF_SAMPLE_DATA_PAGE_SIZE")
> > Fixes: 995f088efebe ("perf/core: Add support for PERF_SAMPLE_CODE_PAGE_SIZE")
> > Signed-off-by: Michael Pratt <mpratt@google.com>
>
> Acked-by: Namhyung Kim <namhyung@kernel.org>
This hasn't been merged yet.
- Arnaldo
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2022-08-10 13:29 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-07-06 21:06 [PATCH] perf: uapi: fix PERF_RECORD_SAMPLE format documentation Michael Pratt
2022-07-08 20:38 ` Namhyung Kim
2022-08-10 13:28 ` Arnaldo Carvalho de Melo
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).