From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 4D57AC6FD20 for ; Fri, 24 Mar 2023 14:01:44 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:References: Message-ID:Subject:Cc:To:From:Date:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=+QkJ1yCYi9z1F8Ww/guHujWe2Wa+iN8XLEoxVI7c3CE=; b=ec9IcGjV3DkhqH f9Vp38qh32cArhnHePQHo5XMSdc5MuJiVHWKnku6/8W5FVb4isSFzFQP76LcUe6k/bHSJyov9esvV 2YklLBAEaPhMMnOWdy7MtNRkxM62zd2eubhybAcioaW0gMnqooLgrz0SlyrEqlaYhsHru+dqE3FM5 f3iVouplwZCwRNU74pdk4v6QKp3yhQcD1bPBt+2UdYaxuSsiE2qlJNB4591e4vWZXdjIVTe3g12jX 3DiH6EDS/byV/gKh8oYxzu7AHI6HOd5Ev3dCS2Ba3obepbkjMmAIeGdySQRvtf0iSJMt/AAaSR6Rx KzqA+Wqg1POmwk1N3SKg==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.96 #2 (Red Hat Linux)) id 1pfhyM-004ZN7-13; Fri, 24 Mar 2023 14:00:50 +0000 Received: from foss.arm.com ([217.140.110.172]) by bombadil.infradead.org with esmtp (Exim 4.96 #2 (Red Hat Linux)) id 1pfhyI-004ZM9-0r for linux-arm-kernel@lists.infradead.org; Fri, 24 Mar 2023 14:00:48 +0000 Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 6F4A211FB; Fri, 24 Mar 2023 07:01:23 -0700 (PDT) Received: from FVFF77S0Q05N (unknown [10.57.55.116]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id B9FE53F71E; Fri, 24 Mar 2023 07:00:37 -0700 (PDT) Date: Fri, 24 Mar 2023 14:00:34 +0000 From: Mark Rutland To: Janne Grunau , Will Deacon Cc: Rob Herring , Krzysztof Kozlowski , asahi@lists.linux.dev, linux-arm-kernel@lists.infradead.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH 2/2] drivers/perf: apple_m1: Add Apple M2 support Message-ID: References: <20230214-apple_m2_pmu-v1-0-9c9213ab9b63@jannau.net> <20230214-apple_m2_pmu-v1-2-9c9213ab9b63@jannau.net> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <20230214-apple_m2_pmu-v1-2-9c9213ab9b63@jannau.net> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20230324_070046_354786_339C07A2 X-CRM114-Status: GOOD ( 17.49 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On Tue, Feb 14, 2023 at 11:38:02AM +0100, Janne Grunau wrote: > The PMU itself is compatible with the one found on M1. We still know > next to nothing about the counters so keep using CPU uarch specific > compatibles/PMU names. > > Signed-off-by: Janne Grunau Acked-by: Mark Rutland --- > drivers/perf/apple_m1_cpu_pmu.c | 14 ++++++++++++++ > 1 file changed, 14 insertions(+) > > diff --git a/drivers/perf/apple_m1_cpu_pmu.c b/drivers/perf/apple_m1_cpu_pmu.c > index 979a7c2b4f56..83b74c7fe63f 100644 > --- a/drivers/perf/apple_m1_cpu_pmu.c > +++ b/drivers/perf/apple_m1_cpu_pmu.c > @@ -559,7 +559,21 @@ static int m1_pmu_fire_init(struct arm_pmu *cpu_pmu) > return m1_pmu_init(cpu_pmu); > } > > +static int m2_pmu_avalanche_init(struct arm_pmu *cpu_pmu) > +{ > + cpu_pmu->name = "apple_avalanche_pmu"; > + return m1_pmu_init(cpu_pmu); > +} > + > +static int m2_pmu_blizzard_init(struct arm_pmu *cpu_pmu) > +{ > + cpu_pmu->name = "apple_blizzard_pmu"; > + return m1_pmu_init(cpu_pmu); > +} > + > static const struct of_device_id m1_pmu_of_device_ids[] = { > + { .compatible = "apple,avalanche-pmu", .data = m2_pmu_avalanche_init, }, > + { .compatible = "apple,blizzard-pmu", .data = m2_pmu_blizzard_init, }, > { .compatible = "apple,icestorm-pmu", .data = m1_pmu_ice_init, }, > { .compatible = "apple,firestorm-pmu", .data = m1_pmu_fire_init, }, > { }, > > -- > 2.39.1 > _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel