]> git.ipfire.org Git - thirdparty/kernel/linux.git/commitdiff
arm64: perf: add support for Cortex-A78
authorSeiya Wang <seiya.wang@mediatek.com>
Wed, 3 Feb 2021 05:53:47 +0000 (13:53 +0800)
committerWill Deacon <will@kernel.org>
Wed, 3 Feb 2021 20:42:54 +0000 (20:42 +0000)
Add support for Cortex-A78 using generic PMUv3 for now.

Signed-off-by: Seiya Wang <seiya.wang@mediatek.com>
Acked-by: Mark Rutland <mark.rutland@arm.com>
Link: https://lore.kernel.org/r/20210203055348.4935-2-seiya.wang@mediatek.com
Signed-off-by: Will Deacon <will@kernel.org>
arch/arm64/kernel/perf_event.c

index 59b1eed522362f5376521bce46637e61db2f2859..b6d0b2cbdc79fffaaf4f0cfcce920a396d2d0390 100644 (file)
@@ -1188,6 +1188,12 @@ static int armv8_a77_pmu_init(struct arm_pmu *cpu_pmu)
                                       armv8_pmuv3_map_event);
 }
 
+static int armv8_a78_pmu_init(struct arm_pmu *cpu_pmu)
+{
+       return armv8_pmu_init_nogroups(cpu_pmu, "armv8_cortex_a78",
+                                      armv8_pmuv3_map_event);
+}
+
 static int armv8_e1_pmu_init(struct arm_pmu *cpu_pmu)
 {
        return armv8_pmu_init_nogroups(cpu_pmu, "armv8_neoverse_e1",
@@ -1225,6 +1231,7 @@ static const struct of_device_id armv8_pmu_of_device_ids[] = {
        {.compatible = "arm,cortex-a75-pmu",    .data = armv8_a75_pmu_init},
        {.compatible = "arm,cortex-a76-pmu",    .data = armv8_a76_pmu_init},
        {.compatible = "arm,cortex-a77-pmu",    .data = armv8_a77_pmu_init},
+       {.compatible = "arm,cortex-a78-pmu",    .data = armv8_a78_pmu_init},
        {.compatible = "arm,neoverse-e1-pmu",   .data = armv8_e1_pmu_init},
        {.compatible = "arm,neoverse-n1-pmu",   .data = armv8_n1_pmu_init},
        {.compatible = "cavium,thunder-pmu",    .data = armv8_thunder_pmu_init},