Skip to content

Commit 31a5ec7

Browse files
jannaumarcan
authored andcommitted
drivers/perf: Add Apple blizzard/avalanche to Apple M1 CPU PMU driver
Signed-off-by: Janne Grunau <j@jannau.net>
1 parent a1e0878 commit 31a5ec7

1 file changed

Lines changed: 14 additions & 0 deletions

File tree

drivers/perf/apple_m1_cpu_pmu.c

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -559,9 +559,23 @@ static int m1_pmu_fire_init(struct arm_pmu *cpu_pmu)
559559
return m1_pmu_init(cpu_pmu);
560560
}
561561

562+
static int m2_pmu_blizzard_init(struct arm_pmu *cpu_pmu)
563+
{
564+
cpu_pmu->name = "apple_blizzard_pmu";
565+
return m1_pmu_init(cpu_pmu);
566+
}
567+
568+
static int m2_pmu_avalanche_init(struct arm_pmu *cpu_pmu)
569+
{
570+
cpu_pmu->name = "apple_avalanche_pmu";
571+
return m1_pmu_init(cpu_pmu);
572+
}
573+
562574
static const struct of_device_id m1_pmu_of_device_ids[] = {
563575
{ .compatible = "apple,icestorm-pmu", .data = m1_pmu_ice_init, },
564576
{ .compatible = "apple,firestorm-pmu", .data = m1_pmu_fire_init, },
577+
{ .compatible = "apple,blizzard-pmu", .data = m2_pmu_blizzard_init, },
578+
{ .compatible = "apple,avalanche-pmu", .data = m2_pmu_avalanche_init, },
565579
{ },
566580
};
567581
MODULE_DEVICE_TABLE(of, m1_pmu_of_device_ids);

0 commit comments

Comments
 (0)