]> asedeno.scripts.mit.edu Git - linux.git/commitdiff
arm64: perf: Extend event config for ARMv8.1
authorShaokun Zhang <zhangshaokun@hisilicon.com>
Wed, 24 May 2017 07:43:18 +0000 (15:43 +0800)
committerWill Deacon <will.deacon@arm.com>
Tue, 30 May 2017 11:15:14 +0000 (12:15 +0100)
Perf has supported ARMv8.1 feature with 16-bit evtCount filed [see c210ae8
arm64: perf: Extend event mask for ARMv8.1], event config should be
extended to 16-bit too, otherwise, if use -e event_name whose event_code
is more than 0x3ff, pmu_config_term will return -EINVAL because function
pmu_format_max_value depends on event config.

This patch extends event config to 16-bit.

Signed-off-by: Shaokun Zhang <zhangshaokun@hisilicon.com>
Signed-off-by: Will Deacon <will.deacon@arm.com>
arch/arm64/kernel/perf_event.c

index 83a1b1ad189f51536af8c4c8dd8c509cb70f9a95..b5798ba211895aafe598425d5b9fa45293b3cc2d 100644 (file)
@@ -529,7 +529,7 @@ static struct attribute_group armv8_pmuv3_events_attr_group = {
        .is_visible = armv8pmu_event_attr_is_visible,
 };
 
-PMU_FORMAT_ATTR(event, "config:0-9");
+PMU_FORMAT_ATTR(event, "config:0-15");
 
 static struct attribute *armv8_pmuv3_format_attrs[] = {
        &format_attr_event.attr,