aboutsummaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
authorKan Liang <kan.liang@linux.intel.com>2025-04-24 06:47:15 -0700
committerPeter Zijlstra <peterz@infradead.org>2025-04-25 14:55:19 +0200
commite9988ad7b1744991118ac348a804f9395368a284 (patch)
tree3cf6e2125a2f577074465d7f8fddf3872aa700ea
parentperf/x86/intel: Only check the group flag for X86 leader (diff)
downloadwireguard-linux-e9988ad7b1744991118ac348a804f9395368a284.tar.xz
wireguard-linux-e9988ad7b1744991118ac348a804f9395368a284.zip
perf/x86/intel: Check the X86 leader for pebs_counter_event_group
The PEBS counters snapshotting group also requires a group flag in the leader. The leader must be a X86 event. Fixes: e02e9b0374c3 ("perf/x86/intel: Support PEBS counters snapshotting") Signed-off-by: Kan Liang <kan.liang@linux.intel.com> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Link: https://lkml.kernel.org/r/20250424134718.311934-3-kan.liang@linux.intel.com
-rw-r--r--arch/x86/events/perf_event.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/x86/events/perf_event.h b/arch/x86/events/perf_event.h
index 4237c379cdc5..46d120597bab 100644
--- a/arch/x86/events/perf_event.h
+++ b/arch/x86/events/perf_event.h
@@ -124,7 +124,7 @@ static inline bool is_branch_counters_group(struct perf_event *event)
static inline bool is_pebs_counter_event_group(struct perf_event *event)
{
- return event->group_leader->hw.flags & PERF_X86_EVENT_PEBS_CNTR;
+ return check_leader_group(event->group_leader, PERF_X86_EVENT_PEBS_CNTR);
}
struct amd_nb {