1cb7aa33aSEmmanuel Vadot# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause) 2cb7aa33aSEmmanuel Vadot%YAML 1.2 3cb7aa33aSEmmanuel Vadot--- 4cb7aa33aSEmmanuel Vadot$id: http://devicetree.org/schemas/sound/microchip,sama7g5-i2smcc.yaml# 5cb7aa33aSEmmanuel Vadot$schema: http://devicetree.org/meta-schemas/core.yaml# 6cb7aa33aSEmmanuel Vadot 7cb7aa33aSEmmanuel Vadottitle: Microchip I2S Multi-Channel Controller 8cb7aa33aSEmmanuel Vadot 9cb7aa33aSEmmanuel Vadotmaintainers: 10cb7aa33aSEmmanuel Vadot - Codrin Ciubotariu <codrin.ciubotariu@microchip.com> 11cb7aa33aSEmmanuel Vadot 12cb7aa33aSEmmanuel Vadotdescription: 13cb7aa33aSEmmanuel Vadot The I2SMCC complies with the Inter-IC Sound (I2S) bus specification and 14cb7aa33aSEmmanuel Vadot supports a Time Division Multiplexed (TDM) interface with external 15cb7aa33aSEmmanuel Vadot multi-channel audio codecs. It consists of a receiver, a transmitter and a 16cb7aa33aSEmmanuel Vadot common clock generator that can be enabled separately to provide Adapter, 17cb7aa33aSEmmanuel Vadot Client or Controller modes with receiver and/or transmitter active. 18cb7aa33aSEmmanuel Vadot On later I2SMCC versions (starting with Microchip's SAMA7G5) I2S 19cb7aa33aSEmmanuel Vadot multi-channel is supported by using multiple data pins, output and 20cb7aa33aSEmmanuel Vadot input, without TDM. 21cb7aa33aSEmmanuel Vadot 22cb7aa33aSEmmanuel Vadotproperties: 23cb7aa33aSEmmanuel Vadot "#sound-dai-cells": 24cb7aa33aSEmmanuel Vadot const: 0 25cb7aa33aSEmmanuel Vadot 26cb7aa33aSEmmanuel Vadot compatible: 27*01950c46SEmmanuel Vadot oneOf: 28*01950c46SEmmanuel Vadot - enum: 29cb7aa33aSEmmanuel Vadot - microchip,sam9x60-i2smcc 30cb7aa33aSEmmanuel Vadot - microchip,sama7g5-i2smcc 31*01950c46SEmmanuel Vadot - items: 32*01950c46SEmmanuel Vadot - enum: 33*01950c46SEmmanuel Vadot - microchip,sam9x7-i2smcc 34*01950c46SEmmanuel Vadot - const: microchip,sam9x60-i2smcc 35cb7aa33aSEmmanuel Vadot 36cb7aa33aSEmmanuel Vadot reg: 37cb7aa33aSEmmanuel Vadot maxItems: 1 38cb7aa33aSEmmanuel Vadot 39cb7aa33aSEmmanuel Vadot interrupts: 40cb7aa33aSEmmanuel Vadot maxItems: 1 41cb7aa33aSEmmanuel Vadot 42cb7aa33aSEmmanuel Vadot clocks: 43cb7aa33aSEmmanuel Vadot items: 44cb7aa33aSEmmanuel Vadot - description: Peripheral Bus Clock 45cb7aa33aSEmmanuel Vadot - description: Generic Clock (Optional). Should be set mostly when Master 46cb7aa33aSEmmanuel Vadot Mode is required. 47cb7aa33aSEmmanuel Vadot minItems: 1 48cb7aa33aSEmmanuel Vadot 49cb7aa33aSEmmanuel Vadot clock-names: 50cb7aa33aSEmmanuel Vadot items: 51cb7aa33aSEmmanuel Vadot - const: pclk 52cb7aa33aSEmmanuel Vadot - const: gclk 53cb7aa33aSEmmanuel Vadot minItems: 1 54cb7aa33aSEmmanuel Vadot 55cb7aa33aSEmmanuel Vadot dmas: 56cb7aa33aSEmmanuel Vadot items: 57cb7aa33aSEmmanuel Vadot - description: TX DMA Channel 58cb7aa33aSEmmanuel Vadot - description: RX DMA Channel 59cb7aa33aSEmmanuel Vadot 60cb7aa33aSEmmanuel Vadot dma-names: 61cb7aa33aSEmmanuel Vadot items: 62cb7aa33aSEmmanuel Vadot - const: tx 63cb7aa33aSEmmanuel Vadot - const: rx 64cb7aa33aSEmmanuel Vadot 65cb7aa33aSEmmanuel Vadot microchip,tdm-data-pair: 66cb7aa33aSEmmanuel Vadot description: 67cb7aa33aSEmmanuel Vadot Represents the DIN/DOUT pair pins that are used to receive/send 68cb7aa33aSEmmanuel Vadot TDM data. It is optional and it is only needed if the controller 69cb7aa33aSEmmanuel Vadot uses the TDM mode. 70cb7aa33aSEmmanuel Vadot $ref: /schemas/types.yaml#/definitions/uint8 71cb7aa33aSEmmanuel Vadot enum: [0, 1, 2, 3] 72cb7aa33aSEmmanuel Vadot default: 0 73cb7aa33aSEmmanuel Vadot 74cb7aa33aSEmmanuel VadotallOf: 75cb7aa33aSEmmanuel Vadot - $ref: dai-common.yaml# 76cb7aa33aSEmmanuel Vadot - if: 77cb7aa33aSEmmanuel Vadot properties: 78cb7aa33aSEmmanuel Vadot compatible: 79cb7aa33aSEmmanuel Vadot const: microchip,sam9x60-i2smcc 80cb7aa33aSEmmanuel Vadot then: 81cb7aa33aSEmmanuel Vadot properties: 82cb7aa33aSEmmanuel Vadot microchip,tdm-data-pair: false 83cb7aa33aSEmmanuel Vadot 84cb7aa33aSEmmanuel Vadotrequired: 85cb7aa33aSEmmanuel Vadot - "#sound-dai-cells" 86cb7aa33aSEmmanuel Vadot - compatible 87cb7aa33aSEmmanuel Vadot - reg 88cb7aa33aSEmmanuel Vadot - interrupts 89cb7aa33aSEmmanuel Vadot - clocks 90cb7aa33aSEmmanuel Vadot - clock-names 91cb7aa33aSEmmanuel Vadot - dmas 92cb7aa33aSEmmanuel Vadot - dma-names 93cb7aa33aSEmmanuel Vadot 94cb7aa33aSEmmanuel VadotunevaluatedProperties: false 95cb7aa33aSEmmanuel Vadot 96cb7aa33aSEmmanuel Vadotexamples: 97cb7aa33aSEmmanuel Vadot - | 98cb7aa33aSEmmanuel Vadot #include <dt-bindings/dma/at91.h> 99cb7aa33aSEmmanuel Vadot #include <dt-bindings/interrupt-controller/arm-gic.h> 100cb7aa33aSEmmanuel Vadot 101cb7aa33aSEmmanuel Vadot i2s@f001c000 { 102cb7aa33aSEmmanuel Vadot #sound-dai-cells = <0>; 103cb7aa33aSEmmanuel Vadot compatible = "microchip,sam9x60-i2smcc"; 104cb7aa33aSEmmanuel Vadot reg = <0xf001c000 0x100>; 105cb7aa33aSEmmanuel Vadot interrupts = <34 IRQ_TYPE_LEVEL_HIGH 7>; 106cb7aa33aSEmmanuel Vadot dmas = <&dma0 (AT91_XDMAC_DT_MEM_IF(0) | AT91_XDMAC_DT_PER_IF(1) | 107cb7aa33aSEmmanuel Vadot AT91_XDMAC_DT_PERID(36))>, 108cb7aa33aSEmmanuel Vadot <&dma0 (AT91_XDMAC_DT_MEM_IF(0) | AT91_XDMAC_DT_PER_IF(1) | 109cb7aa33aSEmmanuel Vadot AT91_XDMAC_DT_PERID(37))>; 110cb7aa33aSEmmanuel Vadot dma-names = "tx", "rx"; 111cb7aa33aSEmmanuel Vadot clocks = <&i2s_clk>, <&i2s_gclk>; 112cb7aa33aSEmmanuel Vadot clock-names = "pclk", "gclk"; 113cb7aa33aSEmmanuel Vadot pinctrl-names = "default"; 114cb7aa33aSEmmanuel Vadot pinctrl-0 = <&pinctrl_i2s_default>; 115cb7aa33aSEmmanuel Vadot }; 116