linux-loongson/Documentation/devicetree/bindings/sound/fsl,xcvr.yaml
Krzysztof Kozlowski fffe003fc2
ASoC: dt-bindings: Correct indentation and style in DTS example
DTS example in the bindings should be indented with 2- or 4-spaces and
aligned with opening '- |', so correct any differences like 3-spaces or
mixtures 2- and 4-spaces in one binding.  While touching the lines do
other non-functional changes: replace raw number with proper define for
GPIO flag and use generic node name.

No functional changes here, but saves some comments during reviews of
new patches built on existing code.

Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Link: https://patch.msgid.link/20250107125901.227995-1-krzysztof.kozlowski@linaro.org
Signed-off-by: Mark Brown <broonie@kernel.org>
2025-01-07 14:28:08 +00:00

161 lines
3.6 KiB
YAML

# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
%YAML 1.2
---
$id: http://devicetree.org/schemas/sound/fsl,xcvr.yaml#
$schema: http://devicetree.org/meta-schemas/core.yaml#
title: NXP Audio Transceiver (XCVR) Controller
maintainers:
- Viorel Suman <viorel.suman@nxp.com>
description: |
NXP XCVR (Audio Transceiver) is a on-chip functional module
that allows CPU to receive and transmit digital audio via
HDMI2.1 eARC, HDMI1.4 ARC and SPDIF.
properties:
$nodename:
pattern: "^xcvr@.*"
compatible:
enum:
- fsl,imx8mp-xcvr
- fsl,imx93-xcvr
- fsl,imx95-xcvr
reg:
items:
- description: 20K RAM for code and data
- description: registers space
- description: RX FIFO address
- description: TX FIFO address
reg-names:
items:
- const: ram
- const: regs
- const: rxfifo
- const: txfifo
interrupts:
items:
- description: WAKEUPMIX Audio XCVR Interrupt 1
- description: WAKEUPMIX Audio XCVR Interrupt 2
- description: SPDIF wakeup interrupt from PHY
minItems: 1
clocks:
items:
- description: Peripheral clock
- description: PHY clock
- description: SPBA clock
- description: PLL clock
- description: PLL clock source for 8kHz series
- description: PLL clock source for 11kHz series
minItems: 4
clock-names:
items:
- const: ipg
- const: phy
- const: spba
- const: pll_ipg
- const: pll8k
- const: pll11k
minItems: 4
dmas:
items:
- description: DMA controller phandle and request line for RX
- description: DMA controller phandle and request line for TX
dma-names:
items:
- const: rx
- const: tx
resets:
maxItems: 1
required:
- compatible
- reg
- reg-names
- interrupts
- clocks
- clock-names
- dmas
- dma-names
allOf:
- $ref: dai-common.yaml#
- if:
properties:
compatible:
contains:
const: fsl,imx8mp-xcvr
then:
required:
- resets
- if:
properties:
compatible:
contains:
enum:
- fsl,imx93-xcvr
- fsl,imx95-xcvr
then:
properties:
interrupts:
minItems: 2
maxItems: 2
else:
properties:
interrupts:
minItems: 3
maxItems: 3
- if:
properties:
compatible:
contains:
enum:
- fsl,imx8mp-xcvr
- fsl,imx93-xcvr
then:
properties:
clocks:
maxItems: 4
clock-names:
maxItems: 4
unevaluatedProperties: false
examples:
- |
#include <dt-bindings/interrupt-controller/arm-gic.h>
#include <dt-bindings/clock/imx8mp-clock.h>
#include <dt-bindings/reset/imx8mp-reset.h>
xcvr: xcvr@30cc0000 {
compatible = "fsl,imx8mp-xcvr";
reg = <0x30cc0000 0x800>,
<0x30cc0800 0x400>,
<0x30cc0c00 0x080>,
<0x30cc0e00 0x080>;
reg-names = "ram", "regs", "rxfifo", "txfifo";
interrupts = <GIC_SPI 128 IRQ_TYPE_LEVEL_HIGH>,
<GIC_SPI 129 IRQ_TYPE_LEVEL_HIGH>,
<GIC_SPI 146 IRQ_TYPE_LEVEL_HIGH>;
clocks = <&audiomix_clk IMX8MP_CLK_AUDIOMIX_EARC_IPG>,
<&audiomix_clk IMX8MP_CLK_AUDIOMIX_EARC_PHY>,
<&audiomix_clk IMX8MP_CLK_AUDIOMIX_SPBA2_ROOT>,
<&audiomix_clk IMX8MP_CLK_AUDIOMIX_AUDPLL_ROOT>;
clock-names = "ipg", "phy", "spba", "pll_ipg";
dmas = <&sdma2 30 2 0>, <&sdma2 31 2 0>;
dma-names = "rx", "tx";
resets = <&audiomix_reset 0>;
};