summaryrefslogtreecommitdiff
path: root/scripts/lib/kdoc/kdoc_parser.py
diff options
context:
space:
mode:
authorRavi Bangoria <ravi.bangoria@amd.com>2025-01-15 05:44:34 +0000
committerPeter Zijlstra <peterz@infradead.org>2025-02-03 11:46:05 +0100
commite1e7844ced88f9558a48579390a7d4eaac6a28eb (patch)
treee52b97a99ceceb759210c281fbc89d508e8c9b6b /scripts/lib/kdoc/kdoc_parser.py
parent46dcf85566170d4528b842bf83ffc350d71771fa (diff)
perf/amd/ibs: Don't allow freq mode event creation through ->config interface
Most perf_event_attr->config bits directly maps to IBS_{FETCH|OP}_CTL MSR. Since the sample period is programmed in these control registers, IBS PMU driver allows opening an IBS event by setting sample period value directly in perf_event_attr->config instead of using explicit perf_event_attr->sample_period interface. However, this logic is not applicable for freq mode events since the semantics of control register fields are applicable only to fixed sample period whereas the freq mode event adjusts sample period after each and every sample. Currently, IBS driver (unintentionally) allows creating freq mode event via ->config interface, which is semantically wrong as well as detrimental because it can be misused to bypass perf_event_max_sample_rate checks. Don't allow freq mode event creation through perf_event_attr->config interface. Signed-off-by: Ravi Bangoria <ravi.bangoria@amd.com> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Acked-by: Namhyung Kim <namhyung@kernel.org> Link: https://lkml.kernel.org/r/20250115054438.1021-6-ravi.bangoria@amd.com
Diffstat (limited to 'scripts/lib/kdoc/kdoc_parser.py')
0 files changed, 0 insertions, 0 deletions