History

Merge tag 'perf-core-2020-08-03' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip

Pull perf event updates from Ingo Molnar: "HW support updates: - Add uncore support for Intel Comet Lake - Add RAPL support for Hygon Fam18h - Add Intel "IIO stack to PMON mapping" support on Skylake-SP CPUs, which enumerates per device performance counters via sysfs and enables the perf stat --iiostat functionality - Add support for Intel "Architectural LBRs", which generalized the model specific LBR hardware tracing feature into a model-independent, architected performance monitoring feature. Usage is mostly seamless to tooling, as the pre-existing LBR features are kept, but there's a couple of advantages under the hood, such as faster context-switching, faster LBR reads, cleaner exposure of LBR features to guest kernels, etc. ( Since architectural LBRs are supported via XSAVE, there's related changes to the x86 FPU code as well. ) ftrace/perf updates: - Add support to add a text poke event to record changes to kernel text (i.e. self-modifying code) in order to support tracers like Intel PT decoding through jump labels, kprobes and ftrace trampolines. Misc cleanups, smaller fixes..." * tag 'perf-core-2020-08-03' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: (47 commits) perf/x86/rapl: Add Hygon Fam18h RAPL support kprobes: Remove unnecessary module_mutex locking from kprobe_optimizer() x86/perf: Fix a typo perf: <linux/perf_event.h>: drop a duplicated word perf/x86/intel/lbr: Support XSAVES for arch LBR read perf/x86/intel/lbr: Support XSAVES/XRSTORS for LBR context switch x86/fpu/xstate: Add helpers for LBR dynamic supervisor feature x86/fpu/xstate: Support dynamic supervisor feature for LBR x86/fpu: Use proper mask to replace full instruction mask perf/x86: Remove task_ctx_size perf/x86/intel/lbr: Create kmem_cache for the LBR context data perf/core: Use kmem_cache to allocate the PMU specific data perf/core: Factor out functions to allocate/free the task_ctx_data perf/x86/intel/lbr: Support Architectural LBR perf/x86/intel/lbr: Factor out intel_pmu_store_lbr perf/x86/intel/lbr: Factor out rdlbr_all() and wrlbr_all() perf/x86/intel/lbr: Mark the {rd,wr}lbr_{to,from} wrappers __always_inline perf/x86/intel/lbr: Unify the stored format of LBR information perf/x86/intel/lbr: Support LBR_CTL perf/x86: Expose CPUID enumeration bits for arch LBR ...

Linus Torvalds committed 6 years ago

Commit b34133f2 parents 9dee868 d903b6d32 files · +1943 −280Browse files

Showing the changes to include/uapi/linux (1 of 32 files). Show all

Unified · Split

include/uapi/linux/perf_event.h+25−1
@@ -383,7 +383,8 @@ struct perf_event_attr { · 382 unmodified lines
383 bpf_event : 1, /* include bpf events */383 bpf_event : 1, /* include bpf events */
384 aux_output : 1, /* generate AUX records instead of events */384 aux_output : 1, /* generate AUX records instead of events */
385 cgroup : 1, /* include cgroup events */385 cgroup : 1, /* include cgroup events */
386 __reserved_1 : 31;386 text_poke : 1, /* include text poke events */
387 __reserved_1 : 30;
387 388
388 union {389 union {
389 __u32 wakeup_events; /* wakeup every n events */390 __u32 wakeup_events; /* wakeup every n events */
@@ -1041,12 +1042,35 @@ enum perf_event_type { · 651 unmodified lines
1041 */1042 */
1042 PERF_RECORD_CGROUP = 19,1043 PERF_RECORD_CGROUP = 19,
1043 1044
1045 /*
1046 * Records changes to kernel text i.e. self-modified code. 'old_len' is
1047 * the number of old bytes, 'new_len' is the number of new bytes. Either
1048 * 'old_len' or 'new_len' may be zero to indicate, for example, the
1049 * addition or removal of a trampoline. 'bytes' contains the old bytes
1050 * followed immediately by the new bytes.
1051 *
1052 * struct {
1053 * struct perf_event_header header;
1054 * u64 addr;
1055 * u16 old_len;
1056 * u16 new_len;
1057 * u8 bytes[];
1058 * struct sample_id sample_id;
1059 * };
1060 */
1061 PERF_RECORD_TEXT_POKE = 20,
1062
1044 PERF_RECORD_MAX, /* non-ABI */1063 PERF_RECORD_MAX, /* non-ABI */
1045};1064};
1046 1065
1047enum perf_record_ksymbol_type {1066enum perf_record_ksymbol_type {
1048 PERF_RECORD_KSYMBOL_TYPE_UNKNOWN = 0,1067 PERF_RECORD_KSYMBOL_TYPE_UNKNOWN = 0,
1049 PERF_RECORD_KSYMBOL_TYPE_BPF = 1,1068 PERF_RECORD_KSYMBOL_TYPE_BPF = 1,
1069 /*
1070 * Out of line code such as kprobe-replaced instructions or optimized
1071 * kprobes or ftrace trampolines.
1072 */
1073 PERF_RECORD_KSYMBOL_TYPE_OOL = 2,
1050 PERF_RECORD_KSYMBOL_TYPE_MAX /* non-ABI */1074 PERF_RECORD_KSYMBOL_TYPE_MAX /* non-ABI */
1051};1075};
1052 1076