Re: Query on audio-graph-card DT binding

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 





On 09-01-2024 07:47, Kuninori Morimoto wrote:
               /-----> codec1 endpoint
              /
CPU endpoint \
               \-----> codec2 endpoint
It sounds "Single CPU - Mult Codec" connection, and if my understanding
was correct, current ASoC is not supporting it so far.

Yes, this is a typical TDM use case. The core loops over all codecs for a given rtd. Please see, https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/sound/soc/soc-pcm.c?h=v6.7#n1013
So latter part of your above comment is not clear to me.

But dummy CPU with Multi-CPU/Codec connection helps you ?
I'm not 100% sure though...
See
         ${LINUX}/sound/soc/generic/audio-graph-card2-custom-sample.dtsi

DT looks like

         [Multi-CPU/Codec]
                          +-+             +-+
                 cpu   <--| |<-@--------->| |-> codec1
                 dummy <--| |             | |-> codec2
                          +-+             +-+

Use Multi-CPU/Codec connection with dummy.

         audio-graph-card2 {
                 compatible = "audio-graph-card2";
                 links = <&mcpu>;

                 multi {
                         ports@0 {
                         /* [Multi-CPU] */
                         mcpu:   port@0 { mcpu0_ep: endpoint { remote-endpoint = <&mcodec0_ep>; }; };
                                 port@1 { mcpu1_ep: endpoint { remote-endpoint = <&cpu_ep>;     }; };
                                 port@2 { mcpu2_ep: endpoint { remote-endpoint = <&dummy_ep>;   }; };
                         };

                         /* [Multi-Codec] */
                         ports@1 {
                                 port@0 { mcodec0_ep: endpoint { remote-endpoint = <&mcpu0_ep>;  }; };
                                 port@1 { mcodec1_ep: endpoint { remote-endpoint = <&codec1_ep>; }; };
                                 port@2 { mcodec2_ep: endpoint { remote-endpoint = <&codec2_ep>; }; };
                         };
                 };
         };

         test_cpu {
                 compatible = "test-cpu";
                 port { dummy_ep: endpoint { remote-endpoint = <&mcpu2_ep>; }; };
         };

I looked at the 1:N (Semi-Multi) example in the references you shared. Seems like this is broken into multiple 1:1 links. Is this correct understanding?

Also the binding properties of "audio-graph-card2" seem to be different from "audio-graph-card". I am looking at a simpler extension of existing bindings for Tegra audio without having to re-write the whole bindings. If "remote-endpoint" can take phandle array it would be simpler from DT point of view.




[Index of Archives]     [ALSA User]     [Linux Audio Users]     [Pulse Audio]     [Kernel Archive]     [Asterisk PBX]     [Photo Sharing]     [Linux Sound]     [Video 4 Linux]     [Gimp]     [Yosemite News]

  Powered by Linux