Apple Type-C PHY (ATCPHY)
Schema identifier ($id): "http://devicetree.org/schemas/phy/apple,atcphy.yaml#"
Schema dialect ($schema): "http://devicetree.org/meta-schemas/core.yaml#"
Maintainers (maintainers): "Sven Peter <sven@kernel.org>"
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.
All of these rules must match (allOf) #
Rule 1 #
Shared schema rule (
$ref):/schemas/usb/usb-switch.yaml#
Reusable definitions ($defs) #
apple,tunable #
Shared schema rule ($ref): /schemas/types.yaml#/definitions/uint32-matrix
Array item rules (items) #
Array item rules (
items)Item 1
Register offset
Item 2
Mask to be applied to the register value
Item 3
Bits to be set after applying the mask
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 and child nodes (properties) #
compatible — required here #
Exactly one of these rules must match (oneOf) #
Rule 1
Array item rules (
items)Item 1
Allowed values (
enum):"apple,t6000-atcphy","apple,t6020-atcphy","apple,t8112-atcphy"Item 2
Exact value (
const):"apple,t8103-atcphy"
Rule 2
Exact value (
const):"apple,t8103-atcphy"
reg — required here #
Array item rules (items) #
Item 1
Common controls for all PHYs (USB2/3/4, DisplayPort, TBT)
Item 2
DisplayPort Alternate Mode PHY specific controls
Item 3
Type-C PHY AXI to Apple Fabric interconnect controls
Item 4
USB2 PHY specific controls
Item 5
USB3 PIPE interface controls
reg-names — required here #
Array item rules (items) #
Item 1
Exact value (
const):"core"
Item 2
Exact value (
const):"lpdptx"
Item 3
Exact value (
const):"axi2af"
Item 4
Exact value (
const):"usb2phy"
Item 5
Exact value (
const):"pipehandler"
#phy-cells — required here #
Exact value (const): 1
#reset-cells — required here #
Exact value (const): 0
mode-switch — required here #
true — No constraints added by this property rule.
orientation-switch — required here #
true — No constraints added by this property rule.
power-domains — required here #
Maximum number of items (maxItems): 1
ports — required here #
Shared schema rule ($ref): /schemas/graph.yaml#/properties/ports
Properties and child nodes (properties) #
port@0 — not listed as required here
Shared schema rule ($ref): /schemas/graph.yaml#/properties/port
Outgoing connection to the SS port of the Type-C connector.
port@1 — not listed as required here
Shared schema rule ($ref): /schemas/graph.yaml#/properties/port
Incoming endpoint from the USB3 controller.
port@2 — not listed as required here
Shared schema rule ($ref): /schemas/graph.yaml#/properties/port
Incoming endpoint from the DisplayPort controller.
port@3 — not listed as required here
Shared schema rule ($ref): /schemas/graph.yaml#/properties/port
Incoming endpoint from the USB4/Thunderbolt controller.
apple,tunable-common-a — not listed as required here #
Shared schema rule ($ref): #/$defs/apple,tunable
Common tunables required for all modes, applied before tunable-axi2af.
apple,tunable-axi2af — not listed as required here #
Shared schema rule ($ref): #/$defs/apple,tunable
AXI to Apple Fabric tunables, required for all modes. Unlike all other tunables these are applied to the axi2af region.
apple,tunable-common-b — not listed as required here #
Shared schema rule ($ref): #/$defs/apple,tunable
Common tunables required for all modes, applied after tunable-axi2af.
apple,tunable-lane0-usb — not listed as required here #
Shared schema rule ($ref): #/$defs/apple,tunable
USB3 tunables for lane 0.
apple,tunable-lane1-usb — not listed as required here #
Shared schema rule ($ref): #/$defs/apple,tunable
USB3 tunables for lane 1.
apple,tunable-lane0-cio — not listed as required here #
Shared schema rule ($ref): #/$defs/apple,tunable
USB4/Thunderbolt ("Converged IO") tunables for lane 0.
apple,tunable-lane1-cio — not listed as required here #
Shared schema rule ($ref): #/$defs/apple,tunable
USB4/Thunderbolt ("Converged IO") tunables for lane 1.
apple,tunable-lane0-dp — not listed as required here #
Shared schema rule ($ref): #/$defs/apple,tunable
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 — not listed as required here #
Shared schema rule ($ref): #/$defs/apple,tunable
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 in this object (required): "compatible", "reg", "reg-names", "#phy-cells", "#reset-cells", "orientation-switch", "mode-switch", "power-domains", "ports"
Properties not matched by properties or patternProperties in this schema (additionalProperties) #
false
Not allowed by this rule.
Examples (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>;
};
};
};
};
Source notes #
Annotations retained from the schema source
Line 1: SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)