From 872f8353779fe652bd0474ee944ea3c544db544f Mon Sep 17 00:00:00 2001 From: Ryan Murray <81541646+RyanTheTide@users.noreply.github.com> Date: Sat, 7 Nov 2026 23:34:16 +1100 Subject: [PATCH 1/4] arm64: dts: apple: Describe disabled T8112 peripheral resources Describe missing media, DMA, cache, timer and fabric resources using the existing controller bindings and shared generic schemas. Correct the AVE physical register addresses and distinguish timer PWM from FPWM. Reuse the reference Mac SPI4/SPMI nodes and retain J413 board ownership. Document the existing M2 AOP service interface without enabling additional services. Signed-off-by: Ryan Murray <81541646+RyanTheTide@users.noreply.github.com> Assisted-by: LLM --- .../devicetree/bindings/crypto/apple,aes.yaml | 65 +++ .../bindings/display/apple,dcp.yaml | 23 +- .../bindings/display/apple,dpin.yaml | 41 ++ .../bindings/dma/apple,pcie-piodma.yaml | 47 +++ .../bindings/dma/apple,pciec-piodma.yaml | 47 +++ .../edac/apple,soc-error-handler.yaml | 38 +- .../bindings/iio/light/apple,aop-als.yaml | 38 ++ .../bindings/iio/position/apple,aop-las.yaml | 38 ++ .../devicetree/bindings/media/apple,jpeg.yaml | 14 +- .../bindings/media/apple,prores.yaml | 13 +- .../bindings/media/apple,scaler.yaml | 80 ++++ .../devicetree/bindings/media/apple,scdc.yaml | 61 +++ .../bindings/media/apple,t8140-ave.yaml | 26 +- .../bindings/net/nfc/apple,spmi-nfc.yaml | 49 +++ .../bindings/nvmem/apple,spmi-nvmem.yaml | 4 + .../devicetree/bindings/pwm/apple,pwm.yaml | 48 +++ .../serial/apple,dockchannel-uart.yaml | 10 +- .../bindings/soc/apple/apple,aft.yaml | 40 ++ .../bindings/soc/apple/apple,aop.yaml | 59 +++ .../bindings/soc/apple/apple,dwi.yaml | 49 +++ .../bindings/soc/apple/apple,t8140-mcc.yaml | 7 + .../bindings/sound/apple,aop-audio.yaml | 54 +++ .../bindings/sound/apple,dpaudio.yaml | 94 +++++ .../bindings/sound/apple,t6000-dpaudio.yaml | 92 ----- .../bindings/sound/apple,t6030-dpaudio.yaml | 64 --- .../devicetree/bindings/spi/apple,spi.yaml | 1 + .../bindings/spmi/apple,spmi-peripheral.yaml | 46 +++ .../bindings/spmi/apple,spmi-sideband.yaml | 47 +++ .../devicetree/bindings/spmi/apple,spmi.yaml | 1 + .../bindings/timer/apple,aic-timebase.yaml | 37 ++ .../dts/apple/t8112-j415-peripherals.dtsi | 44 ++ arch/arm64/boot/dts/apple/t8112-j415.dts | 3 + .../dts/apple/t8112-j473-peripherals.dtsi | 44 ++ arch/arm64/boot/dts/apple/t8112-j473.dts | 3 + .../dts/apple/t8112-j493-peripherals.dtsi | 27 ++ arch/arm64/boot/dts/apple/t8112-j493.dts | 3 + .../boot/dts/apple/t8112-peripherals.dtsi | 382 ++++++++++++++++++ arch/arm64/boot/dts/apple/t8112.dtsi | 26 +- 38 files changed, 1575 insertions(+), 190 deletions(-) create mode 100644 Documentation/devicetree/bindings/crypto/apple,aes.yaml create mode 100644 Documentation/devicetree/bindings/display/apple,dpin.yaml create mode 100644 Documentation/devicetree/bindings/dma/apple,pcie-piodma.yaml create mode 100644 Documentation/devicetree/bindings/dma/apple,pciec-piodma.yaml create mode 100644 Documentation/devicetree/bindings/iio/light/apple,aop-als.yaml create mode 100644 Documentation/devicetree/bindings/iio/position/apple,aop-las.yaml create mode 100644 Documentation/devicetree/bindings/media/apple,scaler.yaml create mode 100644 Documentation/devicetree/bindings/media/apple,scdc.yaml create mode 100644 Documentation/devicetree/bindings/net/nfc/apple,spmi-nfc.yaml create mode 100644 Documentation/devicetree/bindings/pwm/apple,pwm.yaml create mode 100644 Documentation/devicetree/bindings/soc/apple/apple,aft.yaml create mode 100644 Documentation/devicetree/bindings/soc/apple/apple,aop.yaml create mode 100644 Documentation/devicetree/bindings/soc/apple/apple,dwi.yaml create mode 100644 Documentation/devicetree/bindings/sound/apple,aop-audio.yaml create mode 100644 Documentation/devicetree/bindings/sound/apple,dpaudio.yaml delete mode 100644 Documentation/devicetree/bindings/sound/apple,t6000-dpaudio.yaml delete mode 100644 Documentation/devicetree/bindings/sound/apple,t6030-dpaudio.yaml create mode 100644 Documentation/devicetree/bindings/spmi/apple,spmi-peripheral.yaml create mode 100644 Documentation/devicetree/bindings/spmi/apple,spmi-sideband.yaml create mode 100644 Documentation/devicetree/bindings/timer/apple,aic-timebase.yaml create mode 100644 arch/arm64/boot/dts/apple/t8112-j415-peripherals.dtsi create mode 100644 arch/arm64/boot/dts/apple/t8112-j473-peripherals.dtsi create mode 100644 arch/arm64/boot/dts/apple/t8112-j493-peripherals.dtsi create mode 100644 arch/arm64/boot/dts/apple/t8112-peripherals.dtsi diff --git a/Documentation/devicetree/bindings/crypto/apple,aes.yaml b/Documentation/devicetree/bindings/crypto/apple,aes.yaml new file mode 100644 index 0000000000000..34a5a812a7002 --- /dev/null +++ b/Documentation/devicetree/bindings/crypto/apple,aes.yaml @@ -0,0 +1,65 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/crypto/apple,aes.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: Apple AES engine + +maintainers: + - Ryan Murray <81541646+RyanTheTide@users.noreply.github.com> + +description: | + AES hardware attached to the SIO DART. The register banks are the + engine, shared control and auxiliary control windows, in that order. + +properties: + compatible: + oneOf: + - items: + - const: apple,t6041-aes + - const: apple,aes + - items: + - const: apple,t8140-aes + - const: apple,aes + - items: + - enum: + - apple,t8112-aes + - apple,t6020-aes + - apple,t6021-aes + - apple,t6022-aes + - const: apple,aes + + reg: + minItems: 2 + maxItems: 3 + description: Register apertures in hardware-description order. + + interrupts: + maxItems: 1 + + power-domains: + maxItems: 1 + + iommus: + maxItems: 1 + +required: + - compatible + - reg + - interrupts + - power-domains + - iommus + +allOf: + - if: + properties: + compatible: + contains: + enum: ['apple,t6041-aes', 'apple,t8140-aes'] + then: + properties: + reg: + minItems: 3 + +additionalProperties: false diff --git a/Documentation/devicetree/bindings/display/apple,dcp.yaml b/Documentation/devicetree/bindings/display/apple,dcp.yaml index 081f923b497e6..a3ab3318c8d6d 100644 --- a/Documentation/devicetree/bindings/display/apple,dcp.yaml +++ b/Documentation/devicetree/bindings/display/apple,dcp.yaml @@ -65,6 +65,11 @@ properties: - enum: [disp-4, iop-vbar] - const: iop-vbar + interrupts: + minItems: 7 + maxItems: 16 + description: Optional host display-engine interrupt sources. + mboxes: maxItems: 1 @@ -414,6 +419,7 @@ allOf: enum: ['apple,t6030-dcpext', 'apple,t8132-dcpext'] required: - compatible + then: {} else: properties: mux-controls: @@ -423,11 +429,18 @@ allOf: items: pattern: '^(dp-xbar|typec[0-9]+)$' - if: - not: - properties: - compatible: - contains: - enum: ['apple,t8132-dcp', 'apple,t8132-dcpext'] + allOf: + - not: + properties: + compatible: + contains: + enum: ['apple,t8132-dcp', 'apple,t8132-dcpext'] + - not: + properties: + status: + const: disabled + required: + - status then: required: - apple,bw-scratch diff --git a/Documentation/devicetree/bindings/display/apple,dpin.yaml b/Documentation/devicetree/bindings/display/apple,dpin.yaml new file mode 100644 index 0000000000000..28367bc7c0af4 --- /dev/null +++ b/Documentation/devicetree/bindings/display/apple,dpin.yaml @@ -0,0 +1,41 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/display/apple,dpin.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: Apple DisplayPort tunnel ingress + +maintainers: + - Ryan Murray <81541646+RyanTheTide@users.noreply.github.com> + +description: | + DisplayPort ingress registers and interrupt for a USB4 display tunnel. + +properties: + compatible: + oneOf: + - items: + - const: apple,t6041-dpin + - const: apple,dpin + - items: + - enum: + - apple,t8112-dpin + - apple,t6020-dpin + - apple,t6021-dpin + - apple,t6022-dpin + - const: apple,dpin + + reg: + maxItems: 1 + description: Register apertures in hardware-description order. + + interrupts: + maxItems: 1 + +required: + - compatible + - reg + - interrupts + +additionalProperties: false diff --git a/Documentation/devicetree/bindings/dma/apple,pcie-piodma.yaml b/Documentation/devicetree/bindings/dma/apple,pcie-piodma.yaml new file mode 100644 index 0000000000000..73deeb8f3a0f8 --- /dev/null +++ b/Documentation/devicetree/bindings/dma/apple,pcie-piodma.yaml @@ -0,0 +1,47 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/dma/apple,pcie-piodma.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: Apple PCIe PIODMA engine + +maintainers: + - Ryan Murray <81541646+RyanTheTide@users.noreply.github.com> + +description: | + PCIe auxiliary DMA register banks and completion interrupt. The stream + is distinct from the PCIe endpoint streams in the same DART. + +properties: + compatible: + oneOf: + - items: + - const: apple,t6041-pcie-piodma + - const: apple,pcie-piodma + - items: + - enum: + - apple,t8112-pcie-piodma + - apple,t6020-pcie-piodma + - apple,t6021-pcie-piodma + - apple,t6022-pcie-piodma + - const: apple,pcie-piodma + + reg: + minItems: 3 + maxItems: 3 + description: Register apertures in hardware-description order. + + interrupts: + maxItems: 1 + + iommus: + maxItems: 1 + +required: + - compatible + - reg + - interrupts + - iommus + +additionalProperties: false diff --git a/Documentation/devicetree/bindings/dma/apple,pciec-piodma.yaml b/Documentation/devicetree/bindings/dma/apple,pciec-piodma.yaml new file mode 100644 index 0000000000000..0c5c47dbfe2ae --- /dev/null +++ b/Documentation/devicetree/bindings/dma/apple,pciec-piodma.yaml @@ -0,0 +1,47 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/dma/apple,pciec-piodma.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: Apple PCIe tunnel PIODMA engine + +maintainers: + - Ryan Murray <81541646+RyanTheTide@users.noreply.github.com> + +description: | + PCIe tunnel auxiliary DMA register banks and completion interrupt. Its + stream is distinct from the tunnel endpoint streams in the same DART. + +properties: + compatible: + oneOf: + - items: + - const: apple,t6041-pciec-piodma + - const: apple,pciec-piodma + - items: + - enum: + - apple,t8112-pciec-piodma + - apple,t6020-pciec-piodma + - apple,t6021-pciec-piodma + - apple,t6022-pciec-piodma + - const: apple,pciec-piodma + + reg: + minItems: 4 + maxItems: 4 + description: Register apertures in hardware-description order. + + interrupts: + maxItems: 1 + + iommus: + maxItems: 1 + +required: + - compatible + - reg + - interrupts + - iommus + +additionalProperties: false diff --git a/Documentation/devicetree/bindings/edac/apple,soc-error-handler.yaml b/Documentation/devicetree/bindings/edac/apple,soc-error-handler.yaml index 71053bd3841a5..fc8a94f5192ad 100644 --- a/Documentation/devicetree/bindings/edac/apple,soc-error-handler.yaml +++ b/Documentation/devicetree/bindings/edac/apple,soc-error-handler.yaml @@ -29,16 +29,33 @@ properties: - items: - const: apple,t8140-event-log - const: apple,soc-event-log + - items: + - enum: + - apple,t8112-error-handler + - apple,t6020-error-handler + - apple,t6021-error-handler + - apple,t6022-error-handler + - const: apple,soc-error-handler + - items: + - enum: + - apple,t8112-event-log + - apple,t6020-event-log + - apple,t6021-event-log + - apple,t6022-event-log + - const: apple,soc-event-log + + power-domains: + maxItems: 1 + description: Power domain needed for the associated error-source registers. interrupts: minItems: 9 - maxItems: 89 + maxItems: 255 reg: - minItems: 25 - maxItems: 25 - description: | - T6041 per-source NI0 through NI6 status apertures, in interrupt order. + minItems: 16 + maxItems: 255 + description: Error or event source register apertures in hardware order. required: - compatible @@ -88,6 +105,17 @@ allOf: minItems: 9 maxItems: 9 + - if: + properties: + compatible: + contains: + const: apple,t6041-error-handler + then: + properties: + reg: + minItems: 25 + maxItems: 25 + additionalProperties: false examples: diff --git a/Documentation/devicetree/bindings/iio/light/apple,aop-als.yaml b/Documentation/devicetree/bindings/iio/light/apple,aop-als.yaml new file mode 100644 index 0000000000000..1bfb009fa57ea --- /dev/null +++ b/Documentation/devicetree/bindings/iio/light/apple,aop-als.yaml @@ -0,0 +1,38 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/iio/light/apple,aop-als.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: Apple AOP ambient light sensor service + +maintainers: + - Ryan Murray <81541646+RyanTheTide@users.noreply.github.com> + +description: | + The service is supplied by the parent Always-On Processor. Firmware and + calibration handoff determine its availability. It has no independent + application-processor register window or interrupt. + +select: + properties: + compatible: + contains: + enum: + - apple,t6020-aop-als + - apple,t8112-aop-als + required: + - compatible + +properties: + compatible: + items: + - enum: + - apple,t6020-aop-als + - apple,t8112-aop-als + - const: apple,aop-als + +required: + - compatible + +additionalProperties: false diff --git a/Documentation/devicetree/bindings/iio/position/apple,aop-las.yaml b/Documentation/devicetree/bindings/iio/position/apple,aop-las.yaml new file mode 100644 index 0000000000000..bac004f1ac9b3 --- /dev/null +++ b/Documentation/devicetree/bindings/iio/position/apple,aop-las.yaml @@ -0,0 +1,38 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/iio/position/apple,aop-las.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: Apple AOP lid angle sensor service + +maintainers: + - Ryan Murray <81541646+RyanTheTide@users.noreply.github.com> + +description: | + The service is supplied by the parent Always-On Processor. Firmware and + calibration handoff determine its availability. It has no independent + application-processor register window or interrupt. + +select: + properties: + compatible: + contains: + enum: + - apple,t6020-aop-las + - apple,t8112-aop-las + required: + - compatible + +properties: + compatible: + items: + - enum: + - apple,t6020-aop-las + - apple,t8112-aop-las + - const: apple,aop-las + +required: + - compatible + +additionalProperties: false diff --git a/Documentation/devicetree/bindings/media/apple,jpeg.yaml b/Documentation/devicetree/bindings/media/apple,jpeg.yaml index 056e1d33c00fd..7602776703261 100644 --- a/Documentation/devicetree/bindings/media/apple,jpeg.yaml +++ b/Documentation/devicetree/bindings/media/apple,jpeg.yaml @@ -21,9 +21,17 @@ description: | properties: compatible: - enum: - - apple,t6041-jpeg - - apple,t8140-jpeg + oneOf: + - enum: + - apple,t6041-jpeg + - apple,t8140-jpeg + - items: + - enum: + - apple,t8112-jpeg + - apple,t6020-jpeg + - apple,t6021-jpeg + - apple,t6022-jpeg + - const: apple,jpeg reg: maxItems: 1 diff --git a/Documentation/devicetree/bindings/media/apple,prores.yaml b/Documentation/devicetree/bindings/media/apple,prores.yaml index 07afac17ef2ee..1f3f3a03396bb 100644 --- a/Documentation/devicetree/bindings/media/apple,prores.yaml +++ b/Documentation/devicetree/bindings/media/apple,prores.yaml @@ -16,7 +16,15 @@ description: | properties: compatible: - const: apple,t8140-prores + oneOf: + - const: apple,t8140-prores + - items: + - enum: + - apple,t8112-prores + - apple,t6020-prores + - apple,t6021-prores + - apple,t6022-prores + - const: apple,prores reg: items: @@ -33,7 +41,8 @@ properties: maxItems: 2 iommus: - maxItems: 1 + minItems: 1 + maxItems: 2 power-domains: minItems: 1 diff --git a/Documentation/devicetree/bindings/media/apple,scaler.yaml b/Documentation/devicetree/bindings/media/apple,scaler.yaml new file mode 100644 index 0000000000000..1f8e012c19100 --- /dev/null +++ b/Documentation/devicetree/bindings/media/apple,scaler.yaml @@ -0,0 +1,80 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/media/apple,scaler.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: Apple image scaler + +maintainers: + - Ryan Murray <81541646+RyanTheTide@users.noreply.github.com> + +description: | + The image scaler and its companion DMA registers. The two DART streams + carry image data and PIODMA transfers. Firmware performance votes are + not fixed clock rates and are not encoded as clock-frequency values. + +properties: + compatible: + oneOf: + - items: + - const: apple,t6041-scaler + - const: apple,scaler + - items: + - const: apple,t8140-scaler + - const: apple,scaler + - items: + - enum: + - apple,t8112-scaler + - apple,t6020-scaler + - apple,t6021-scaler + - apple,t6022-scaler + - const: apple,scaler + + reg: + minItems: 3 + maxItems: 4 + description: Register apertures in hardware-description order. + + interrupts: + minItems: 2 + maxItems: 2 + + power-domains: + minItems: 2 + maxItems: 3 + + iommus: + minItems: 2 + maxItems: 2 + + clocks: + maxItems: 1 + + resets: + maxItems: 1 + +required: + - compatible + - reg + - interrupts + - power-domains + - iommus + +allOf: + - if: + properties: + compatible: + contains: + enum: ['apple,t6041-scaler', 'apple,t8140-scaler'] + then: + properties: + reg: + minItems: 4 + power-domains: + maxItems: 2 + required: + - resets + - clocks + +additionalProperties: false diff --git a/Documentation/devicetree/bindings/media/apple,scdc.yaml b/Documentation/devicetree/bindings/media/apple,scdc.yaml new file mode 100644 index 0000000000000..4eee874f12c67 --- /dev/null +++ b/Documentation/devicetree/bindings/media/apple,scdc.yaml @@ -0,0 +1,61 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/media/apple,scdc.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: Apple SCDC coprocessor + +maintainers: + - Ryan Murray <81541646+RyanTheTide@users.noreply.github.com> + +description: | + SCDC coprocessor resources on M2 generation SoCs. The register apertures + follow hardware resource order. Firmware configuration and tuning are + supplied by the bootloader and are not part of this binding. Unqualified + instances must remain disabled. + +select: + properties: + compatible: + contains: + enum: + - apple,t6020-scdc + - apple,t6021-scdc + - apple,t6022-scdc + - apple,t8112-scdc + required: + - compatible + +properties: + compatible: + items: + - enum: + - apple,t6020-scdc + - apple,t6021-scdc + - apple,t6022-scdc + - apple,t8112-scdc + - const: apple,scdc + + reg: + maxItems: 8 + + interrupts: + minItems: 5 + maxItems: 6 + + iommus: + maxItems: 3 + + power-domains: + minItems: 1 + maxItems: 2 + +required: + - compatible + - reg + - interrupts + - iommus + - power-domains + +additionalProperties: false diff --git a/Documentation/devicetree/bindings/media/apple,t8140-ave.yaml b/Documentation/devicetree/bindings/media/apple,t8140-ave.yaml index dadb98b19f822..a1f7c11717414 100644 --- a/Documentation/devicetree/bindings/media/apple,t8140-ave.yaml +++ b/Documentation/devicetree/bindings/media/apple,t8140-ave.yaml @@ -16,23 +16,36 @@ description: | properties: compatible: - enum: - - apple,t6000-ave - - apple,t6041-ave - - apple,t8112-ave - - apple,t8140-ave + oneOf: + - enum: + - apple,t6000-ave + - apple,t6041-ave + - apple,t8112-ave + - apple,t8140-ave + - items: + - enum: + - apple,t6020-ave + - apple,t6021-ave + - apple,t6022-ave + - const: apple,ave reg: + minItems: 3 items: - description: Codec registers - description: Mailbox registers - description: Coprocessor registers + - description: Power control registers + - description: Fabric register aperture reg-names: + minItems: 3 items: - const: codec - const: mailbox - const: coproc + - const: power-control + - const: fabric interrupts: items: @@ -61,7 +74,8 @@ properties: PMC). iommus: - maxItems: 2 + minItems: 2 + maxItems: 4 memory-region: items: diff --git a/Documentation/devicetree/bindings/net/nfc/apple,spmi-nfc.yaml b/Documentation/devicetree/bindings/net/nfc/apple,spmi-nfc.yaml new file mode 100644 index 0000000000000..7ce5c5c7caebf --- /dev/null +++ b/Documentation/devicetree/bindings/net/nfc/apple,spmi-nfc.yaml @@ -0,0 +1,49 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/net/nfc/apple,spmi-nfc.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: Apple SPMI NFC peripheral + +maintainers: + - Ryan Murray <81541646+RyanTheTide@users.noreply.github.com> + +description: | + SPMI NFC peripheral resources. The address is a unique slave identifier on + its parent bus. Register access and protocol support are separate from + describing the peripheral and its interrupt resources. + +select: + properties: + compatible: + contains: + enum: + - apple,t6020-spmi-nfc + - apple,t6021-spmi-nfc + - apple,t6022-spmi-nfc + - apple,t8112-spmi-nfc + required: + - compatible + +properties: + compatible: + items: + - enum: + - apple,t6020-spmi-nfc + - apple,t6021-spmi-nfc + - apple,t6022-spmi-nfc + - apple,t8112-spmi-nfc + - const: apple,spmi-nfc + + reg: + maxItems: 1 + + interrupts: + maxItems: 7 + +required: + - compatible + - reg + +additionalProperties: false diff --git a/Documentation/devicetree/bindings/nvmem/apple,spmi-nvmem.yaml b/Documentation/devicetree/bindings/nvmem/apple,spmi-nvmem.yaml index f5ba5bc509cfe..97988fbc3c3dd 100644 --- a/Documentation/devicetree/bindings/nvmem/apple,spmi-nvmem.yaml +++ b/Documentation/devicetree/bindings/nvmem/apple,spmi-nvmem.yaml @@ -22,6 +22,7 @@ properties: - apple,baku-pmic - apple,chapel-pmic - apple,maverick-pmic + - apple,mirabeau-pmic - apple,monaco-pmic - apple,sera-pmic - apple,stowe-pmic @@ -31,6 +32,9 @@ properties: reg: maxItems: 1 + interrupts: + maxItems: 1 + rtc: $ref: /schemas/rtc/apple,j700-pmu-rtc.yaml# diff --git a/Documentation/devicetree/bindings/pwm/apple,pwm.yaml b/Documentation/devicetree/bindings/pwm/apple,pwm.yaml new file mode 100644 index 0000000000000..8ed94ebe9453d --- /dev/null +++ b/Documentation/devicetree/bindings/pwm/apple,pwm.yaml @@ -0,0 +1,48 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/pwm/apple,pwm.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: Apple timer PWM controller + +maintainers: + - Ryan Murray <81541646+RyanTheTide@users.noreply.github.com> + +description: | + The timer PWM controller is distinct from the FPWM keyboard-backlight + controller. It has one register aperture, one interrupt and a PMGR gate. + No firmware PWM program or board-specific output state is implied. + +select: + properties: + compatible: + contains: + enum: ['apple,t8103-pwm', 'apple,t8112-pwm'] + required: + - compatible + +properties: + compatible: + items: + - enum: + - apple,t8103-pwm + - apple,t8112-pwm + - const: apple,pwm + + reg: + maxItems: 1 + + interrupts: + maxItems: 1 + + power-domains: + maxItems: 1 + +required: + - compatible + - reg + - interrupts + - power-domains + +additionalProperties: false diff --git a/Documentation/devicetree/bindings/serial/apple,dockchannel-uart.yaml b/Documentation/devicetree/bindings/serial/apple,dockchannel-uart.yaml index 07a7f1fc8c71b..dcf49761f719a 100644 --- a/Documentation/devicetree/bindings/serial/apple,dockchannel-uart.yaml +++ b/Documentation/devicetree/bindings/serial/apple,dockchannel-uart.yaml @@ -19,7 +19,15 @@ allOf: properties: compatible: - const: apple,dockchannel-uart + oneOf: + - const: apple,dockchannel-uart + - items: + - enum: + - apple,t8112-dockchannel-uart + - apple,t6020-dockchannel-uart + - apple,t6021-dockchannel-uart + - apple,t6022-dockchannel-uart + - const: apple,dockchannel-uart reg: items: diff --git a/Documentation/devicetree/bindings/soc/apple/apple,aft.yaml b/Documentation/devicetree/bindings/soc/apple/apple,aft.yaml new file mode 100644 index 0000000000000..eaa11136152be --- /dev/null +++ b/Documentation/devicetree/bindings/soc/apple/apple,aft.yaml @@ -0,0 +1,40 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/soc/apple/apple,aft.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: Apple fabric trace controller + +maintainers: + - Ryan Murray <81541646+RyanTheTide@users.noreply.github.com> + +description: | + The fabric trace controller exposes a register aperture used by the + processor debug infrastructure. Trace programs and debug sequences are + firmware policy and are not part of this hardware description. + +select: + properties: + compatible: + contains: + enum: ['apple,t8103-aft', 'apple,t8112-aft'] + required: + - compatible + +properties: + compatible: + items: + - enum: + - apple,t8103-aft + - apple,t8112-aft + - const: apple,aft + + reg: + maxItems: 1 + +required: + - compatible + - reg + +additionalProperties: false diff --git a/Documentation/devicetree/bindings/soc/apple/apple,aop.yaml b/Documentation/devicetree/bindings/soc/apple/apple,aop.yaml new file mode 100644 index 0000000000000..38e7418b63e17 --- /dev/null +++ b/Documentation/devicetree/bindings/soc/apple/apple,aop.yaml @@ -0,0 +1,59 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/soc/apple/apple,aop.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: Apple Always-On Processor + +maintainers: + - Ryan Murray <81541646+RyanTheTide@users.noreply.github.com> + +description: | + The Always-On Processor runs firmware that owns audio and sensor services. + The host uses an RTKit mailbox and a DART stream to exchange messages and + buffers. Service nodes do not have independent host MMIO or interrupts. + +properties: + compatible: + enum: + - apple,t6020-aop + - apple,t8112-aop + + reg: + items: + - description: Shared SRAM + - description: Coprocessor registers + + mboxes: + maxItems: 1 + + mbox-names: + const: mbox + + iommus: + maxItems: 1 + + audio: + $ref: /schemas/sound/apple,aop-audio.yaml# + + als: + $ref: /schemas/iio/light/apple,aop-als.yaml# + + las: + $ref: /schemas/iio/position/apple,aop-las.yaml# + + accel: + $ref: /schemas/iio/imu/apple,aop-motion.yaml# + + gyro: + $ref: /schemas/iio/imu/apple,aop-motion.yaml# + +required: + - compatible + - reg + - mboxes + - mbox-names + - iommus + +additionalProperties: false diff --git a/Documentation/devicetree/bindings/soc/apple/apple,dwi.yaml b/Documentation/devicetree/bindings/soc/apple/apple,dwi.yaml new file mode 100644 index 0000000000000..921fd46057524 --- /dev/null +++ b/Documentation/devicetree/bindings/soc/apple/apple,dwi.yaml @@ -0,0 +1,49 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/soc/apple/apple,dwi.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: Apple DWI controller + +maintainers: + - Ryan Murray <81541646+RyanTheTide@users.noreply.github.com> + +description: | + DWI hardware register window and interrupt. Register programming and + firmware ownership must be qualified before enabling the controller. + +properties: + compatible: + oneOf: + - items: + - const: apple,t6041-dwi + - const: apple,dwi + - items: + - const: apple,t8140-dwi + - const: apple,dwi + - items: + - enum: + - apple,t8112-dwi + - apple,t6020-dwi + - apple,t6021-dwi + - apple,t6022-dwi + - const: apple,dwi + + reg: + maxItems: 1 + description: Register apertures in hardware-description order. + + interrupts: + maxItems: 1 + + power-domains: + maxItems: 1 + +required: + - compatible + - reg + - interrupts + - power-domains + +additionalProperties: false diff --git a/Documentation/devicetree/bindings/soc/apple/apple,t8140-mcc.yaml b/Documentation/devicetree/bindings/soc/apple/apple,t8140-mcc.yaml index 63767db0cea1a..2b709649479d9 100644 --- a/Documentation/devicetree/bindings/soc/apple/apple,t8140-mcc.yaml +++ b/Documentation/devicetree/bindings/soc/apple/apple,t8140-mcc.yaml @@ -24,6 +24,13 @@ properties: - items: - const: apple,t6041-mcc - const: apple,t8140-mcc + - items: + - enum: + - apple,t8112-mcc + - apple,t6020-mcc + - apple,t6021-mcc + - apple,t6022-mcc + - const: apple,mcc reg: description: Per-plane blocks on T8140, or the two multicast apertures on T8132. diff --git a/Documentation/devicetree/bindings/sound/apple,aop-audio.yaml b/Documentation/devicetree/bindings/sound/apple,aop-audio.yaml new file mode 100644 index 0000000000000..5a501c66df767 --- /dev/null +++ b/Documentation/devicetree/bindings/sound/apple,aop-audio.yaml @@ -0,0 +1,54 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/sound/apple,aop-audio.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: Apple AOP audio service + +maintainers: + - Ryan Murray <81541646+RyanTheTide@users.noreply.github.com> + +description: | + The service is supplied by the parent Always-On Processor. Firmware and + calibration handoff determine its availability. It has no independent + application-processor register window or interrupt. + +select: + properties: + compatible: + contains: + enum: + - apple,t6020-aop-audio + - apple,t8112-aop-audio + required: + - compatible + +properties: + compatible: + items: + - enum: + - apple,t6020-aop-audio + - apple,t8112-aop-audio + - const: apple,aop-audio + + dmas: + maxItems: 1 + + dma-names: + const: dma + + apple,chassis-name: + $ref: /schemas/types.yaml#/definitions/string + description: Board family used to identify the audio configuration. + + apple,machine-kind: + $ref: /schemas/types.yaml#/definitions/string + description: Machine family used for the sound card identity. + +required: + - compatible + - dmas + - dma-names + +additionalProperties: false diff --git a/Documentation/devicetree/bindings/sound/apple,dpaudio.yaml b/Documentation/devicetree/bindings/sound/apple,dpaudio.yaml new file mode 100644 index 0000000000000..deea3a1068d83 --- /dev/null +++ b/Documentation/devicetree/bindings/sound/apple,dpaudio.yaml @@ -0,0 +1,94 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/sound/apple,dpaudio.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: Apple DisplayPort audio interface + +maintainers: + - Ryan Murray + +description: | + The display processor provides a firmware audio service. Samples arrive + through an SIO DMA channel, and the graph connects the audio interface to + the display processor's audio service. The interface has a PMGR power gate. + + Existing device trees also identify a register window. The firmware audio + transport does not program that window directly. + +select: + properties: + compatible: + contains: + enum: + - apple,t6000-dpaudio + - apple,t6020-dpaudio + - apple,t6030-dpaudio + - apple,t6041-dpaudio + - apple,t8112-dpaudio + required: + - compatible + +properties: + compatible: + items: + - enum: + - apple,t6000-dpaudio + - apple,t6020-dpaudio + - apple,t6030-dpaudio + - apple,t6041-dpaudio + - apple,t8112-dpaudio + - const: apple,dpaudio + + reg: + maxItems: 1 + + dmas: + maxItems: 1 + + dma-names: + const: tx + + power-domains: + maxItems: 1 + + ports: + $ref: /schemas/graph.yaml#/properties/ports + properties: + port@0: + $ref: /schemas/graph.yaml#/properties/port + description: Connection to the display processor's audio service. + required: + - port@0 + +required: + - compatible + - dmas + - dma-names + - power-domains + - ports + +additionalProperties: false + +examples: + - | + audio-controller { + compatible = "apple,t8112-dpaudio", "apple,dpaudio"; + dmas = <&sio 0x66>; + dma-names = "tx"; + power-domains = <&ps_dpa1>; + + ports { + #address-cells = <1>; + #size-cells = <0>; + + port@0 { + reg = <0>; + + endpoint { + remote-endpoint = <&dcpext_audio>; + }; + }; + }; + }; diff --git a/Documentation/devicetree/bindings/sound/apple,t6000-dpaudio.yaml b/Documentation/devicetree/bindings/sound/apple,t6000-dpaudio.yaml deleted file mode 100644 index 7c409d4ea2c72..0000000000000 --- a/Documentation/devicetree/bindings/sound/apple,t6000-dpaudio.yaml +++ /dev/null @@ -1,92 +0,0 @@ -# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) -%YAML 1.2 ---- -$id: http://devicetree.org/schemas/sound/apple,t6000-dpaudio.yaml# -$schema: http://devicetree.org/meta-schemas/core.yaml# - -title: Apple T6000 and T6020 DisplayPort audio - -maintainers: - - Ryan Murray - -description: | - Each display coprocessor (DCP) provides a DisplayPort/HDMI audio service. - Samples are fed to it by SIO DMA; the host does not access the register - window of the interface. The graph connects this interface to port 0 of - the display processor that owns the audio service. - -select: - properties: - compatible: - contains: - enum: - - apple,t6000-dpaudio - - apple,t6020-dpaudio - required: - - compatible - -properties: - compatible: - items: - - enum: - - apple,t6000-dpaudio - - apple,t6020-dpaudio - - const: apple,dpaudio - - reg: - maxItems: 1 - - dmas: - maxItems: 1 - - dma-names: - const: tx - - power-domains: - maxItems: 1 - - ports: - $ref: /schemas/graph.yaml#/properties/ports - properties: - port@0: - $ref: /schemas/graph.yaml#/properties/port - description: Connection to the display processor's audio service. - required: - - port@0 - -required: - - compatible - - reg - - dmas - - dma-names - - power-domains - -additionalProperties: false - -examples: - - | - soc { - #address-cells = <2>; - #size-cells = <2>; - - audio-controller@39b500000 { - compatible = "apple,t6000-dpaudio", "apple,dpaudio"; - reg = <0x3 0x9b500000 0x0 0x4000>; - dmas = <&sio 0x64>; - dma-names = "tx"; - power-domains = <&ps_dpa0>; - - ports { - #address-cells = <1>; - #size-cells = <0>; - - port@0 { - reg = <0>; - - endpoint { - remote-endpoint = <&dcp_audio>; - }; - }; - }; - }; - }; diff --git a/Documentation/devicetree/bindings/sound/apple,t6030-dpaudio.yaml b/Documentation/devicetree/bindings/sound/apple,t6030-dpaudio.yaml deleted file mode 100644 index b511202f35c7e..0000000000000 --- a/Documentation/devicetree/bindings/sound/apple,t6030-dpaudio.yaml +++ /dev/null @@ -1,64 +0,0 @@ -# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) -%YAML 1.2 ---- -$id: http://devicetree.org/schemas/sound/apple,t6030-dpaudio.yaml# -$schema: http://devicetree.org/meta-schemas/core.yaml# - -title: Apple T6030 and T6041 DisplayPort audio - -maintainers: - - Ryan Murray - -description: | - The external display processor provides a DisplayPort/HDMI audio service. - Its DisplayPort audio interface has no application-processor registers. - Samples arrive through SIO, and the graph connects this interface to - port 0 of the display processor that owns the audio service. - - T6041 interfaces remain disabled until a generation-specific SIO firmware - backend and loader handoff are available and display audio is qualified. - -select: - properties: - compatible: - contains: - enum: - - apple,t6030-dpaudio - - apple,t6041-dpaudio - required: - - compatible - -properties: - compatible: - items: - - enum: - - apple,t6030-dpaudio - - apple,t6041-dpaudio - - const: apple,dpaudio - - dmas: - maxItems: 1 - - dma-names: - const: tx - - power-domains: - maxItems: 1 - - ports: - $ref: /schemas/graph.yaml#/properties/ports - properties: - port@0: - $ref: /schemas/graph.yaml#/properties/port - description: Connection to the display processor's audio service. - required: - - port@0 - -required: - - compatible - - dmas - - dma-names - - power-domains - - ports - -additionalProperties: false diff --git a/Documentation/devicetree/bindings/spi/apple,spi.yaml b/Documentation/devicetree/bindings/spi/apple,spi.yaml index 515d3dab78b65..e670893416812 100644 --- a/Documentation/devicetree/bindings/spi/apple,spi.yaml +++ b/Documentation/devicetree/bindings/spi/apple,spi.yaml @@ -18,6 +18,7 @@ properties: - items: - enum: - apple,t6020-spi + - apple,t8112-spi - apple,t6030-spi - apple,t6031-spi - apple,t6041-spi diff --git a/Documentation/devicetree/bindings/spmi/apple,spmi-peripheral.yaml b/Documentation/devicetree/bindings/spmi/apple,spmi-peripheral.yaml new file mode 100644 index 0000000000000..b2e67009a92bb --- /dev/null +++ b/Documentation/devicetree/bindings/spmi/apple,spmi-peripheral.yaml @@ -0,0 +1,46 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/spmi/apple,spmi-peripheral.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: Apple SPMI peripheral + +maintainers: + - Ryan Murray <81541646+RyanTheTide@users.noreply.github.com> + +description: | + SPMI peripheral resources. The address is a unique slave identifier on + its parent bus. Register access and protocol support are separate from + describing the peripheral and its interrupt resources. + +select: + properties: + compatible: + contains: + enum: + - apple,t6020-spmi-peripheral + - apple,t6021-spmi-peripheral + - apple,t6022-spmi-peripheral + - apple,t8112-spmi-peripheral + required: + - compatible + +properties: + compatible: + items: + - enum: + - apple,t6020-spmi-peripheral + - apple,t6021-spmi-peripheral + - apple,t6022-spmi-peripheral + - apple,t8112-spmi-peripheral + - const: apple,spmi-peripheral + + reg: + maxItems: 1 + +required: + - compatible + - reg + +additionalProperties: false diff --git a/Documentation/devicetree/bindings/spmi/apple,spmi-sideband.yaml b/Documentation/devicetree/bindings/spmi/apple,spmi-sideband.yaml new file mode 100644 index 0000000000000..44771f03efce6 --- /dev/null +++ b/Documentation/devicetree/bindings/spmi/apple,spmi-sideband.yaml @@ -0,0 +1,47 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/spmi/apple,spmi-sideband.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: Apple SPMI sideband + +maintainers: + - Ryan Murray <81541646+RyanTheTide@users.noreply.github.com> + +description: | + SPMI sideband resources on M2 generation SoCs. The register apertures + follow hardware resource order. Firmware configuration and tuning are + supplied by the bootloader and are not part of this binding. Unqualified + instances must remain disabled. + +select: + properties: + compatible: + contains: + enum: + - apple,t6020-spmi-sideband + - apple,t6021-spmi-sideband + - apple,t6022-spmi-sideband + - apple,t8112-spmi-sideband + required: + - compatible + +properties: + compatible: + items: + - enum: + - apple,t6020-spmi-sideband + - apple,t6021-spmi-sideband + - apple,t6022-spmi-sideband + - apple,t8112-spmi-sideband + - const: apple,spmi-sideband + + reg: + maxItems: 1 + +required: + - compatible + - reg + +additionalProperties: false diff --git a/Documentation/devicetree/bindings/spmi/apple,spmi.yaml b/Documentation/devicetree/bindings/spmi/apple,spmi.yaml index 0b35a017bb808..87fc5510e1e83 100644 --- a/Documentation/devicetree/bindings/spmi/apple,spmi.yaml +++ b/Documentation/devicetree/bindings/spmi/apple,spmi.yaml @@ -20,6 +20,7 @@ properties: - items: - enum: - apple,t6020-spmi + - apple,t8112-spmi - apple,t6030-spmi - apple,t6031-spmi - apple,t6041-spmi diff --git a/Documentation/devicetree/bindings/timer/apple,aic-timebase.yaml b/Documentation/devicetree/bindings/timer/apple,aic-timebase.yaml new file mode 100644 index 0000000000000..6b361d798a263 --- /dev/null +++ b/Documentation/devicetree/bindings/timer/apple,aic-timebase.yaml @@ -0,0 +1,37 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/timer/apple,aic-timebase.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: Apple AIC timebase + +maintainers: + - Ryan Murray <81541646+RyanTheTide@users.noreply.github.com> + +description: | + The timebase register aperture associated with the interrupt controller. + +properties: + compatible: + oneOf: + - items: + - const: apple,t6041-aic-timebase + - const: apple,aic-timebase + - items: + - enum: + - apple,t8112-aic-timebase + - apple,t6020-aic-timebase + - apple,t6021-aic-timebase + - apple,t6022-aic-timebase + - const: apple,aic-timebase + + reg: + maxItems: 1 + description: Register apertures in hardware-description order. + +required: + - compatible + - reg + +additionalProperties: false diff --git a/arch/arm64/boot/dts/apple/t8112-j415-peripherals.dtsi b/arch/arm64/boot/dts/apple/t8112-j415-peripherals.dtsi new file mode 100644 index 0000000000000..844cf938da69f --- /dev/null +++ b/arch/arm64/boot/dts/apple/t8112-j415-peripherals.dtsi @@ -0,0 +1,44 @@ +// SPDX-License-Identifier: GPL-2.0+ OR MIT +/* Additional T8112 hardware resources. Keep unqualified blocks disabled. */ + +&aop_spmi0 { + interrupt-parent = <&aic>; + interrupts = ; + #address-cells = <2>; + #size-cells = <0>; + interrupt-controller; + #interrupt-cells = <2>; + status = "disabled"; + + peripheral@e { + compatible = "apple,t8112-spmi-peripheral", + "apple,spmi-peripheral"; + reg = <0xe SPMI_USID>; + status = "disabled"; + }; +}; + +&aop_spmi1 { + interrupt-parent = <&aic>; + interrupts = ; + #address-cells = <2>; + #size-cells = <0>; + interrupt-controller; + #interrupt-cells = <2>; + status = "disabled"; + + nfc@8 { + compatible = "apple,t8112-spmi-nfc", + "apple,spmi-nfc"; + reg = <0x8 SPMI_USID>; + interrupt-parent = <&aop_spmi1>; + interrupts = <176 IRQ_TYPE_LEVEL_HIGH>, + <177 IRQ_TYPE_LEVEL_HIGH>, + <178 IRQ_TYPE_LEVEL_HIGH>, + <179 IRQ_TYPE_LEVEL_HIGH>, + <180 IRQ_TYPE_LEVEL_HIGH>, + <181 IRQ_TYPE_LEVEL_HIGH>, + <182 IRQ_TYPE_LEVEL_HIGH>; + status = "disabled"; + }; +}; diff --git a/arch/arm64/boot/dts/apple/t8112-j415.dts b/arch/arm64/boot/dts/apple/t8112-j415.dts index 3deb986fcfe98..e99e982f1d66e 100644 --- a/arch/arm64/boot/dts/apple/t8112-j415.dts +++ b/arch/arm64/boot/dts/apple/t8112-j415.dts @@ -316,3 +316,6 @@ &pmp_report_isp_sys { status = "okay"; }; + + +#include "t8112-j415-peripherals.dtsi" diff --git a/arch/arm64/boot/dts/apple/t8112-j473-peripherals.dtsi b/arch/arm64/boot/dts/apple/t8112-j473-peripherals.dtsi new file mode 100644 index 0000000000000..844cf938da69f --- /dev/null +++ b/arch/arm64/boot/dts/apple/t8112-j473-peripherals.dtsi @@ -0,0 +1,44 @@ +// SPDX-License-Identifier: GPL-2.0+ OR MIT +/* Additional T8112 hardware resources. Keep unqualified blocks disabled. */ + +&aop_spmi0 { + interrupt-parent = <&aic>; + interrupts = ; + #address-cells = <2>; + #size-cells = <0>; + interrupt-controller; + #interrupt-cells = <2>; + status = "disabled"; + + peripheral@e { + compatible = "apple,t8112-spmi-peripheral", + "apple,spmi-peripheral"; + reg = <0xe SPMI_USID>; + status = "disabled"; + }; +}; + +&aop_spmi1 { + interrupt-parent = <&aic>; + interrupts = ; + #address-cells = <2>; + #size-cells = <0>; + interrupt-controller; + #interrupt-cells = <2>; + status = "disabled"; + + nfc@8 { + compatible = "apple,t8112-spmi-nfc", + "apple,spmi-nfc"; + reg = <0x8 SPMI_USID>; + interrupt-parent = <&aop_spmi1>; + interrupts = <176 IRQ_TYPE_LEVEL_HIGH>, + <177 IRQ_TYPE_LEVEL_HIGH>, + <178 IRQ_TYPE_LEVEL_HIGH>, + <179 IRQ_TYPE_LEVEL_HIGH>, + <180 IRQ_TYPE_LEVEL_HIGH>, + <181 IRQ_TYPE_LEVEL_HIGH>, + <182 IRQ_TYPE_LEVEL_HIGH>; + status = "disabled"; + }; +}; diff --git a/arch/arm64/boot/dts/apple/t8112-j473.dts b/arch/arm64/boot/dts/apple/t8112-j473.dts index 3eb6ef49d5cc5..aa88793bf9397 100644 --- a/arch/arm64/boot/dts/apple/t8112-j473.dts +++ b/arch/arm64/boot/dts/apple/t8112-j473.dts @@ -275,3 +275,6 @@ }; #include "hwmon-mini.dtsi" + + +#include "t8112-j473-peripherals.dtsi" diff --git a/arch/arm64/boot/dts/apple/t8112-j493-peripherals.dtsi b/arch/arm64/boot/dts/apple/t8112-j493-peripherals.dtsi new file mode 100644 index 0000000000000..b6496cf5f8038 --- /dev/null +++ b/arch/arm64/boot/dts/apple/t8112-j493-peripherals.dtsi @@ -0,0 +1,27 @@ +// SPDX-License-Identifier: GPL-2.0+ OR MIT +/* Additional T8112 hardware resources. Keep unqualified blocks disabled. */ + +&aop_spmi1 { + interrupt-parent = <&aic>; + interrupts = ; + #address-cells = <2>; + #size-cells = <0>; + interrupt-controller; + #interrupt-cells = <2>; + status = "disabled"; + + nfc@c { + compatible = "apple,t8112-spmi-nfc", + "apple,spmi-nfc"; + reg = <0xc SPMI_USID>; + interrupt-parent = <&aop_spmi1>; + interrupts = <160 IRQ_TYPE_LEVEL_HIGH>, + <161 IRQ_TYPE_LEVEL_HIGH>, + <162 IRQ_TYPE_LEVEL_HIGH>, + <163 IRQ_TYPE_LEVEL_HIGH>, + <164 IRQ_TYPE_LEVEL_HIGH>, + <165 IRQ_TYPE_LEVEL_HIGH>, + <166 IRQ_TYPE_LEVEL_HIGH>; + status = "disabled"; + }; +}; diff --git a/arch/arm64/boot/dts/apple/t8112-j493.dts b/arch/arm64/boot/dts/apple/t8112-j493.dts index c8009d3e7024c..ae5258507e91b 100644 --- a/arch/arm64/boot/dts/apple/t8112-j493.dts +++ b/arch/arm64/boot/dts/apple/t8112-j493.dts @@ -340,3 +340,6 @@ &pmp_report_isp_sys { status = "okay"; }; + + +#include "t8112-j493-peripherals.dtsi" diff --git a/arch/arm64/boot/dts/apple/t8112-peripherals.dtsi b/arch/arm64/boot/dts/apple/t8112-peripherals.dtsi new file mode 100644 index 0000000000000..bd6f97b08b79c --- /dev/null +++ b/arch/arm64/boot/dts/apple/t8112-peripherals.dtsi @@ -0,0 +1,382 @@ +// SPDX-License-Identifier: GPL-2.0+ OR MIT +/* Additional T8112 hardware resources. Keep unqualified blocks disabled. */ + +&{/soc} { + m2_error_handler: error-handler@200100000 { + compatible = "apple,t8112-error-handler", "apple,soc-error-handler"; + reg = <0x2 0x100000 0x0 0x100000>, + <0x2 0x0 0x0 0x1000>, + <0x2 0x1c000 0x0 0xc000>, + <0x2 0x4000 0x0 0x18000>, + <0x2 0x40000 0x0 0x1000>, + <0x2 0x5c000 0x0 0xc000>, + <0x2 0x44000 0x0 0x18000>, + <0x2 0x80000 0x0 0x1000>, + <0x2 0x9c000 0x0 0xc000>, + <0x2 0x84000 0x0 0x18000>, + <0x2 0xc0000 0x0 0x1000>, + <0x2 0xdc000 0x0 0xc000>, + <0x2 0xc4000 0x0 0x18000>, + <0x2 0x5d440000 0x0 0x40000>, + <0x2 0x5d400000 0x0 0x40000>, + <0x2 0x3b000000 0x0 0x70000>, + <0x2 0x3b728000 0x0 0x4000>, + <0x2 0x1000000 0x0 0x2000000>; + interrupt-parent = <&aic>; + interrupts = , + , + , + , + , + , + , + , + , + , + , + , + , + , + , + , + , + , + ; + status = "disabled"; + }; + + m2_mcc: memory-controller@200100000 { + compatible = "apple,t8112-mcc", "apple,mcc"; + reg = <0x2 0x100000 0x0 0x80000>, + <0x2 0x0 0x0 0x100000>, + <0x2 0x1000000 0x0 0x2000000>, + <0x2 0xf00000 0x0 0x100000>, + <0x2 0x3b3c0000 0x0 0x20000>; + status = "disabled"; + }; + + m2_aft: fabric-tracker@200110000 { + compatible = "apple,t8112-aft", "apple,aft"; + reg = <0x2 0x110000 0x0 0x10000>; + status = "disabled"; + }; + + m2_aes: aes@23500c000 { + compatible = "apple,t8112-aes", "apple,aes"; + reg = <0x2 0x3500c000 0x0 0x4000>, + <0x2 0x3d2dc000 0x0 0x8000>; + interrupt-parent = <&aic>; + interrupts = ; + iommus = <&sio_dart 1>; + power-domains = <&ps_aes>; + status = "disabled"; + }; + + m2_pwm: pwm@235040000 { + compatible = "apple,t8112-pwm", "apple,pwm"; + reg = <0x2 0x35040000 0x0 0x4000>; + interrupt-parent = <&aic>; + interrupts = ; + power-domains = <&ps_fpwm0>; + status = "disabled"; + }; + + m2_aic_timebase: timer@23b0dc000 { + compatible = "apple,t8112-aic-timebase", "apple,aic-timebase"; + reg = <0x2 0x3b0dc000 0x0 0x1000>; + status = "disabled"; + }; + + m2_dwi: dwi@23b200000 { + compatible = "apple,t8112-dwi", "apple,dwi"; + reg = <0x2 0x3b200000 0x0 0x4000>; + interrupt-parent = <&aic>; + interrupts = ; + power-domains = <&ps_dwi>; + status = "disabled"; + }; + + m2_event_log_handler: event-log@23b700000 { + compatible = "apple,t8112-event-log", "apple,soc-event-log"; + reg = <0x2 0x3b700000 0x0 0xcc000>, + <0x2 0x3d280000 0x0 0x7c000>, + <0x2 0x3b000000 0x0 0x70000>, + <0x2 0x3d200000 0x0 0x7c000>, + <0x2 0x3b290000 0x0 0x4000>, + <0x2 0x3b294000 0x0 0x4000>, + <0x2 0x3b298000 0x0 0x4000>, + <0x2 0x3b29c000 0x0 0x4000>, + <0x2 0x3b2a0000 0x0 0x4000>, + <0x2 0x3b2a4000 0x0 0x4000>, + <0x2 0x3b28c000 0x0 0x4000>, + <0x2 0x3b280000 0x0 0x8000>, + <0x2 0x6b868000 0x0 0x4000>, + <0x2 0x6b838000 0x0 0x8000>, + <0x2 0x3b340000 0x0 0xc000>, + <0x2 0x3b350000 0x0 0xc000>; + interrupt-parent = <&aic>; + interrupts = , + , + , + , + , + , + , + , + , + , + , + , + , + , + , + ; + status = "disabled"; + }; + + m2_dockchannel_uart: serial@23d128000 { + compatible = "apple,t8112-dockchannel-uart", "apple,dockchannel-uart"; + reg-names = "data", "config", "irq"; + reg = <0x2 0x3d12c000 0x0 0x4000>, + <0x2 0x3d128000 0x0 0x4000>, + <0x2 0x3d10c000 0x0 0x1000>; + interrupt-parent = <&aic>; + interrupts = ; + status = "disabled"; + apple,sw-drain; + }; + + m2_nub_spmi0_sideband: spmi-sideband@23d704000 { + compatible = "apple,t8112-spmi-sideband", "apple,spmi-sideband"; + reg = <0x2 0x3d704000 0x0 0x4000>; + status = "disabled"; + }; + + m2_nub_spmi1_sideband: spmi-sideband@23d784000 { + compatible = "apple,t8112-spmi-sideband", "apple,spmi-sideband"; + reg = <0x2 0x3d784000 0x0 0x4000>; + status = "disabled"; + }; + + m2_aop_spmi0_sideband: spmi-sideband@24a884000 { + compatible = "apple,t8112-spmi-sideband", "apple,spmi-sideband"; + reg = <0x2 0x4a884000 0x0 0x4000>; + status = "disabled"; + }; + + m2_aop_spmi1_sideband: spmi-sideband@24a8c4000 { + compatible = "apple,t8112-spmi-sideband", "apple,spmi-sideband"; + reg = <0x2 0x4a8c4000 0x0 0x4000>; + status = "disabled"; + }; + + m2_scaler0: scaler@263000000 { + compatible = "apple,t8112-scaler", "apple,scaler"; + reg = <0x2 0x63000000 0x0 0x28000>, + <0x2 0x63210000 0x0 0x4000>, + <0x2 0x63204000 0x0 0x4000>; + interrupt-parent = <&aic>; + interrupts = , + ; + iommus = <&m2_dart_scaler 0>, <&m2_dart_scaler 1>; + power-domains = <&ps_msr>, <&ps_msr_ase_core>; + status = "disabled"; + }; + + m2_dart_scaler: iommu@263200000 { + compatible = "apple,t8112-dart", "apple,t8110-dart"; + reg = <0x2 0x63200000 0x0 0x4000>; + interrupt-parent = <&aic>; + interrupts = ; + power-domains = <&ps_msr>; + #iommu-cells = <1>; + status = "disabled"; + }; + + m2_jpeg0: jpeg@265000000 { + compatible = "apple,t8112-jpeg", "apple,jpeg"; + reg = <0x2 0x65000000 0x0 0x4000>; + interrupt-parent = <&aic>; + interrupts = ; + iommus = <&m2_dart_jpeg0 0>; + power-domains = <&ps_jpg>; + status = "disabled"; + }; + + m2_dart_jpeg0: iommu@265004000 { + compatible = "apple,t8112-dart", "apple,t8110-dart"; + reg = <0x2 0x65004000 0x0 0x4000>; + interrupt-parent = <&aic>; + interrupts = ; + power-domains = <&ps_jpg>; + #iommu-cells = <1>; + status = "disabled"; + }; + + m2_jpeg1: jpeg@265008000 { + compatible = "apple,t8112-jpeg", "apple,jpeg"; + reg = <0x2 0x65008000 0x0 0x4000>; + interrupt-parent = <&aic>; + interrupts = ; + iommus = <&m2_dart_jpeg1 0>; + power-domains = <&ps_jpg>; + status = "disabled"; + }; + + m2_dart_jpeg1: iommu@26500c000 { + compatible = "apple,t8112-dart", "apple,t8110-dart"; + reg = <0x2 0x6500c000 0x0 0x4000>; + interrupt-parent = <&aic>; + interrupts = ; + power-domains = <&ps_jpg>; + #iommu-cells = <1>; + status = "disabled"; + }; + + m2_dart_ave_2: iommu@267020000 { + compatible = "apple,t8112-dart", "apple,t8110-dart"; + reg = <0x2 0x67020000 0x0 0x4000>; + interrupt-parent = <&aic>; + interrupts = ; + power-domains = <&ps_venc_sys>; + #iommu-cells = <1>; + status = "disabled"; + }; + + m2_dart_ave_3: iommu@267044000 { + compatible = "apple,t8112-dart", "apple,t8110-dart"; + reg = <0x2 0x67044000 0x0 0x4000>; + interrupt-parent = <&aic>; + interrupts = ; + power-domains = <&ps_venc_sys>; + #iommu-cells = <1>; + status = "disabled"; + }; + + m2_dart_dispext0_1: iommu@271300000 { + compatible = "apple,t8112-dart", "apple,t8110-dart"; + reg = <0x2 0x71300000 0x0 0x4000>; + interrupt-parent = <&aic>; + interrupts = ; + #iommu-cells = <1>; + status = "disabled"; + }; + + m2_apr: video-codec@27d000000 { + compatible = "apple,t8112-prores", "apple,prores"; + reg-names = "core", "wrapper"; + reg = <0x2 0x7d000000 0x0 0x4000>, + <0x2 0x7c000000 0x0 0x4000>; + interrupt-parent = <&aic>; + interrupts = , + ; + iommus = <&m2_dart_apr_0 0>, <&m2_dart_apr_1 0>; + power-domains = <&ps_scodec>; + status = "disabled"; + }; + + m2_dart_apr_1: iommu@27d024000 { + compatible = "apple,t8112-dart", "apple,t8110-dart"; + reg = <0x2 0x7d024000 0x0 0x4000>; + interrupt-parent = <&aic>; + interrupts = ; + #iommu-cells = <1>; + status = "disabled"; + }; + + m2_dart_apr_0: iommu@27d028000 { + compatible = "apple,t8112-dart", "apple,t8110-dart"; + reg = <0x2 0x7d028000 0x0 0x4000>; + interrupt-parent = <&aic>; + interrupts = ; + #iommu-cells = <1>; + status = "disabled"; + }; + + m2_dart_scdc: iommu@27d02c000 { + compatible = "apple,t8112-dart", "apple,t8110-dart"; + reg = <0x2 0x7d02c000 0x0 0x4000>; + interrupt-parent = <&aic>; + interrupts = ; + #iommu-cells = <1>; + status = "disabled"; + }; + + m2_scdc: coprocessor@27e400000 { + compatible = "apple,t8112-scdc", "apple,scdc"; + reg = <0x2 0x7e400000 0x0 0x6c000>, + <0x2 0x7e050000 0x0 0x4000>, + <0x2 0x7c000000 0x0 0x1000000>, + <0x2 0x7d040000 0x0 0x1c000>, + <0x2 0x7d070000 0x0 0x4000>, + <0x2 0x7d074000 0x0 0x4000>, + <0x2 0x7d100000 0x0 0x3c000>, + <0x2 0x7d140000 0x0 0x20000>; + interrupt-parent = <&aic>; + interrupts = , + , + , + , + , + ; + iommus = <&m2_dart_scdc 0>, <&m2_dart_apr_0 0>, <&m2_dart_apr_1 0>; + power-domains = <&ps_scodec>; + status = "disabled"; + }; + + m2_atc0_dpin0: displayport-input@381e50000 { + compatible = "apple,t8112-dpin", "apple,dpin"; + reg = <0x3 0x81e50000 0x0 0x4000>; + interrupt-parent = <&aic>; + interrupts = ; + status = "disabled"; + }; + + m2_atc0_dpin1: displayport-input@381e58000 { + compatible = "apple,t8112-dpin", "apple,dpin"; + reg = <0x3 0x81e58000 0x0 0x4000>; + interrupt-parent = <&aic>; + interrupts = ; + status = "disabled"; + }; + + m2_apciec0_piodma: dma-controller@3a2000000 { + compatible = "apple,t8112-pciec-piodma", "apple,pciec-piodma"; + reg = <0x3 0xa2000000 0x0 0x4000>, + <0x3 0xa2004000 0x0 0x4000>, + <0x3 0xa2008000 0x0 0x4000>, + <0x3 0xa0008000 0x0 0x4000>; + interrupt-parent = <&aic>; + interrupts = ; + iommus = <&apciec0_dart 15>; + status = "disabled"; + }; + + m2_atc1_dpin0: displayport-input@501e50000 { + compatible = "apple,t8112-dpin", "apple,dpin"; + reg = <0x5 0x1e50000 0x0 0x4000>; + interrupt-parent = <&aic>; + interrupts = ; + status = "disabled"; + }; + + m2_atc1_dpin1: displayport-input@501e58000 { + compatible = "apple,t8112-dpin", "apple,dpin"; + reg = <0x5 0x1e58000 0x0 0x4000>; + interrupt-parent = <&aic>; + interrupts = ; + status = "disabled"; + }; + + m2_apciec1_piodma: dma-controller@522000000 { + compatible = "apple,t8112-pciec-piodma", "apple,pciec-piodma"; + reg = <0x5 0x22000000 0x0 0x4000>, + <0x5 0x22004000 0x0 0x4000>, + <0x5 0x22008000 0x0 0x4000>, + <0x5 0x20008000 0x0 0x4000>; + interrupt-parent = <&aic>; + interrupts = ; + iommus = <&apciec1_dart 15>; + status = "disabled"; + }; +}; diff --git a/arch/arm64/boot/dts/apple/t8112.dtsi b/arch/arm64/boot/dts/apple/t8112.dtsi index 5c7875256502a..27c8910b390e6 100644 --- a/arch/arm64/boot/dts/apple/t8112.dtsi +++ b/arch/arm64/boot/dts/apple/t8112.dtsi @@ -505,9 +505,9 @@ /* Required to get >32-bit DMA via DARTs */ dma-ranges = <0 0 0 0 0xffffffff 0xffffc000>; - ave_dart0: iommu@67030000 { + ave_dart0: iommu@267030000 { compatible = "apple,t8112-dart", "apple,t8110-dart"; - reg = <0 0x67030000 0 0x4000>; + reg = <0x2 0x67030000 0 0x4000>; interrupt-parent = <&aic>; interrupts = ; power-domains = <&ps_venc_sys>; @@ -515,9 +515,9 @@ status = "disabled"; }; - ave_dart1: iommu@67040000 { + ave_dart1: iommu@267040000 { compatible = "apple,t8112-dart", "apple,t8110-dart"; - reg = <0 0x67040000 0 0x4000>; + reg = <0x2 0x67040000 0 0x4000>; interrupt-parent = <&aic>; interrupts = ; power-domains = <&ps_venc_sys>; @@ -525,11 +525,11 @@ status = "disabled"; }; - ave: video-codec@67100000 { + ave: video-codec@267100000 { compatible = "apple,t8112-ave"; - reg = <0 0x67100000 0 0x45c000>, - <0 0x67050000 0 0x8000>, - <0 0x67800000 0 0x800000>; + reg = <0x2 0x67100000 0 0x45c000>, + <0x2 0x67050000 0 0x8000>, + <0x2 0x67800000 0 0x800000>; reg-names = "codec", "mailbox", "coproc"; interrupt-parent = <&aic>; interrupts = , @@ -962,7 +962,7 @@ }; spi4: spi@235110000 { - compatible = "apple,t8112-spi", "apple,spi"; + compatible = "apple,t8112-spi", "apple,t8103-spi"; reg = <0x2 0x35110000 0x0 0x4000>; interrupt-parent = <&aic>; interrupts = ; @@ -1495,7 +1495,7 @@ }; nub_spmi1: spmi@23d794000 { - compatible = "apple,t8112-spmi", "apple,spmi"; + compatible = "apple,t8112-spmi", "apple,t8103-spmi"; reg = <0x2 0x3d794000 0x0 0x100>; #address-cells = <2>; #size-cells = <0>; @@ -1627,7 +1627,7 @@ }; aop_spmi0: spmi@24a894000 { - compatible = "apple,t8112-spmi", "apple,spmi"; + compatible = "apple,t8112-spmi", "apple,t8103-spmi"; reg = <0x2 0x4a894000 0x0 0x100>; #address-cells = <2>; #size-cells = <0>; @@ -1635,7 +1635,7 @@ }; aop_spmi1: spmi@24a8d4000 { - compatible = "apple,t8112-spmi", "apple,spmi"; + compatible = "apple,t8112-spmi", "apple,t8103-spmi"; reg = <0x2 0x4a8d4000 0x0 0x100>; #address-cells = <2>; #size-cells = <0>; @@ -2641,3 +2641,5 @@ apple,peak-bandwidth-bytes-per-second = /bits/ 64 <102400000000>; apple,bandwidth-class-bytes-per-second = /bits/ 64 <100000000000>; }; + +#include "t8112-peripherals.dtsi" From 60917b7450f2845d51653427170ef32f79c5cf3e Mon Sep 17 00:00:00 2001 From: Ryan Murray <81541646+RyanTheTide@users.noreply.github.com> Date: Sat, 7 Nov 2026 23:43:45 +1100 Subject: [PATCH 2/4] dt-bindings: sound: Keep a single shared Apple DisplayPort audio binding Remove the legacy T8112 schema after consolidating its contract into apple,dpaudio.yaml. Signed-off-by: Ryan Murray <81541646+RyanTheTide@users.noreply.github.com> Assisted-by: LLM --- .../bindings/sound/apple,t8112-dpaudio.yaml | 84 ------------------- 1 file changed, 84 deletions(-) delete mode 100644 Documentation/devicetree/bindings/sound/apple,t8112-dpaudio.yaml diff --git a/Documentation/devicetree/bindings/sound/apple,t8112-dpaudio.yaml b/Documentation/devicetree/bindings/sound/apple,t8112-dpaudio.yaml deleted file mode 100644 index b4e4af0aaa715..0000000000000 --- a/Documentation/devicetree/bindings/sound/apple,t8112-dpaudio.yaml +++ /dev/null @@ -1,84 +0,0 @@ -# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) -%YAML 1.2 ---- -$id: http://devicetree.org/schemas/sound/apple,t8112-dpaudio.yaml# -$schema: http://devicetree.org/meta-schemas/core.yaml# - -title: Apple T8112 DisplayPort audio interface - -maintainers: - - Ryan Murray - -description: | - The display processor provides a firmware audio service. Samples arrive - through an SIO DMA channel, and the graph connects the audio interface to - the display processor's audio service. The interface has a PMGR power gate. - - Existing device trees also identify a register window. The firmware audio - transport does not program that window directly. - -select: - properties: - compatible: - contains: - const: apple,t8112-dpaudio - required: - - compatible - -properties: - compatible: - items: - - const: apple,t8112-dpaudio - - const: apple,dpaudio - - reg: - maxItems: 1 - - dmas: - maxItems: 1 - - dma-names: - const: tx - - power-domains: - maxItems: 1 - - ports: - $ref: /schemas/graph.yaml#/properties/ports - properties: - port@0: - $ref: /schemas/graph.yaml#/properties/port - description: Connection to the display processor's audio service. - required: - - port@0 - -required: - - compatible - - dmas - - dma-names - - power-domains - - ports - -additionalProperties: false - -examples: - - | - audio-controller { - compatible = "apple,t8112-dpaudio", "apple,dpaudio"; - dmas = <&sio 0x66>; - dma-names = "tx"; - power-domains = <&ps_dpa1>; - - ports { - #address-cells = <1>; - #size-cells = <0>; - - port@0 { - reg = <0>; - - endpoint { - remote-endpoint = <&dcpext_audio>; - }; - }; - }; - }; From 4db88d22fe95f1979984e3b9598a9cf969c5e4f5 Mon Sep 17 00:00:00 2001 From: Ryan Murray <81541646+RyanTheTide@users.noreply.github.com> Date: Sun, 8 Nov 2026 00:02:15 +1100 Subject: [PATCH 3/4] dt-bindings: apple: Describe M2 MTP and legacy ISP interfaces Describe the existing firmware helper and legacy ISP host interface without changing any device state or importing firmware configuration. Preserve the T6041 ISP resource and handoff requirements. Signed-off-by: Ryan Murray <81541646+RyanTheTide@users.noreply.github.com> Assisted-by: LLM --- .../{apple,t6041-isp.yaml => apple,isp.yaml} | 93 ++++++++--- .../soc/apple/apple,rtk-helper-asc4.yaml | 158 ++++-------------- 2 files changed, 102 insertions(+), 149 deletions(-) rename Documentation/devicetree/bindings/media/{apple,t6041-isp.yaml => apple,isp.yaml} (73%) diff --git a/Documentation/devicetree/bindings/media/apple,t6041-isp.yaml b/Documentation/devicetree/bindings/media/apple,isp.yaml similarity index 73% rename from Documentation/devicetree/bindings/media/apple,t6041-isp.yaml rename to Documentation/devicetree/bindings/media/apple,isp.yaml index e66161db7c371..0b015b75ee4b8 100644 --- a/Documentation/devicetree/bindings/media/apple,t6041-isp.yaml +++ b/Documentation/devicetree/bindings/media/apple,isp.yaml @@ -1,16 +1,16 @@ # SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) %YAML 1.2 --- -$id: http://devicetree.org/schemas/media/apple,t6041-isp.yaml# +$id: http://devicetree.org/schemas/media/apple,isp.yaml# $schema: http://devicetree.org/meta-schemas/core.yaml# -title: Apple T604x Image Signal Processor +title: Apple Image Signal Processor maintainers: - Jonathan Goyvaerts description: - The T604x ISP controls the attached camera sensor and processes its frames + The ISP controls the attached camera sensor and processes its frames through firmware the bootloader loads. The firmware segments are described as reserved memory mapped at the addresses the firmware runs them at. The host exchanges commands and image buffers through three DART instances. @@ -19,14 +19,17 @@ select: properties: compatible: contains: - const: apple,t6041-isp + enum: ['apple,t6020-isp', 'apple,t6041-isp', 'apple,t8112-isp'] required: - compatible properties: compatible: items: - - const: apple,t6041-isp + - enum: + - apple,t6020-isp + - apple,t6041-isp + - apple,t8112-isp - const: apple,isp reg: @@ -53,27 +56,20 @@ properties: - description: Third ISP DART stream power-domains: - items: - - description: ISP system domain - - description: ISP CPU domain - - description: ISP FE domain - - description: ISP DPRX domain - - description: ISP secure domain - - description: ISP BE domain - - description: ISP CLR domain - - description: Camera sensor domain + minItems: 7 + maxItems: 16 + description: Register-backed power domains required by the ISP. memory-region: - items: - - description: Firmware text loaded by the bootloader - - description: Firmware data loaded by the bootloader - - description: Firmware main memory window; host allocations follow it + minItems: 1 + maxItems: 3 + description: Firmware memory and the host allocation heap. memory-region-names: + minItems: 1 + maxItems: 3 items: - - const: text - - const: data - - const: heap + enum: [text, data, heap] apple,dart-vm-size: $ref: /schemas/types.yaml#/definitions/uint64 @@ -142,11 +138,58 @@ required: - interrupts - iommus - power-domains - - memory-region - - memory-region-names - apple,dart-vm-size - - apple,platform-id - - sensor-presets + +allOf: + - if: + properties: + compatible: + contains: + const: apple,t6041-isp + then: + properties: + power-domains: + items: + - description: ISP system domain + - description: ISP CPU domain + - description: ISP FE domain + - description: ISP DPRX domain + - description: ISP secure domain + - description: ISP BE domain + - description: ISP CLR domain + - description: Camera sensor domain + memory-region: + minItems: 3 + memory-region-names: + items: + - const: text + - const: data + - const: heap + required: + - memory-region + - memory-region-names + - apple,platform-id + - sensor-presets + else: + properties: + memory-region: + maxItems: 1 + memory-region-names: + items: + - const: heap + - if: + not: + properties: + status: + const: disabled + required: + - status + then: + required: + - memory-region + - memory-region-names + - apple,platform-id + - sensor-presets additionalProperties: false diff --git a/Documentation/devicetree/bindings/soc/apple/apple,rtk-helper-asc4.yaml b/Documentation/devicetree/bindings/soc/apple/apple,rtk-helper-asc4.yaml index 7b0d286ee03d7..138479a9e3561 100644 --- a/Documentation/devicetree/bindings/soc/apple/apple,rtk-helper-asc4.yaml +++ b/Documentation/devicetree/bindings/soc/apple/apple,rtk-helper-asc4.yaml @@ -4,55 +4,48 @@ $id: http://devicetree.org/schemas/soc/apple/apple,rtk-helper-asc4.yaml# $schema: http://devicetree.org/meta-schemas/core.yaml# -title: Apple ASC4 RTKit helper coprocessor +title: Apple RTKit ASC v4 transport helper maintainers: - - Ryan Murray - -description: - Apple SoCs contain a number of ASC coprocessors that run RTKit firmware. - For some of them the operating system only has to boot the coprocessor and - keep it running, while the devices it serves are described by other nodes. - The MTP (multi-touch processor) ASC of Apple laptops is one of these. It - serves the built-in keyboard and trackpad over DockChannel, and the - DockChannel HID transport refers to this node through its apple,helper-cpu - property. + - Ryan Murray <81541646+RyanTheTide@users.noreply.github.com> + +description: | + The MTP coprocessor provides firmware services used by the keyboard and + trackpad transport. A client refers to the helper to coordinate startup + through its RTKit mailbox. The helper has a control aperture, shared SRAM + and a DART stream. Firmware contents and boot configuration are supplied + by the bootloader. + +select: + properties: + compatible: + contains: + enum: + - apple,t6020-rtk-helper-asc4 + - apple,t8112-rtk-helper-asc4 + required: + - compatible properties: compatible: - items: - - enum: - - apple,t6020-mtp - - apple,t6030-mtp - - apple,t6031-mtp - - apple,t6041-mtp - - apple,t8112-mtp - - apple,t8122-mtp - - apple,t8132-mtp - - apple,t8140-mtp - - apple,t8142-mtp - - enum: - - apple,t6020-rtk-helper-asc4 - - apple,t6030-rtk-helper-asc4 - - apple,t6041-rtk-helper-asc4 - - apple,t8112-rtk-helper-asc4 - - apple,t8122-rtk-helper-asc4 - - apple,t8132-rtk-helper-asc4 - - apple,t8140-rtk-helper-asc4 - - apple,t8142-rtk-helper-asc4 - - const: apple,mtp - - const: apple,rtk-helper-asc4 + oneOf: + - items: + - const: apple,t6020-mtp + - const: apple,t6020-rtk-helper-asc4 + - const: apple,mtp + - const: apple,rtk-helper-asc4 + - items: + - const: apple,t8112-mtp + - const: apple,t8112-rtk-helper-asc4 + - const: apple,mtp + - const: apple,rtk-helper-asc4 reg: - minItems: 1 items: - - description: ASC control registers - - description: - Coprocessor SRAM, from which the firmware may ask the host to map - buffers instead of allocating them from system memory + - description: Coprocessor control registers + - description: Shared SRAM reg-names: - minItems: 1 items: - const: asc - const: sram @@ -63,64 +56,9 @@ properties: iommus: maxItems: 1 - apple,rtkit-handoff: - enum: - - mtp-live-v1 - description: | - The producer reserves firmware-visible buffers and retains their DART - mappings, and transfers a running RTKit session without renegotiation. - On T8132 it also supplies apple,rtkit-buffers, leaves the initial - DockChannel HID header unread, and retains the helper's identity DART - bypass. The host continues servicing system endpoints without restarting - the coprocessor or taking it to QUIESCED. - - apple,rtkit-buffers: - oneOf: - - type: boolean - - $ref: /schemas/types.yaml#/definitions/uint32-array - minItems: 5 - maxItems: 20 - description: | - An empty property records that no shared buffers were negotiated. - Otherwise this is the inventory of every shared buffer negotiated, - in groups of five cells: system endpoint number, device address high - cell, device address low cell, exact protocol size in bytes, and the - original request's is-mapped flag (0 or 1). Endpoint numbers are 1 for - crashlog, 2 for syslog, 4 for IOReport, and 8 for OSLog, each at most once. - The last cell records whether firmware supplied the original address; - it does not classify the backing memory as SRAM or DRAM. Device - addresses are physical addresses under the retained identity bypass. - SRAM buffers must lie inside the sram register resource. Every DRAM - buffer must lie inside a no-map reserved-memory region referenced by - memory-region. The inventory is installed before mailbox RX is enabled; - repeating an existing request cannot replace a live allocation. - - memory-region: - minItems: 1 - maxItems: 4 - description: - Reserved no-map DRAM buffers held by the running coprocessor. This - excludes buffers inside its SRAM register resource. - - linux-enablement-mac,rtkit-inherited: - deprecated: true - description: | - Legacy J713 preservation contract. An empty property or one 32-bit - cell containing 1 retains the running helper. A cell containing 0 - selects ordinary startup. This carries no buffer inventory or verified - reservation record; the consumer can service system notifications but - cannot reconstruct or replace the existing shared buffers. New - producers use mtp-live-v1 and may retain this marker for older kernels. - oneOf: - - type: boolean - - $ref: /schemas/types.yaml#/definitions/uint32 - enum: [0, 1] - '#helper-cells': const: 0 - description: - Present in existing device trees. Nothing references the helper with - argument cells; the DockChannel HID transport uses a plain phandle. + description: The helper reference has no arguments. required: - compatible @@ -128,34 +66,6 @@ required: - reg-names - mboxes - iommus - -allOf: - - if: - properties: - compatible: - contains: - const: apple,t8132-mtp - required: - - apple,rtkit-handoff - then: - required: - - apple,rtkit-buffers + - '#helper-cells' additionalProperties: false - -examples: - - | - soc { - #address-cells = <2>; - #size-cells = <2>; - - mtp@314600000 { - compatible = "apple,t8140-mtp", "apple,t8140-rtk-helper-asc4", - "apple,mtp", "apple,rtk-helper-asc4"; - reg = <0x3 0x14600000 0x0 0x4000>, - <0x3 0x14050000 0x0 0x4000>; - reg-names = "asc", "sram"; - mboxes = <&mtp_mbox>; - iommus = <&mtp_dart 0>; - }; - }; From abc199266199d18625a691cb1cd3e59f74730c45 Mon Sep 17 00:00:00 2001 From: Ryan Murray <81541646+RyanTheTide@users.noreply.github.com> Date: Sun, 8 Nov 2026 00:09:55 +1100 Subject: [PATCH 4/4] dt-bindings: apple: Correct the M2 resource variants and retain the shared helper Keep the established helper binding, preserve the modern ISP requirements, and match the register and interrupt resource facts of the M2 variants. Signed-off-by: Ryan Murray <81541646+RyanTheTide@users.noreply.github.com> Assisted-by: LLM --- .../edac/apple,soc-error-handler.yaml | 2 +- .../devicetree/bindings/media/apple,isp.yaml | 28 ++-- .../soc/apple/apple,rtk-helper-asc4.yaml | 158 ++++++++++++++---- .../boot/dts/apple/t8112-peripherals.dtsi | 2 +- 4 files changed, 140 insertions(+), 50 deletions(-) diff --git a/Documentation/devicetree/bindings/edac/apple,soc-error-handler.yaml b/Documentation/devicetree/bindings/edac/apple,soc-error-handler.yaml index fc8a94f5192ad..f954e69af5c82 100644 --- a/Documentation/devicetree/bindings/edac/apple,soc-error-handler.yaml +++ b/Documentation/devicetree/bindings/edac/apple,soc-error-handler.yaml @@ -50,7 +50,7 @@ properties: interrupts: minItems: 9 - maxItems: 255 + maxItems: 322 reg: minItems: 16 diff --git a/Documentation/devicetree/bindings/media/apple,isp.yaml b/Documentation/devicetree/bindings/media/apple,isp.yaml index 0b015b75ee4b8..8b3eb242358d6 100644 --- a/Documentation/devicetree/bindings/media/apple,isp.yaml +++ b/Documentation/devicetree/bindings/media/apple,isp.yaml @@ -10,10 +10,10 @@ maintainers: - Jonathan Goyvaerts description: - The ISP controls the attached camera sensor and processes its frames - through firmware the bootloader loads. The firmware segments are described - as reserved memory mapped at the addresses the firmware runs them at. The - host exchanges commands and image buffers through three DART instances. + The ISP controls the attached camera sensor and processes its frames using + a coprocessor. The host exchanges commands and image buffers through three + DART instances. The memory handoff identifies either the allocation heap or + separate firmware text, data and heap regions. select: properties: @@ -148,16 +148,16 @@ allOf: const: apple,t6041-isp then: properties: - power-domains: - items: - - description: ISP system domain - - description: ISP CPU domain - - description: ISP FE domain - - description: ISP DPRX domain - - description: ISP secure domain - - description: ISP BE domain - - description: ISP CLR domain - - description: Camera sensor domain + power-domains: + items: + - description: ISP system domain + - description: ISP CPU domain + - description: ISP FE domain + - description: ISP DPRX domain + - description: ISP secure domain + - description: ISP BE domain + - description: ISP CLR domain + - description: Camera sensor domain memory-region: minItems: 3 memory-region-names: diff --git a/Documentation/devicetree/bindings/soc/apple/apple,rtk-helper-asc4.yaml b/Documentation/devicetree/bindings/soc/apple/apple,rtk-helper-asc4.yaml index 138479a9e3561..7b0d286ee03d7 100644 --- a/Documentation/devicetree/bindings/soc/apple/apple,rtk-helper-asc4.yaml +++ b/Documentation/devicetree/bindings/soc/apple/apple,rtk-helper-asc4.yaml @@ -4,48 +4,55 @@ $id: http://devicetree.org/schemas/soc/apple/apple,rtk-helper-asc4.yaml# $schema: http://devicetree.org/meta-schemas/core.yaml# -title: Apple RTKit ASC v4 transport helper +title: Apple ASC4 RTKit helper coprocessor maintainers: - - Ryan Murray <81541646+RyanTheTide@users.noreply.github.com> - -description: | - The MTP coprocessor provides firmware services used by the keyboard and - trackpad transport. A client refers to the helper to coordinate startup - through its RTKit mailbox. The helper has a control aperture, shared SRAM - and a DART stream. Firmware contents and boot configuration are supplied - by the bootloader. - -select: - properties: - compatible: - contains: - enum: - - apple,t6020-rtk-helper-asc4 - - apple,t8112-rtk-helper-asc4 - required: - - compatible + - Ryan Murray + +description: + Apple SoCs contain a number of ASC coprocessors that run RTKit firmware. + For some of them the operating system only has to boot the coprocessor and + keep it running, while the devices it serves are described by other nodes. + The MTP (multi-touch processor) ASC of Apple laptops is one of these. It + serves the built-in keyboard and trackpad over DockChannel, and the + DockChannel HID transport refers to this node through its apple,helper-cpu + property. properties: compatible: - oneOf: - - items: - - const: apple,t6020-mtp - - const: apple,t6020-rtk-helper-asc4 - - const: apple,mtp - - const: apple,rtk-helper-asc4 - - items: - - const: apple,t8112-mtp - - const: apple,t8112-rtk-helper-asc4 - - const: apple,mtp - - const: apple,rtk-helper-asc4 + items: + - enum: + - apple,t6020-mtp + - apple,t6030-mtp + - apple,t6031-mtp + - apple,t6041-mtp + - apple,t8112-mtp + - apple,t8122-mtp + - apple,t8132-mtp + - apple,t8140-mtp + - apple,t8142-mtp + - enum: + - apple,t6020-rtk-helper-asc4 + - apple,t6030-rtk-helper-asc4 + - apple,t6041-rtk-helper-asc4 + - apple,t8112-rtk-helper-asc4 + - apple,t8122-rtk-helper-asc4 + - apple,t8132-rtk-helper-asc4 + - apple,t8140-rtk-helper-asc4 + - apple,t8142-rtk-helper-asc4 + - const: apple,mtp + - const: apple,rtk-helper-asc4 reg: + minItems: 1 items: - - description: Coprocessor control registers - - description: Shared SRAM + - description: ASC control registers + - description: + Coprocessor SRAM, from which the firmware may ask the host to map + buffers instead of allocating them from system memory reg-names: + minItems: 1 items: - const: asc - const: sram @@ -56,9 +63,64 @@ properties: iommus: maxItems: 1 + apple,rtkit-handoff: + enum: + - mtp-live-v1 + description: | + The producer reserves firmware-visible buffers and retains their DART + mappings, and transfers a running RTKit session without renegotiation. + On T8132 it also supplies apple,rtkit-buffers, leaves the initial + DockChannel HID header unread, and retains the helper's identity DART + bypass. The host continues servicing system endpoints without restarting + the coprocessor or taking it to QUIESCED. + + apple,rtkit-buffers: + oneOf: + - type: boolean + - $ref: /schemas/types.yaml#/definitions/uint32-array + minItems: 5 + maxItems: 20 + description: | + An empty property records that no shared buffers were negotiated. + Otherwise this is the inventory of every shared buffer negotiated, + in groups of five cells: system endpoint number, device address high + cell, device address low cell, exact protocol size in bytes, and the + original request's is-mapped flag (0 or 1). Endpoint numbers are 1 for + crashlog, 2 for syslog, 4 for IOReport, and 8 for OSLog, each at most once. + The last cell records whether firmware supplied the original address; + it does not classify the backing memory as SRAM or DRAM. Device + addresses are physical addresses under the retained identity bypass. + SRAM buffers must lie inside the sram register resource. Every DRAM + buffer must lie inside a no-map reserved-memory region referenced by + memory-region. The inventory is installed before mailbox RX is enabled; + repeating an existing request cannot replace a live allocation. + + memory-region: + minItems: 1 + maxItems: 4 + description: + Reserved no-map DRAM buffers held by the running coprocessor. This + excludes buffers inside its SRAM register resource. + + linux-enablement-mac,rtkit-inherited: + deprecated: true + description: | + Legacy J713 preservation contract. An empty property or one 32-bit + cell containing 1 retains the running helper. A cell containing 0 + selects ordinary startup. This carries no buffer inventory or verified + reservation record; the consumer can service system notifications but + cannot reconstruct or replace the existing shared buffers. New + producers use mtp-live-v1 and may retain this marker for older kernels. + oneOf: + - type: boolean + - $ref: /schemas/types.yaml#/definitions/uint32 + enum: [0, 1] + '#helper-cells': const: 0 - description: The helper reference has no arguments. + description: + Present in existing device trees. Nothing references the helper with + argument cells; the DockChannel HID transport uses a plain phandle. required: - compatible @@ -66,6 +128,34 @@ required: - reg-names - mboxes - iommus - - '#helper-cells' + +allOf: + - if: + properties: + compatible: + contains: + const: apple,t8132-mtp + required: + - apple,rtkit-handoff + then: + required: + - apple,rtkit-buffers additionalProperties: false + +examples: + - | + soc { + #address-cells = <2>; + #size-cells = <2>; + + mtp@314600000 { + compatible = "apple,t8140-mtp", "apple,t8140-rtk-helper-asc4", + "apple,mtp", "apple,rtk-helper-asc4"; + reg = <0x3 0x14600000 0x0 0x4000>, + <0x3 0x14050000 0x0 0x4000>; + reg-names = "asc", "sram"; + mboxes = <&mtp_mbox>; + iommus = <&mtp_dart 0>; + }; + }; diff --git a/arch/arm64/boot/dts/apple/t8112-peripherals.dtsi b/arch/arm64/boot/dts/apple/t8112-peripherals.dtsi index bd6f97b08b79c..45e9fea6e3f94 100644 --- a/arch/arm64/boot/dts/apple/t8112-peripherals.dtsi +++ b/arch/arm64/boot/dts/apple/t8112-peripherals.dtsi @@ -134,7 +134,7 @@ status = "disabled"; }; - m2_dockchannel_uart: serial@23d128000 { + m2_dockchannel_uart: serial@23d12c000 { compatible = "apple,t8112-dockchannel-uart", "apple,dockchannel-uart"; reg-names = "data", "config", "irq"; reg = <0x2 0x3d12c000 0x0 0x4000>,