device tree setup &sai1 for Simple Sound Card at MX8UX6AVLFZAC as slave

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

device tree setup &sai1 for Simple Sound Card at MX8UX6AVLFZAC as slave

1,344件の閲覧回数
boris_schmidt
Contributor II

Hello does any one know how to setup wm8960 codec (Raspi HAT)  with 24MHz oscillator as SAI1 master.

Clock driver is wm8960; so no mlck out of iMX8 is needed;

There is now dts document how to setup SAI for iMX8; there are some iMX8 with DSP and others have only SAI (no DSP).

I do not need the DSP.

How to assign clock and PLL of SAI1 ?
i2S Slave               i2S Master
iMX8                      WM8960
CLK   <-                 CLK
FS     <-                 FS 
RX    <-                  TX      : 2xMIC L/R
TX   ->                    RX     : 2xSpeaker L/R




スポイラ
[ 2.685173] clk: failed to reparent audio_pll0_clk to aud_pll_div_clk0_lpcg_clk: -22
[ 2.703444] imx-audmix imx-audmix.0: failed to find SAI platform device
[ 2.710412] imx-audmix: probe of imx-audmix.0 failed with error -22
スポイラ

sound {
compatible = "simple-audio-card";
simple-audio-card,format = "i2s";
simple-audio-card,bitclock-master = <&dailink0_master>;
simple-audio-card,frame-master = <&dailink0_master>;
simple-audio-card,widgets =
"Microphone", "Microphone Jack",
"Headphone", "Headphone Jack",
"Speaker", "Speaker Ext",
"Line", "Line In Jack";
simple-audio-card,routing =
"MIC_IN", "Microphone Jack",
"Microphone Jack", "Mic Bias",
"LINE_IN", "Line In Jack",
"Headphone Jack", "HP_OUT",
"Speaker Ext", "LINE_OUT";

simple-audio-card,cpu {
sound-dai = <&sai1>;
frame-master;
bitclock-master;
};

dailink0_master: simple-audio-card,codec {
sound-dai = <&wm8960>;
frame-master;
bitclock-master;
system-clock-frequency = <24000000>;
};

};
};

&amix {
status = "okay";
};

&sai1 {
#sound-dai-cells = <0>;
pinctrl-names = "default";
pinctrl-0 = <&pinctrl_sai1>;
clock-names = "ipg", "ocram", "core",
"sai1_bus", "sai1_mclk0", "sai1_mclk1", "sai1_mclk2", "sai1_mclk3";
clocks = <&clk_dummy>, <&clk_dummy>, <&clk_dummy>,
<&sai1_lpcg 1>, <&clk_dummy>, <&sai1_lpcg 0>,
<&clk_dummy>, <&clk_dummy>;
assigned-clocks = <&clk IMX_SC_R_AUDIO_PLL_0 IMX_SC_PM_CLK_PLL>,
<&clk IMX_SC_R_AUDIO_PLL_0 IMX_SC_PM_CLK_SLV_BUS>,
<&clk IMX_SC_R_AUDIO_PLL_0 IMX_SC_PM_CLK_MST_BUS>,
<&sai1_lpcg 0>; /* FIXME: should be sai1, original code is 0 */
//assigned-clocks = <&clk IMX8MQ_CLK_SAI3>;
//assigned-clock-parents = <&clk IMX8MQ_AUDIO_PLL1_OUT>;
//assigned-clock-rates = <24576000>;
//assigned-clocks = <&clk IMX8MQ_CLK_DUMMY>;
assigned-clock-parents = <&aud_pll_div0_lpcg 0>;
assigned-clock-rates = <0>, <786432000>, <49152000>, <12288000>, <49152000>;
status = "okay";
};

 





ラベル(1)
0 件の賞賛
返信
1 返信

1,317件の閲覧回数
jimmychan
NXP TechSupport
NXP TechSupport
0 件の賞賛
返信