Hello,
I try to get working an AKM4556 codec on the arm64 Rockchip RK3399 board
under Linux 4.4.179
The codec is a simple one (without i2c connection), similar to AKM4554
(but 24 bit instead of 16 bit audio) and hard configured to use i2s.
I implemented the driver soc/codecs/ak4556.c which has only few
differences to ak4554.c.
But when I try to get it working with the soc/general/simple-card.c, the
connection to the codec fails
Both drivers (snd_soc_simple_card and snd_soc_ak4556) get loaded, the
call to
asoc_simple_card_dai_link_of -> asoc_simple_card_sub_parse_of(cpu, ..)
is OK, but the call to
asoc_simple_card_dai_link_of -> asoc_simple_card_sub_parse_of(codec, ..)
-> snd_soc_of_get_dai_name
fails with -EPROBE_DEFER.
Now, i am not sure if it is a driver issue or rather a device-tree one.
I declared dt like this :
/ {
ak4556_card: ak4556-adc-dac {
status = "okay";
compatible = "simple-audio-card";
simple-audio-card,name = "ak4556";
simple-audio-card,format = "i2s";
simple-audio-card,mclk-fs = <256>;
simple-audio-card,widgets =
"Line", "Line In",
"Line", "Line Out";
simple-audio-card,routing =
"LIN", "Line In",
"RIN", "Line In",
"Line Out", "LOUT",
"Line Out", "ROUT";
simple-audio-card,cpu {
sound-dai = <&i2s0>;
};
simple-audio-card,codec {
sound-dai = <&ak4556_codec>;
};
};
ak4556_codec: ak4556-codec {
status = "okay";
compatible = "asahi-kasei,ak4556";
#sound-dai-cells = <0>;
};
i2s0: i2s@ff880000 {
compatible = "rockchip,rk3399-i2s", "rockchip,rk3066-i2s";
reg = <0x0 0xff880000 0x0 0x1000>;
rockchip,grf = <&grf>;
interrupts = <GIC_SPI 39 IRQ_TYPE_LEVEL_HIGH 0>;
dmas = <&dmac_bus 0>, <&dmac_bus 1>;
dma-names = "tx", "rx";
clock-names = "i2s_clk", "i2s_hclk";
clocks = <&cru SCLK_I2S0_8CH>, <&cru HCLK_I2S0_8CH>;
resets = <&cru SRST_I2S0_8CH>, <&cru SRST_H_I2S0_8CH>;
reset-names = "reset-m", "reset-h";
pinctrl-names = "default";
pinctrl-0 = <&i2s0_8ch_bus>;
power-domains = <&power RK3399_PD_SDIOAUDIO>;
status = "disabled";
};
&i2s0 {
#sound-dai-cells = <0>;
assigned-clocks = <&cru SCLK_I2S0_DIV>;
assigned-clock-parents = <&cru PLL_GPLL>;
status = "okay";
};
Thank you in advance for your suggestions,
Markus