Skip to content
Commit 3c27b0c6 authored by Peter Zijlstra's avatar Peter Zijlstra
Browse files

perf/x86/amd: Fix AMD BRS period adjustment

There's two problems with the current amd_brs_adjust_period() code:

 - it isn't in fact AMD specific and wil always adjust the period;

 - it adjusts the period, while it should only adjust the event count,
   resulting in repoting a short period.

Fix this by using x86_pmu.limit_period, this makes it specific to the
AMD BRS case and ensures only the event count is adjusted while the
reported period is unmodified.

Fixes: ba2fe750

 ("perf/x86/amd: Add AMD branch sampling period adjustment")
Signed-off-by: default avatarPeter Zijlstra (Intel) <peterz@infradead.org>
parent bc469ddf
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment