Linux-ARM-Kernel Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Sven Peter <sven@kernel.org>
To: Heikki Krogerus <heikki.krogerus@linux.intel.com>,
	 Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	 Rob Herring <robh@kernel.org>,
	Krzysztof Kozlowski <krzk+dt@kernel.org>,
	 Conor Dooley <conor+dt@kernel.org>, Janne Grunau <j@jannau.net>,
	 Neal Gompa <neal@gompa.dev>,
	Andreas Noever <andreas.noever@gmail.com>,
	 Mika Westerberg <westeri@kernel.org>,
	 Yehezkel Bernat <YehezkelShB@gmail.com>,
	 Philipp Zabel <p.zabel@pengutronix.de>
Cc: Konrad Dybcio <konradybcio@kernel.org>,
	linux-usb@vger.kernel.org,  devicetree@vger.kernel.org,
	linux-kernel@vger.kernel.org,  asahi@lists.linux.dev,
	linux-arm-kernel@lists.infradead.org,
	 Sven Peter <sven@kernel.org>
Subject: [PATCH v2 06/22] dt-bindings: thunderbolt: Add Apple USB4/Thunderbolt ACIO block
Date: Sun, 06 Sep 2026 20:36:29 +0200	[thread overview]
Message-ID: <20260906-b4-apple-soc-tbt-v2-6-1f80085f93fb@kernel.org> (raw)
In-Reply-To: <20260906-b4-apple-soc-tbt-v2-0-1f80085f93fb@kernel.org>

Each Type-C port with USB4/Thunderbolt support on Apple Silicon SoCs
comes with block called ACIO ("Apple Converged I/O"). It contains a
Cortex-M3 co-processor, the hardware blocks implementing the USB4 host
router, the Native Host Interface (NHI) and a DART IOMMU. The
co-processor exposes the NHI and its DART to the main SoC bus while it
is running.

ACIO can only be powered on after the Type-C PHY has been switched to
USB4/Thunderbolt mode. The Type-C PD controller publishes the negotiated
mode and cable information through the Type-C class. ACIO finds the
corresponding Type-C port through the OF graph connection.

Signed-off-by: Sven Peter <sven@kernel.org>
---
 .../thunderbolt/apple,t8103-usb4-acio.yaml         | 213 +++++++++++++++++++++
 MAINTAINERS                                        |   1 +
 2 files changed, 214 insertions(+)

diff --git a/Documentation/devicetree/bindings/thunderbolt/apple,t8103-usb4-acio.yaml b/Documentation/devicetree/bindings/thunderbolt/apple,t8103-usb4-acio.yaml
new file mode 100644
index 000000000000..5bfe7a66923e
--- /dev/null
+++ b/Documentation/devicetree/bindings/thunderbolt/apple,t8103-usb4-acio.yaml
@@ -0,0 +1,213 @@
+# SPDX-License-Identifier: GPL-2.0 OR BSD-2-Clause
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/thunderbolt/apple,t8103-usb4-acio.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Apple Silicon USB4/Thunderbolt Host Router (ACIO)
+
+maintainers:
+  - Sven Peter <sven@kernel.org>
+
+description: |
+  Each Type-C port with USB4/Thunderbolt support on Apple Silicon SoCs has a
+  host router complex called ACIO (Apple Converged I/O). It contains a
+  Cortex-M3 co-processor, the hardware blocks implementing the USB4 router
+  and its PCIe, USB3 and DisplayPort adapters.
+
+  The co-processor exposes the Native Host Interface (NHI) and its DART IOMMU
+  to the main SoC bus once it is running. They are therefore represented as
+  child nodes. All child registers are located in a single 16 MiB MMIO window
+  and use addresses relative to this window.
+
+  ACIO can only be powered on after the Type-C PHY has been switched to
+  USB4/Thunderbolt mode. Before the connection to the remote device can be
+  established the Type-C PD controller has to publish the negotiated mode and
+  cable information through the Type-C class. ACIO finds the corresponding
+  Type-C port through the OF graph connection.
+
+properties:
+  compatible:
+    oneOf:
+      - const: apple,t8103-usb4-acio
+      - items:
+          - enum:
+              - apple,t6000-usb4-acio
+              - apple,t6020-usb4-acio
+              - apple,t6030-usb4-acio
+              - apple,t6031-usb4-acio
+              - apple,t8112-usb4-acio
+              - apple,t8122-usb4-acio
+          - const: apple,t8103-usb4-acio
+
+  reg:
+    items:
+      - description: Root complex and co-processor control registers
+      - description: SRAM used for communication with the co-processor
+
+  reg-names:
+    items:
+      - const: rc
+      - const: sram
+
+  mboxes:
+    maxItems: 1
+    description: Mailbox used for RTKit communication with the co-processor
+
+  resets:
+    maxItems: 1
+    description: Reset used to start the ACIO block before booting the
+      co-processor
+
+  power-domains:
+    maxItems: 3
+
+  apple,tunable-rc:
+    $ref: /schemas/types.yaml#/definitions/uint32-matrix
+    items:
+      items:
+        - description: Register offset
+        - description: Mask of bits to clear
+        - description: Bits to set
+    description: |
+      List of (register offset, mask, value) tuples copied from Apple's Device
+      Tree, converted by the bootloader and used to configure the root complex
+      after the co-processor has booted.
+
+  '#address-cells':
+    const: 1
+
+  '#size-cells':
+    const: 1
+
+  ranges:
+    maxItems: 1
+    description: Single 16 MiB MMIO window containing all child registers
+
+  nonposted-mmio: true
+
+  ports:
+    $ref: /schemas/graph.yaml#/properties/ports
+    description:
+      OF graph ports for the USB4 router. The port numbers correspond to the
+      USB4 router adapter numbers.
+    properties:
+      port@1:
+        $ref: /schemas/graph.yaml#/properties/port
+        description: Lane 0 adapter of the connector-facing USB4 port
+
+      port@2:
+        $ref: /schemas/graph.yaml#/properties/port
+        description: Lane 1 adapter of the connector-facing USB4 port
+
+      port@3:
+        $ref: /schemas/graph.yaml#/properties/port
+        description: PCIe adapter
+
+      port@4:
+        $ref: /schemas/graph.yaml#/properties/port
+        description: USB3 adapter
+
+      port@5:
+        $ref: /schemas/graph.yaml#/properties/port
+        description: First DP IN adapter
+
+      port@6:
+        $ref: /schemas/graph.yaml#/properties/port
+        description: Second DP IN adapter
+
+    required:
+      - port@1
+
+  iommu@a80000:
+    $ref: /schemas/iommu/apple,dart.yaml#
+    description: DART IOMMU exposed by ACIO and used for DMA from the NHI
+
+  nhi@f00000:
+    $ref: /schemas/thunderbolt/apple,t8103-usb4-nhi.yaml#
+    description: Native Host Interface exposed by ACIO
+
+required:
+  - compatible
+  - reg
+  - reg-names
+  - mboxes
+  - power-domains
+  - resets
+  - '#address-cells'
+  - '#size-cells'
+  - ranges
+  - nonposted-mmio
+  - ports
+  - iommu@a80000
+  - nhi@f00000
+
+additionalProperties: false
+
+examples:
+  - |
+    soc {
+        #address-cells = <2>;
+        #size-cells = <2>;
+
+        cio@501ac0000 {
+            compatible = "apple,t8103-usb4-acio";
+            reg = <0x5 0x01ac0000 0x0 0xc000>,
+                  <0x5 0x01080000 0x0 0x20000>;
+            reg-names = "rc", "sram";
+            ranges = <0x0 0x5 0x01000000 0x1000000>;
+            #address-cells = <1>;
+            mboxes = <&usb4_1_mbox>;
+            nonposted-mmio;
+            pinctrl-0 = <&acio1_pins>;
+            pinctrl-names = "default";
+            power-domains = <&ps_atc1_cio>,
+                            <&ps_atc1_cio_pcie>,
+                            <&ps_atc1_cio_usb>;
+            resets = <&cio_reset 1>;
+            #size-cells = <1>;
+            ports {
+                #address-cells = <1>;
+                #size-cells = <0>;
+
+                port@1 {
+                    reg = <1>;
+
+                    endpoint {
+                        remote-endpoint = <&typec1_con_tbt>;
+                    };
+                };
+            };
+
+            usb4_1_dart: iommu@a80000 {
+                compatible = "apple,t8103-dart";
+                reg = <0xa80000 0x4000>;
+                interrupt-parent = <&aic>;
+                interrupts = <1 890 4>;
+                #iommu-cells = <1>;
+            };
+
+            nhi@f00000 {
+                compatible = "apple,t8103-usb4-nhi";
+                reg = <0xf00000 0x100000>,
+                      <0xdb0000 0x30004>;
+                reg-names = "nhi", "pdf";
+                interrupt-parent = <&aic>;
+                interrupts = <1 863 4>, <1 864 4>, <1 865 4>, <1 866 4>,
+                             <1 867 4>, <1 868 4>, <1 869 4>, <1 870 4>,
+                             <1 871 4>, <1 872 4>, <1 873 4>, <1 874 4>,
+                             <1 875 4>, <1 876 4>, <1 877 4>, <1 878 4>,
+                             <1 879 4>, <1 880 4>, <1 881 4>, <1 882 4>,
+                             <1 883 4>, <1 884 4>, <1 885 4>, <1 886 4>;
+                interrupt-names = "txring0", "txring1", "txring2", "txring3",
+                                  "txring4", "txring5", "txring6", "txring7",
+                                  "txring8", "txring9", "txring10", "txring11",
+                                  "rxring0", "rxring1", "rxring2", "rxring3",
+                                  "rxring4", "rxring5", "rxring6", "rxring7",
+                                  "rxring8", "rxring9", "rxring10", "rxring11";
+                iommus = <&usb4_1_dart 1>;
+                /* To be filled by the loader */
+                apple,thunderbolt-drom = [00];
+            };
+        };
+    };
diff --git a/MAINTAINERS b/MAINTAINERS
index a9d2e2a914c2..406cf664dedc 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -2659,6 +2659,7 @@ F:	Documentation/devicetree/bindings/rtc/apple,smc-rtc.yaml
 F:	Documentation/devicetree/bindings/soc/apple/apple,t6000-pmgr-misc.yaml
 F:	Documentation/devicetree/bindings/spi/apple,spi.yaml
 F:	Documentation/devicetree/bindings/spmi/apple,spmi.yaml
+F:	Documentation/devicetree/bindings/thunderbolt/apple,t8103-usb4-acio.yaml
 F:	Documentation/devicetree/bindings/thunderbolt/apple,t8103-usb4-nhi.yaml
 F:	Documentation/devicetree/bindings/usb/apple,dwc3.yaml
 F:	Documentation/devicetree/bindings/watchdog/apple,wdt.yaml

-- 
2.55.0




  parent reply	other threads:[~2026-09-06 18:37 UTC|newest]

Thread overview: 41+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-09-06 18:36 [PATCH v2 00/22] Initial USB4/Thunderbolt support for Apple M1/M2/M3 SoCs Sven Peter
2026-09-06 18:36 ` [PATCH v2 01/22] usb: typec: Add alternate mode state notifiers Sven Peter
2026-09-07 13:27   ` Joshua Peisach
2026-09-08 12:00   ` Heikki Krogerus
2026-09-06 18:36 ` [PATCH v2 02/22] usb: typec: Represent USB4 on the Type-C bus Sven Peter
2026-09-07 13:31   ` Joshua Peisach
2026-09-08 12:07   ` Heikki Krogerus
2026-09-06 18:36 ` [PATCH v2 03/22] usb: typec: tipd: Register a USB4 port mode for CD321x Sven Peter
2026-09-06 18:36 ` [PATCH v2 04/22] usb: typec: tipd: Publish CD321x partner alternate modes Sven Peter
2026-09-06 18:36 ` [PATCH v2 05/22] dt-bindings: thunderbolt: Add Apple USB4/Thunderbolt NHI Sven Peter
2026-09-06 18:36 ` Sven Peter [this message]
2026-09-06 18:36 ` [PATCH v2 07/22] thunderbolt: Try reading host DROM from device tree first Sven Peter
2026-09-06 18:36 ` [PATCH v2 08/22] thunderbolt: Don't read the UID if we already know it Sven Peter
2026-09-06 18:36 ` [PATCH v2 09/22] thunderbolt: Allocate ring HopID before requesting the ring interrupt Sven Peter
2026-09-06 18:36 ` [PATCH v2 10/22] thunderbolt: Unlock host router ports during startup Sven Peter
2026-09-08  8:22   ` Mika Westerberg
2026-09-06 18:36 ` [PATCH v2 11/22] thunderbolt: Find Apple VSE capability " Sven Peter
2026-09-07 13:38   ` Joshua Peisach
2026-09-08 20:24     ` Sven Peter
2026-09-06 18:36 ` [PATCH v2 12/22] thunderbolt: Add ring_interrupt_active to tb_nhi_ops Sven Peter
2026-09-06 18:36 ` [PATCH v2 13/22] thunderbolt: Add ring register accessors " Sven Peter
2026-09-08  8:32   ` Mika Westerberg
2026-09-06 18:36 ` [PATCH v2 14/22] thunderbolt: Add ring_interrupt_mask " Sven Peter
2026-09-06 18:36 ` [PATCH v2 15/22] thunderbolt: Add ring_configure " Sven Peter
2026-09-06 18:36 ` [PATCH v2 16/22] thunderbolt: Add add_links " Sven Peter
2026-09-08  8:35   ` Mika Westerberg
2026-09-06 18:36 ` [PATCH v2 17/22] thunderbolt: Add QUIRK_NO_USB3_BW_ALLOC Sven Peter
2026-09-06 18:36 ` [PATCH v2 18/22] thunderbolt: Export symbols required by the Apple Silicon driver Sven Peter
2026-09-06 18:36 ` [PATCH v2 19/22] thunderbolt: Add Apple Silicon support Sven Peter
2026-09-08  9:18   ` Mika Westerberg
2026-09-08 19:02     ` Sven Peter
2026-09-08 19:04       ` Sven Peter
2026-09-09  6:06       ` Mika Westerberg
2026-09-09 15:20         ` Sven Peter
2026-09-09 15:25           ` Sven Peter
2026-09-10  4:52             ` Mika Westerberg
2026-09-10  4:50           ` Mika Westerberg
2026-09-06 18:36 ` [PATCH v2 20/22] arm64: dts: apple: t8103: Add USB4 ACIO and NHI Sven Peter
2026-09-06 18:36 ` [PATCH v2 21/22] arm64: dts: apple: t8112: " Sven Peter
2026-09-06 18:36 ` [PATCH v2 22/22] arm64: dts: apple: t60xx: " Sven Peter
2026-09-07 13:52 ` [PATCH v2 00/22] Initial USB4/Thunderbolt support for Apple M1/M2/M3 SoCs Joshua Peisach

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=20260906-b4-apple-soc-tbt-v2-6-1f80085f93fb@kernel.org \
    --to=sven@kernel.org \
    --cc=YehezkelShB@gmail.com \
    --cc=andreas.noever@gmail.com \
    --cc=asahi@lists.linux.dev \
    --cc=conor+dt@kernel.org \
    --cc=devicetree@vger.kernel.org \
    --cc=gregkh@linuxfoundation.org \
    --cc=heikki.krogerus@linux.intel.com \
    --cc=j@jannau.net \
    --cc=konradybcio@kernel.org \
    --cc=krzk+dt@kernel.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-usb@vger.kernel.org \
    --cc=neal@gompa.dev \
    --cc=p.zabel@pengutronix.de \
    --cc=robh@kernel.org \
    --cc=westeri@kernel.org \
    /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