Document struct perf_build_id as a top-level structure in the perf_event UAPI comment and add it to the PERF_RECORD_MMAP2 union comment so future sample types can reference struct perf_build_id directly. Signed-off-by: Ian Rogers --- include/uapi/linux/perf_event.h | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/include/uapi/linux/perf_event.h b/include/uapi/linux/perf_event.h index c49fc76292f7..deb7c42d109b 100644 --- a/include/uapi/linux/perf_event.h +++ b/include/uapi/linux/perf_event.h @@ -1099,6 +1099,18 @@ enum perf_event_type { */ PERF_RECORD_SAMPLE = 9, + /* + * Build IDs may be present in a number of events. They have a + * consistent encoding of: + * + * struct perf_build_id { + * u8 size; + * u8 __reserved_1; + * u16 __reserved_2; + * u8 data[20]; + * }; + */ + /* * The MMAP2 records are an augmented version of MMAP, they add * maj, min, ino numbers to be used to uniquely identify each mapping @@ -1123,6 +1135,7 @@ enum perf_event_type { * u16 __reserved_2; * u8 build_id[20]; * }; + * struct perf_build_id bid; * }; * u32 prot, flags; * char filename[]; -- 2.56.1.703.gf848ed807c-goog