Hi,
I use the CPU of iMX7d on Linux 4.9.11 on Yocto platform. My device tree extracts as follows. The file name is imx7d-sdb.dts. The WCLK is 48KHz, it is correct. The BCLK is 1.536MHz, it is incorrect. I want to change BCLK to 3.072MHz. How to change it? Thank you very much.
simple-audio-card,dai-link@1 {
format = "i2s";
bitclock-master = <&dailink1_master>;
frame-master = <&dailink1_master>;
dailink1_master: cpu {
sound-dai = <&sai3>;
system-clock-direction = "out";
system-clock-frequency = <12288000>;
};
codec {
sound-dai = <&cx2092x>;
system-clock-direction = "in";
system-clock-frequency = <12288000>;
};
};
&sai3 {
#sound-dai-cells = <0>;
pinctrl-names = "default";
pinctrl-0 = <&pinctrl_sai3 &pinctrl_sai3_mclk>;
assigned-clocks = <&clks IMX7D_SAI3_ROOT_SRC>,
<&clks IMX7D_SAI3_ROOT_CLK>;
assigned-clock-parents = <&clks IMX7D_PLL_AUDIO_POST_DIV>;
assigned-clock-rates = <0>, <36864000>;
status = "okay";
};
Hi igor,
Thanks, but there is some error messages as follows if I change IMX7D_SAI3_ROOT_SRC to IMX7D_AUDIO_MCLK_ROOT_SRC.
I use the command is "arecord -f S16_LE -r 48000 test.wav".
Error message:
fsl-sai 308c0000.sai: failed to derive required Rx rate: 1536000
fsl-sai 308c0000.sai: ASoC: can't set 308c0000.sai hw params: -22
&sai3 {
#sound-dai-cells = <0>;
pinctrl-names = "default";
pinctrl-0 = <&pinctrl_sai3 &pinctrl_sai3_mclk>;
assigned-clocks = <&clks IMX7D_AUDIO_MCLK_ROOT_SRC>,
<&clks IMX7D_SAI3_ROOT_CLK>;
assigned-clock-parents = <&clks IMX7D_PLL_AUDIO_POST_DIV>;
assigned-clock-rates = <0>, <36864000>;
status = "okay";
};
Best regards
Ted
Hi Ted
could you try with nxp bsp
linux-imx.git - i.MX Linux Kernel
description can be found on
Best regards
igor
Hi Ted
one can try to add
assigned-clocks = <&clks IMX7D_AUDIO_MCLK_ROOT_SRC>,
as in linux/arch/arm/boot/dts/imx7d-sdb.dts example
linux-imx.git - i.MX Linux Kernel
Best regards
igor
-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------