perf/x86/intel: Fix SLOTS pebs event constraint
Subsystems (3)
PATCH 1/1 perf/x86/intel: Fix SLOTS pebs event constraint
From: Kan Liang <[email protected]>
Sampling SLOTS event and ref-cycles event in a group on Icelake gives EINVAL.
SLOTS event is the event stands for the fixed counter 3, not fixed counter 2. Wrong mask was set to SLOTS event in intel_icl_pebs_event_constraints[].
--- arch/x86/events/intel/ds.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
arch/x86/events/intel/ds.c +1 -1
@@ -851,7 +851,7 @@ struct event_constraint intel_skl_pebs_event_constraints[] = {struct event_constraint intel_icl_pebs_event_constraints[] = {INTEL_FLAGS_UEVENT_CONSTRAINT (0x1c0 ,0x100000000ULL ),/* INST_RETIRED.PREC_DIST */ -INTEL_FLAGS_UEVENT_CONSTRAINT (0x0400 ,0x400000000ULL ),/* SLOTS */ +INTEL_FLAGS_UEVENT_CONSTRAINT (0x0400 ,0x800000000ULL ),/* SLOTS */ INTEL_PLD_CONSTRAINT (0x1cd ,0xff ),/* MEM_TRANS_RETIRED.LOAD_LATENCY */ INTEL_FLAGS_UEVENT_CONSTRAINT_DATALA_LD (0x1d0 ,0xf ),/* MEM_INST_RETIRED.LOAD */
Signature · 1 line
2.17.1
Peter Zijlstra
maintainerQuoted 5 lines · On Tue, Jul 23, 2019 at 01:04:29PM -0700, [email protected] wrote:
From: Kan Liang <[email protected]>
Sampling SLOTS event and ref-cycles event in a group on Icelake gives EINVAL.
Quoted 7 lines
SLOTS event is the event stands for the fixed counter 3, not fixed counter 2. Wrong mask was set to SLOTS event in intel_icl_pebs_event_constraints[].
Fixes 6017608936c1 ("perf/x86/intel: Add Icelake support")Reported-by Andi Kleen <[email protected]>Signed-off-by Kan Liang <[email protected]>
Thanks!
tip-bot for Kan Liang
merge bot[tip:perf/urgent] perf/x86/intel: Fix SLOTS PEBS event constraint
In reply to [email protected]perf/x86/intel: Fix SLOTS PEBS event constraint
Commit-ID: 3d0c3953601d250175c7684ec0d9df612061dae5 Gitweb: https://git.kernel.org/tip/3d0c3953601d250175c7684ec0d9df612061dae5 Author: Kan Liang <[email protected]> AuthorDate: Tue, 23 Jul 2019 13:04:29 -0700 Committer: Ingo Molnar <[email protected]> CommitDate: Thu, 25 Jul 2019 15:41:29 +0200
perf/x86/intel: Fix SLOTS PEBS event constraint
Sampling SLOTS event and ref-cycles event in a group on Icelake gives EINVAL.
SLOTS event is the event stands for the fixed counter 3, not fixed counter 2. Wrong mask was set to SLOTS event in intel_icl_pebs_event_constraints[].
--- arch/x86/events/intel/ds.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
arch/x86/events/intel/ds.c +1 -1
@@ -851,7 +851,7 @@ struct event_constraint intel_skl_pebs_event_constraints[] = {struct event_constraint intel_icl_pebs_event_constraints[] = {INTEL_FLAGS_UEVENT_CONSTRAINT (0x1c0 ,0x100000000ULL ),/* INST_RETIRED.PREC_DIST */ -INTEL_FLAGS_UEVENT_CONSTRAINT (0x0400 ,0x400000000ULL ),/* SLOTS */ +INTEL_FLAGS_UEVENT_CONSTRAINT (0x0400 ,0x800000000ULL ),/* SLOTS */ INTEL_PLD_CONSTRAINT (0x1cd ,0xff ),/* MEM_TRANS_RETIRED.LOAD_LATENCY */ INTEL_FLAGS_UEVENT_CONSTRAINT_DATALA_LD (0x1d0 ,0xf ),/* MEM_INST_RETIRED.LOAD */