Hi
We are adding an audio codec to our design NX module design. I have created the device tree, but having a problem the assignment of #sound-dai-cells = <?>
We are using i2s as shown below:
tegra_i2s3: i2s@2901200 {
compatible = “nvidia,tegra210-i2s”;
reg = <0x0 0x2901200 0x0 0x100>;
nvidia,ahub-i2s-id = <2>;
clocks = <&bpmp_clks TEGRA194_CLK_I2S3>,
<&bpmp_clks TEGRA194_CLK_PLLA_OUT0>,
<&bpmp_clks TEGRA194_CLK_I2S3_SYNC_INPUT>,
<&bpmp_clks TEGRA194_CLK_SYNC_I2S3>,
<&bpmp_clks TEGRA194_CLK_I2S3_SYNC_INPUT>;
clock-names = “i2s”, “i2s_clk_parent”, “ext_audio_sync”,
“audio_sync”, “clk_sync_input”;
assigned-clocks =
<&bpmp_clks TEGRA194_CLK_I2S3>;
assigned-clock-parents =
<&bpmp_clks TEGRA194_CLK_PLLA_OUT0>;
assigned-clock-rates = <1536000>;
fsync-width = <31>;
status = “disabled”;
};
I am including the above definition (tegra_i2s3) into the following sound node (see the ***):
mysound {
compatible = “simple-audio-card”;
simple-audio-card,name = “My-Sound-Card”;
simple-audio-card,format = “i2s”;
simple-audio-card,widgets =
“Microphone”, “Microphone Jack”,
“Headphone”, “Headphone Jack”,
“Speaker”, “External Speaker”;
simple-audio-card,routing =
“MIC_IN”, “Microphone Jack”,
“Headphone Jack”, “HP_OUT”,
“External Speaker”, “LINE_OUT”;
dai-tdm-slot-num = <2>;
dai-tdm-slot-width = <8>;
/* CPU DAI interface */
simple-audio-card,cpu {
#sound-dai-cells = <1>;
***sound-dai = <&tegra_i2s3>; //This is the I2S interface***
system-clock-frequency = <19200000>;
};
/* Codec interface */
simple-audio-card,codec {
sound-dai = <&headset0>;
bitclock-master;
frame-master;
clocks = <11289600>; // mdm <&osc>;
};
During boot, the following error is found in dmesg:
[ 5.773335] OF: /mysound/simple-audio-card,cpu: arguments longer than property
[ 5.779252] asoc-simple-card mysound: parse error -22
[ 5.784418] asoc-simple-card: probe of mysound failed with error -22
I have tried changing the value in the statement “#sound-dai-cells = <1>;” from 3 to 1 then 2 and also 4, but the above error persists.
Can you provide help on the assignment of the #sound-dai-cells?
Is the structure of my device tree correct to assign the i2s bus to the mysound property?
Thanks,
Malcolm