Documentation / devicetree / bindings / phy / apple,atcphy.yaml


Based on kernel version 7.0. Page generated on 2026-04-23 09:48 EST.

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222
# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
%YAML 1.2
---
$id: http://devicetree.org/schemas/phy/apple,atcphy.yaml#
$schema: http://devicetree.org/meta-schemas/core.yaml#

title: Apple Type-C PHY (ATCPHY)

maintainers:
  - Sven Peter <sven@kernel.org>

description: >
  The Apple Type-C PHY (ATCPHY) is a combined PHY for USB 2.0, USB 3.x,
  USB4/Thunderbolt, and DisplayPort connectivity via Type-C ports found in
  Apple Silicon SoCs.
 
  The PHY handles muxing between these different protocols and also provides the
  reset controller for the attached DWC3 USB controller.
 
  It is designed for USB4 operation and does not handle individual differential
  pairs as distinct DisplayPort lanes. Any reference to lane in this binding
  hence refers to two differential pairs (RX and TX) as used in USB terminology.
 
  In order to correctly setup these lanes for the various modes calibration
  values copied from Apple's firmware and converted to the format described
  below by our bootloader m1n1 are required. Without these only USB2 operation
  is possible.

allOf:
  - $ref: /schemas/usb/usb-switch.yaml#

$defs:
  apple,tunable:
    $ref: /schemas/types.yaml#/definitions/uint32-matrix
    items:
      items:
        - description: Register offset
        - description: Mask to be applied to the register value
        - description: Bits to be set after applying the mask
    description: >
      List of (register offset, mask, value) tuples copied from Apple's Device
      Tree by our bootloader m1n1 and used to configure the PHY. These values
      even vary for a single product/device and likely contain calibration
      values determined by Apple at manufacturing time.
      Unless otherwise noted these tunables are always applied to the core
      register region.

properties:
  compatible:
    oneOf:
      - items:
          - enum:
              - apple,t6000-atcphy
              - apple,t6020-atcphy
              - apple,t8112-atcphy
          - const: apple,t8103-atcphy
      - const: apple,t8103-atcphy

  reg:
    items:
      - description: Common controls for all PHYs (USB2/3/4, DisplayPort, TBT)
      - description: DisplayPort Alternate Mode PHY specific controls
      - description: Type-C PHY AXI to Apple Fabric interconnect controls
      - description: USB2 PHY specific controls
      - description: USB3 PIPE interface controls

  reg-names:
    items:
      - const: core
      - const: lpdptx
      - const: axi2af
      - const: usb2phy
      - const: pipehandler
 
  "#phy-cells":
    const: 1
 
  "#reset-cells":
    const: 0

  mode-switch: true
  orientation-switch: true

  power-domains:
    maxItems: 1

  ports:
    $ref: /schemas/graph.yaml#/properties/ports
    properties:
      port@0:
        $ref: /schemas/graph.yaml#/properties/port
        description: Outgoing connection to the SS port of the Type-C connector.

      port@1:
        $ref: /schemas/graph.yaml#/properties/port
        description: Incoming endpoint from the USB3 controller.

      port@2:
        $ref: /schemas/graph.yaml#/properties/port
        description: Incoming endpoint from the DisplayPort controller.

      port@3:
        $ref: /schemas/graph.yaml#/properties/port
        description: Incoming endpoint from the USB4/Thunderbolt controller.

  apple,tunable-common-a:
    $ref: "#/$defs/apple,tunable"
    description: >
      Common tunables required for all modes, applied before tunable-axi2af.

  apple,tunable-axi2af:
    $ref: "#/$defs/apple,tunable"
    description: >
      AXI to Apple Fabric tunables, required for all modes. Unlike all other
      tunables these are applied to the axi2af region.

  apple,tunable-common-b:
    $ref: "#/$defs/apple,tunable"
    description: >
      Common tunables required for all modes, applied after tunable-axi2af.

  apple,tunable-lane0-usb:
    $ref: "#/$defs/apple,tunable"
    description: USB3 tunables for lane 0.

  apple,tunable-lane1-usb:
    $ref: "#/$defs/apple,tunable"
    description: USB3 tunables for lane 1.

  apple,tunable-lane0-cio:
    $ref: "#/$defs/apple,tunable"
    description: USB4/Thunderbolt ("Converged IO") tunables for lane 0.

  apple,tunable-lane1-cio:
    $ref: "#/$defs/apple,tunable"
    description: USB4/Thunderbolt ("Converged IO") tunables for lane 1.

  apple,tunable-lane0-dp:
    $ref: "#/$defs/apple,tunable"
    description: >
      DisplayPort tunables for lane 0.
 
      Note that lane here refers to a USB RX and TX pair re-used for DisplayPort
      and not to an individual DisplayPort differential lane.

  apple,tunable-lane1-dp:
    $ref: "#/$defs/apple,tunable"
    description: >
      DisplayPort tunables for lane 1.
 
      Note that lane here refers to a USB RX and TX pair re-used for DisplayPort
      and not to an individual DisplayPort differential lane.

required:
  - compatible
  - reg
  - reg-names
  - "#phy-cells"
  - "#reset-cells"
  - orientation-switch
  - mode-switch
  - power-domains
  - ports

additionalProperties: false

examples:
  - |
    phy@83000000 {
      compatible = "apple,t8103-atcphy";
      reg = <0x83000000 0x4c000>,
            <0x83050000 0x8000>,
            <0x80000000 0x4000>,
            <0x82a90000 0x4000>,
            <0x82a84000 0x4000>;
      reg-names = "core", "lpdptx", "axi2af", "usb2phy",
                  "pipehandler";
 
      #phy-cells = <1>;
      #reset-cells = <0>;
 
      orientation-switch;
      mode-switch;
      power-domains = <&ps_atc0_usb>;
 
      ports {
        #address-cells = <1>;
        #size-cells = <0>;
 
        port@0 {
          reg = <0>;
 
          endpoint {
            remote-endpoint = <&typec_connector_ss>;
          };
        };
 
        port@1 {
          reg = <1>;
 
          endpoint {
            remote-endpoint = <&dwc3_ss_out>;
          };
        };
 
        port@2 {
          reg = <2>;
 
          endpoint {
            remote-endpoint = <&dcp_dp_out>;
          };
        };
 
        port@3 {
          reg = <3>;
 
          endpoint {
            remote-endpoint = <&acio_tbt_out>;
          };
        };
      };
    };