Skip to content

Commit 7d35988

Browse files
author
Peter Zijlstra
committed
perf/x86/core: Set pebs_capable and PMU_FL_PEBS_ALL for the Baseline
The SDM explicitly states that PEBS Baseline implies Extended PEBS. For cpu model forward compatibility (e.g. on ICX, SPR, ADL), it's safe to stop doing FMS table thing such as setting pebs_capable and PMU_FL_PEBS_ALL since it's already set in the intel_ds_init(). The Goldmont Plus is the only platform which supports extended PEBS but doesn't have Baseline. Keep the status quo. Reported-by: Like Xu <[email protected]> Signed-off-by: Peter Zijlstra (Intel) <[email protected]> Reviewed-by: Kan Liang <[email protected]> Link: https://lkml.kernel.org/r/[email protected]
1 parent 32ba156 commit 7d35988

File tree

2 files changed

+1
-4
lines changed

2 files changed

+1
-4
lines changed

arch/x86/events/intel/core.c

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6291,10 +6291,8 @@ __init int intel_pmu_init(void)
62916291
x86_pmu.pebs_aliases = NULL;
62926292
x86_pmu.pebs_prec_dist = true;
62936293
x86_pmu.pebs_block = true;
6294-
x86_pmu.pebs_capable = ~0ULL;
62956294
x86_pmu.flags |= PMU_FL_HAS_RSP_1;
62966295
x86_pmu.flags |= PMU_FL_NO_HT_SHARING;
6297-
x86_pmu.flags |= PMU_FL_PEBS_ALL;
62986296
x86_pmu.flags |= PMU_FL_INSTR_LATENCY;
62996297
x86_pmu.flags |= PMU_FL_MEM_LOADS_AUX;
63006298

@@ -6337,10 +6335,8 @@ __init int intel_pmu_init(void)
63376335
x86_pmu.pebs_aliases = NULL;
63386336
x86_pmu.pebs_prec_dist = true;
63396337
x86_pmu.pebs_block = true;
6340-
x86_pmu.pebs_capable = ~0ULL;
63416338
x86_pmu.flags |= PMU_FL_HAS_RSP_1;
63426339
x86_pmu.flags |= PMU_FL_NO_HT_SHARING;
6343-
x86_pmu.flags |= PMU_FL_PEBS_ALL;
63446340
x86_pmu.flags |= PMU_FL_INSTR_LATENCY;
63456341
x86_pmu.flags |= PMU_FL_MEM_LOADS_AUX;
63466342
x86_pmu.lbr_pt_coexist = true;

arch/x86/events/intel/ds.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2262,6 +2262,7 @@ void __init intel_ds_init(void)
22622262
PERF_SAMPLE_BRANCH_STACK |
22632263
PERF_SAMPLE_TIME;
22642264
x86_pmu.flags |= PMU_FL_PEBS_ALL;
2265+
x86_pmu.pebs_capable = ~0ULL;
22652266
pebs_qual = "-baseline";
22662267
x86_get_pmu(smp_processor_id())->capabilities |= PERF_PMU_CAP_EXTENDED_REGS;
22672268
} else {

0 commit comments

Comments
 (0)