162306a36Sopenharmony_ciFreescale Asynchronous Sample Rate Converter (ASRC) Controller 262306a36Sopenharmony_ci 362306a36Sopenharmony_ciThe Asynchronous Sample Rate Converter (ASRC) converts the sampling rate of a 462306a36Sopenharmony_cisignal associated with an input clock into a signal associated with a different 562306a36Sopenharmony_cioutput clock. The driver currently works as a Front End of DPCM with other Back 662306a36Sopenharmony_ciEnds Audio controller such as ESAI, SSI and SAI. It has three pairs to support 762306a36Sopenharmony_cithree substreams within totally 10 channels. 862306a36Sopenharmony_ci 962306a36Sopenharmony_ciRequired properties: 1062306a36Sopenharmony_ci 1162306a36Sopenharmony_ci - compatible : Compatible list, should contain one of the following 1262306a36Sopenharmony_ci compatibles: 1362306a36Sopenharmony_ci "fsl,imx35-asrc", 1462306a36Sopenharmony_ci "fsl,imx53-asrc", 1562306a36Sopenharmony_ci "fsl,imx8qm-asrc", 1662306a36Sopenharmony_ci "fsl,imx8qxp-asrc", 1762306a36Sopenharmony_ci 1862306a36Sopenharmony_ci - reg : Offset and length of the register set for the device. 1962306a36Sopenharmony_ci 2062306a36Sopenharmony_ci - interrupts : Contains the spdif interrupt. 2162306a36Sopenharmony_ci 2262306a36Sopenharmony_ci - dmas : Generic dma devicetree binding as described in 2362306a36Sopenharmony_ci Documentation/devicetree/bindings/dma/dma.txt. 2462306a36Sopenharmony_ci 2562306a36Sopenharmony_ci - dma-names : Contains "rxa", "rxb", "rxc", "txa", "txb" and "txc". 2662306a36Sopenharmony_ci 2762306a36Sopenharmony_ci - clocks : Contains an entry for each entry in clock-names. 2862306a36Sopenharmony_ci 2962306a36Sopenharmony_ci - clock-names : Contains the following entries 3062306a36Sopenharmony_ci "mem" Peripheral access clock to access registers. 3162306a36Sopenharmony_ci "ipg" Peripheral clock to driver module. 3262306a36Sopenharmony_ci "asrck_<0-f>" Clock sources for input and output clock. 3362306a36Sopenharmony_ci "spba" The spba clock is required when ASRC is placed as a 3462306a36Sopenharmony_ci bus slave of the Shared Peripheral Bus and when two 3562306a36Sopenharmony_ci or more bus masters (CPU, DMA or DSP) try to access 3662306a36Sopenharmony_ci it. This property is optional depending on the SoC 3762306a36Sopenharmony_ci design. 3862306a36Sopenharmony_ci 3962306a36Sopenharmony_ci - fsl,asrc-rate : Defines a mutual sample rate used by DPCM Back Ends. 4062306a36Sopenharmony_ci 4162306a36Sopenharmony_ci - fsl,asrc-width : Defines a mutual sample width used by DPCM Back Ends. 4262306a36Sopenharmony_ci 4362306a36Sopenharmony_ci - fsl,asrc-clk-map : Defines clock map used in driver. which is required 4462306a36Sopenharmony_ci by imx8qm/imx8qxp platform 4562306a36Sopenharmony_ci <0> - select the map for asrc0 in imx8qm/imx8qxp 4662306a36Sopenharmony_ci <1> - select the map for asrc1 in imx8qm/imx8qxp 4762306a36Sopenharmony_ci 4862306a36Sopenharmony_ciOptional properties: 4962306a36Sopenharmony_ci 5062306a36Sopenharmony_ci - big-endian : If this property is absent, the little endian mode 5162306a36Sopenharmony_ci will be in use as default. Otherwise, the big endian 5262306a36Sopenharmony_ci mode will be in use for all the device registers. 5362306a36Sopenharmony_ci 5462306a36Sopenharmony_ci - fsl,asrc-format : Defines a mutual sample format used by DPCM Back 5562306a36Sopenharmony_ci Ends, which can replace the fsl,asrc-width. 5662306a36Sopenharmony_ci The value is 2 (S16_LE), or 6 (S24_LE). 5762306a36Sopenharmony_ci 5862306a36Sopenharmony_ciExample: 5962306a36Sopenharmony_ci 6062306a36Sopenharmony_ciasrc: asrc@2034000 { 6162306a36Sopenharmony_ci compatible = "fsl,imx53-asrc"; 6262306a36Sopenharmony_ci reg = <0x02034000 0x4000>; 6362306a36Sopenharmony_ci interrupts = <0 50 IRQ_TYPE_LEVEL_HIGH>; 6462306a36Sopenharmony_ci clocks = <&clks 107>, <&clks 107>, <&clks 0>, 6562306a36Sopenharmony_ci <&clks 0>, <&clks 0>, <&clks 0>, <&clks 0>, 6662306a36Sopenharmony_ci <&clks 0>, <&clks 0>, <&clks 0>, <&clks 0>, 6762306a36Sopenharmony_ci <&clks 0>, <&clks 0>, <&clks 0>, <&clks 0>, 6862306a36Sopenharmony_ci <&clks 107>, <&clks 0>, <&clks 0>; 6962306a36Sopenharmony_ci clock-names = "mem", "ipg", "asrck0", 7062306a36Sopenharmony_ci "asrck_1", "asrck_2", "asrck_3", "asrck_4", 7162306a36Sopenharmony_ci "asrck_5", "asrck_6", "asrck_7", "asrck_8", 7262306a36Sopenharmony_ci "asrck_9", "asrck_a", "asrck_b", "asrck_c", 7362306a36Sopenharmony_ci "asrck_d", "asrck_e", "asrck_f"; 7462306a36Sopenharmony_ci dmas = <&sdma 17 23 1>, <&sdma 18 23 1>, <&sdma 19 23 1>, 7562306a36Sopenharmony_ci <&sdma 20 23 1>, <&sdma 21 23 1>, <&sdma 22 23 1>; 7662306a36Sopenharmony_ci dma-names = "rxa", "rxb", "rxc", 7762306a36Sopenharmony_ci "txa", "txb", "txc"; 7862306a36Sopenharmony_ci fsl,asrc-rate = <48000>; 7962306a36Sopenharmony_ci fsl,asrc-width = <16>; 8062306a36Sopenharmony_ci}; 81