mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Myria Sarvay via B4 Relay <devnull+myrialsarvay.gmail.com@kernel.org>
To: Will Deacon <will@kernel.org>,
	Mark Rutland <mark.rutland@arm.com>,
	 Rob Herring <robh@kernel.org>,
	Krzysztof Kozlowski <krzk+dt@kernel.org>,
	 Conor Dooley <conor+dt@kernel.org>, Sven Peter <sven@kernel.org>,
	 Janne Grunau <j@jannau.net>, Neal Gompa <neal@gompa.dev>,
	 Marc Zyngier <maz@kernel.org>
Cc: linux-arm-kernel@lists.infradead.org,
	linux-perf-users@vger.kernel.org,  devicetree@vger.kernel.org,
	linux-kernel@vger.kernel.org,  asahi@lists.linux.dev,
	Yuvan Shen <yuvanshen09@gmail.com>,
	 Myria Sarvay <myrialsarvay@gmail.com>,
	 Krzysztof Kozlowski <krzysztof.kozlowski@oss.qualcomm.com>,
	 Nick Chan <towinchenmi@gmail.com>
Subject: [PATCH v2 00/15] drivers/perf: apple_m1: Add M3/M4/A18 Pro Support
Date: Sat, 07 Nov 2026 21:48:47 +1100	[thread overview]
Message-ID: <20261107-m3-plus-pmu-events-v2-0-acf1e78da039@gmail.com> (raw)

This series adds support for the CPU PMU in the new M3, M4 and A18 SoCs
presed in apple devices. These PMUs have new encodings for events, along
with larger codes for these events. All of these events are as Apple
describes them in the various kpep files found under /usr/share/kpep on
macOS 27. More events may exist, but we have no idea of their affinity,
or what they actually count, so we don't include them here.

These patches have been tested on my own M2 (t8133-j413) and M3
(t6031-j514c) devices, as well as by Yuvan on their M4 (t8132-j713)
device.

If possible, the device tree changes should probably go through
apple-soc, as this is where the recently picked up M4 Pro/Max dts are.

Tested-by: Yuvan Shen <yuvanshen09@gmail.com> # on t8132-j713
Signed-off-by: Myria Sarvay <myrialsarvay@gmail.com>
---
Changes in v2:
- Remove extra cell in t6041 pmu interrupt specifications
- Add affinities for t603* and t8140 aic interrupts
- Make the a18 interrupts use the m4 function definitions directly
- Remove dead pmceid defines
- All changes address the sashiko feedback
- Link to v1: https://patch.msgid.link/20261103-m3-plus-pmu-events-v1-0-a8eb6c1139fe@gmail.com

To: Will Deacon <will@kernel.org>
To: Mark Rutland <mark.rutland@arm.com>
To: Rob Herring <robh@kernel.org>
To: Krzysztof Kozlowski <krzk+dt@kernel.org>
To: Conor Dooley <conor+dt@kernel.org>
To: Marc Zyngier <maz@kernel.org>
To: Sven Peter <sven@kernel.org>
To: Janne Grunau <j@jannau.net>
To: Neal Gompa <neal@gompa.dev>
Cc: linux-arm-kernel@lists.infradead.org
Cc: linux-perf-users@vger.kernel.org
Cc: devicetree@vger.kernel.org
Cc: linux-kernel@vger.kernel.org
Cc: asahi@lists.linux.dev

---
Myria Sarvay (14):
      dt-bindings: arm: pmu: Add Apple M3/M4/A18 Pro SoC CPU PMU compatibles
      drivers/perf: apple_m1: Remove unused variables
      drivers/perf: apple_m1: Support per-implementation event size
      drivers/perf: apple_m1: Use macros for per-implementation init functions
      drivers/perf: apple_m1: Add Apple M3 Series Support
      drivers/perf: apple_m1: Add Apple M4 Series Support
      drivers/perf: apple_m1: Add Apple A18 Support
      arm64: dts: apple: t603*: Add core interrupt affinities
      arm64: dts: apple: t8140: Add core interrupt affinities
      arm64: dts: apple: t603x: Add PMU Device Nodes
      arm64: dts: apple: t8122: Add PMU Device Nodes
      arm64: dts: apple: t604x: Add PMU Device Nodes
      arm64: dts: apple: t8132: Add PMU Device Nodes
      arm64: dts: apple: t8140: Add PMU Device Nodes

Nick Chan (1):
      drivers/perf: apple_m1: Support per-implementation event tables

 Documentation/devicetree/bindings/arm/pmu.yaml |   8 +
 arch/arm64/boot/dts/apple/t6030.dtsi           |  26 +
 arch/arm64/boot/dts/apple/t6031-base.dtsi      |  12 +
 arch/arm64/boot/dts/apple/t6031.dtsi           |  18 +
 arch/arm64/boot/dts/apple/t6032.dtsi           |  20 +
 arch/arm64/boot/dts/apple/t6041.dtsi           |  12 +
 arch/arm64/boot/dts/apple/t8122.dtsi           |  12 +
 arch/arm64/boot/dts/apple/t8132.dtsi           |  12 +
 arch/arm64/boot/dts/apple/t8140.dtsi           |  25 +
 drivers/perf/apple_m1_cpu_pmu.c                | 654 +++++++++++++++++++++----
 10 files changed, 717 insertions(+), 82 deletions(-)
---
base-commit: 84a1163b0a3ec0acdda113d4c920ed72955dd6e8
change-id: 20260929-m3-plus-pmu-events-e4010ab44135

Best regards,
--  
Myria Sarvay <myrialsarvay@gmail.com>



             reply	other threads:[~2026-11-07 10:49 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-11-07 10:48 Myria Sarvay via B4 Relay [this message]
2026-11-07 10:48 ` [PATCH v2 01/15] dt-bindings: arm: pmu: Add Apple M3/M4/A18 Pro SoC CPU PMU compatibles Myria Sarvay via B4 Relay
2026-11-07 10:48 ` [PATCH v2 02/15] drivers/perf: apple_m1: Remove unused variables Myria Sarvay via B4 Relay
2026-11-07 10:48 ` [PATCH v2 03/15] drivers/perf: apple_m1: Support per-implementation event tables Myria Sarvay via B4 Relay
2026-11-07 10:48 ` [PATCH v2 04/15] drivers/perf: apple_m1: Support per-implementation event size Myria Sarvay via B4 Relay
2026-11-07 10:48 ` [PATCH v2 05/15] drivers/perf: apple_m1: Use macros for per-implementation init functions Myria Sarvay via B4 Relay
2026-11-07 10:48 ` [PATCH v2 06/15] drivers/perf: apple_m1: Add Apple M3 Series Support Myria Sarvay via B4 Relay
2026-11-07 10:48 ` [PATCH v2 07/15] drivers/perf: apple_m1: Add Apple M4 " Myria Sarvay via B4 Relay
2026-11-07 10:48 ` [PATCH v2 08/15] drivers/perf: apple_m1: Add Apple A18 Support Myria Sarvay via B4 Relay
2026-11-07 10:48 ` [PATCH v2 09/15] arm64: dts: apple: t603*: Add core interrupt affinities Myria Sarvay via B4 Relay
2026-11-07 10:48 ` [PATCH v2 10/15] arm64: dts: apple: t8140: " Myria Sarvay via B4 Relay
2026-11-07 10:48 ` [PATCH v2 11/15] arm64: dts: apple: t603x: Add PMU Device Nodes Myria Sarvay via B4 Relay
2026-11-07 10:48 ` [PATCH v2 12/15] arm64: dts: apple: t8122: " Myria Sarvay via B4 Relay
2026-11-07 10:49 ` [PATCH v2 13/15] arm64: dts: apple: t604x: " Myria Sarvay via B4 Relay
2026-11-07 10:49 ` [PATCH v2 14/15] arm64: dts: apple: t8132: " Myria Sarvay via B4 Relay
2026-11-07 10:49 ` [PATCH v2 15/15] arm64: dts: apple: t8140: " Myria Sarvay via B4 Relay

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20261107-m3-plus-pmu-events-v2-0-acf1e78da039@gmail.com \
    --to=devnull+myrialsarvay.gmail.com@kernel.org \
    --cc=asahi@lists.linux.dev \
    --cc=conor+dt@kernel.org \
    --cc=devicetree@vger.kernel.org \
    --cc=j@jannau.net \
    --cc=krzk+dt@kernel.org \
    --cc=krzysztof.kozlowski@oss.qualcomm.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-perf-users@vger.kernel.org \
    --cc=mark.rutland@arm.com \
    --cc=maz@kernel.org \
    --cc=myrialsarvay@gmail.com \
    --cc=neal@gompa.dev \
    --cc=robh@kernel.org \
    --cc=sven@kernel.org \
    --cc=towinchenmi@gmail.com \
    --cc=will@kernel.org \
    --cc=yuvanshen09@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®