aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/arch/x86
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2025-04-26 09:13:09 -0700
committerLinus Torvalds <torvalds@linux-foundation.org>2025-04-26 09:13:09 -0700
commit86baa5499c468f306ca7cdfc1663398c99646ceb (patch)
treecbe17d6d535ec84855acc49cd7d4d1fe3ed06028 /arch/x86
parentMerge tag 'irq-urgent-2025-04-26' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip (diff)
parentperf/x86: Fix non-sampling (counting) events on certain x86 platforms (diff)
downloadwireguard-linux-86baa5499c468f306ca7cdfc1663398c99646ceb.tar.xz
wireguard-linux-86baa5499c468f306ca7cdfc1663398c99646ceb.zip
Merge tag 'perf-urgent-2025-04-26' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip
Pull misc perf events fixes from Ingo Molnar: - Use POLLERR for events in error state, instead of the ambiguous POLLHUP error value - Fix non-sampling (counting) events on certain x86 platforms * tag 'perf-urgent-2025-04-26' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: perf/x86: Fix non-sampling (counting) events on certain x86 platforms perf/core: Change to POLLERR for pinned events with error
Diffstat (limited to 'arch/x86')
-rw-r--r--arch/x86/events/core.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/x86/events/core.c b/arch/x86/events/core.c
index 6866cc5acb0b..3a4f031d2f44 100644
--- a/arch/x86/events/core.c
+++ b/arch/x86/events/core.c
@@ -629,7 +629,7 @@ int x86_pmu_hw_config(struct perf_event *event)
if (event->attr.type == event->pmu->type)
event->hw.config |= x86_pmu_get_event_config(event);
- if (!event->attr.freq && x86_pmu.limit_period) {
+ if (is_sampling_event(event) && !event->attr.freq && x86_pmu.limit_period) {
s64 left = event->attr.sample_period;
x86_pmu.limit_period(event, &left);
if (left > event->attr.sample_period)