Hello,
I am trying to implement the TLV320AIC3262 with the Ambarella CV25 codec in Linux. I found the Linux driver here: /cfs-file/__key/communityserver-discussions-components-files/6/3262_2D00_E2E.zip. This seems to be the latest version that I could find for the driver. My Linux kernel version is 5.4.120.
DTS file:
i2c0: i2c@e4008000 { status = "ok"; pwms = <&pwm2 0 37 0>; ambvin0@01 { compatible = "ambarella,ambvin"; reg = <0x01>; }; tlv320aic3262: codec@18 { compatible = "tlv320aic3262-codec"; #sound-dai-cells = <0>; reg = <0x18>; status = "ok"; }; }; i2s0: i2s@e001d000 { amb,i2s-channels = <4>; }; sound { compatible = "simple-audio-card"; simple-audio-card,name = "tlv320aic3262 @ CV25"; simple-audio-card,widgets = "Microphone", "Left Mic", "Microphone", "Right Mic", "Speaker", "Ext Speaker"; simple-audio-card,routing = "IN2 Left Capture", "Left Mic", "IN2 Right Capture", "Right Mic", "Ext Speaker", "SPK Left Playback"; simple-audio-card,format = "i2s"; simple-audio-card,bitclock-master = <&dailink0_master>; simple-audio-card,frame-master = <&dailink0_master>; dailink0_master: simple-audio-card,cpu { sound-dai = <&i2s0>; }; simple-audio-card,codec { sound-dai = <&tlv320aic3262>; }; };
Debug logs after enabling sound module:
[ 136.785199] tlv320aic3262-codec 0-0018: aic3xxx_device_init beginning [ 136.791746] tlv320aic3262-codec 0-0018: aic3xxx_i2c_probe:97: Failed to init device: -22 [ 136.800610] driver_init: Allocated Major Number: 246 [ 136.809449] driver_init: Registered cfw driver [ 136.897776] ------------[ cut here ]------------ [ 136.902392] codec tlv320aic3262-codec.0-0018 can not start from non-off bias with idle_bias_off==1 [ 136.911443] WARNING: CPU: 2 PID: 21 at sound/soc/soc-core.c:1055 soc_probe_component+0x2b0/0x3b0 [snd_soc_core] [ 136.921498] Modules linked in: snd_soc_tlv320aic326x_amb mfd_core rfkill spidev ambad(O) ehci_ambarella snd_soc_simple_card snd_soc_simple_card_utils ehci_hcd snd_soc_ambarella_i2s snd_soc_ambdummy snd_soc_ambarella ambarella_eth cavalry(O) usbcore of_mdio snd_soc_core snd_pcm_dmaengine rtc_ambarella snd_pcm imgproc(O) usb_f_ecm dsp(O) ambarella_fb syscopyarea fixed_phy pwm_ambarella snd_timer snd sysfillrect libphy ambnl(O) soundcore spi_ambarella ambarella_udc hw_timer(O) sysimgblt ambcma(O) g_ether usb_f_rndis u_ether libcomposite fuse [ 136.969182] CPU: 2 PID: 21 Comm: kworker/2:0 Tainted: G O 5.4.120 #29 [ 136.976895] Hardware name: Brivo CV25 Cerberus Board (DT) [ 136.982283] Workqueue: events deferred_probe_work_func [ 136.987401] pstate: 60000005 (nZCv daif -PAN -UAO) [ 136.992186] pc : soc_probe_component+0x2b0/0x3b0 [snd_soc_core] [ 136.998096] lr : soc_probe_component+0x2b0/0x3b0 [snd_soc_core] [ 137.003990] sp : ffffffc010a33a30 [ 137.007283] x29: ffffffc010a33a30 x28: 0000000000000000 [ 137.012574] x27: ffffff801780d688 x26: ffffff801a386420 [ 137.017865] x25: ffffff8018788f40 x24: ffffff8018788e80 [ 137.023155] x23: ffffff8018788ee8 x22: ffffff801780e080 [ 137.028446] x21: ffffff801a100b40 x20: ffffff8018788e78 [ 137.033736] x19: 0000000000000000 x18: 0000000000000030 [ 137.039026] x17: 0000000000000000 x16: 0000000000000012 [ 137.044316] x15: ffffff801a100f70 x14: 7469772073616962 [ 137.049607] x13: 2066666f2d6e6f6e x12: 206d6f7266207472 [ 137.054897] x11: 61747320746f6e20 x10: 6e61632038313030 [ 137.060187] x9 : 2d302e6365646f63 x8 : 3d66666f5f736169 [ 137.065478] x7 : 625f656c64692068 x6 : 00000000000000d3 [ 137.070768] x5 : 0000000000000000 x4 : 0000000000000000 [ 137.076057] x3 : 0000000000000000 x2 : ffffff801cbaf3d8 [ 137.081347] x1 : 0000000000000000 x0 : 0000000000000000 [ 137.086637] Call trace: [ 137.089083] soc_probe_component+0x2b0/0x3b0 [snd_soc_core] [ 137.094646] snd_soc_instantiate_card+0x318/0x6e0 [snd_soc_core] [ 137.100643] snd_soc_register_card+0xf8/0x120 [snd_soc_core] [ 137.106292] devm_snd_soc_register_card+0x40/0x90 [snd_soc_core] [ 137.112278] asoc_simple_probe+0x1a4/0x29c [snd_soc_simple_card] [ 137.118264] platform_drv_probe+0x50/0xa0 [ 137.122254] really_probe+0xe0/0x470 [ 137.125811] driver_probe_device+0xe0/0x130 [ 137.129975] __device_attach_driver+0x88/0x10c [ 137.134398] bus_for_each_drv+0x74/0xc4 [ 137.138214] __device_attach+0xd8/0x1b0 [ 137.142032] device_initial_probe+0x10/0x20 [ 137.146195] bus_probe_device+0x90/0xa0 [ 137.150011] deferred_probe_work_func+0x88/0xd4 [ 137.154524] process_one_work+0x1c8/0x324 [ 137.158514] worker_thread+0x68/0x3ac [ 137.162157] kthread+0x13c/0x150 [ 137.165368] ret_from_fork+0x10/0x1c [ 137.168922] ---[ end trace 023703bbb2a9eff4 ]--- [ 137.173741] tlv320aic3262-codec 0-0018: Conditional paths are not supported for supply widgets (DACCLK -> [DAC_CLK] -> ASI1_BCLK Route) [ 137.185912] tlv320aic3262-codec 0-0018: ASoC: no dapm match for DACCLK --> DAC_CLK --> ASI1_BCLK Route [ 137.195211] tlv320aic3262-codec 0-0018: ASoC: Failed to add route DACCLK -> DAC_CLK -> ASI1_BCLK Route [ 137.204523] tlv320aic3262-codec 0-0018: Conditional paths are not supported for supply widgets (DAC_MOD_CLK -> [DAC_MOD_CLK] -> ASI1_BCLK Route) [ 137.217457] tlv320aic3262-codec 0-0018: ASoC: no dapm match for DAC_MOD_CLK --> DAC_MOD_CLK --> ASI1_BCLK Route [ 137.227541] tlv320aic3262-codec 0-0018: ASoC: Failed to add route DAC_MOD_CLK -> DAC_MOD_CLK -> ASI1_BCLK Route [ 137.237615] tlv320aic3262-codec 0-0018: Conditional paths are not supported for supply widgets (ADCCLK -> [ADC_CLK] -> ASI1_BCLK Route) [ 137.249776] tlv320aic3262-codec 0-0018: ASoC: no dapm match for ADCCLK --> ADC_CLK --> ASI1_BCLK Route [ 137.259071] tlv320aic3262-codec 0-0018: ASoC: Failed to add route ADCCLK -> ADC_CLK -> ASI1_BCLK Route [ 137.268375] tlv320aic3262-codec 0-0018: Conditional paths are not supported for supply widgets (ADC_MOD_CLK -> [ADC_MOD_CLK] -> ASI1_BCLK Route) [ 137.281317] tlv320aic3262-codec 0-0018: ASoC: no dapm match for ADC_MOD_CLK --> ADC_MOD_CLK --> ASI1_BCLK Route [ 137.291395] tlv320aic3262-codec 0-0018: ASoC: Failed to add route ADC_MOD_CLK -> ADC_MOD_CLK -> ASI1_BCLK Route [ 137.301483] tlv320aic3262-codec 0-0018: Conditional paths are not supported for supply widgets (DACCLK -> [DAC_CLK] -> ASI2_BCLK Route) [ 137.313638] tlv320aic3262-codec 0-0018: ASoC: no dapm match for DACCLK --> DAC_CLK --> ASI2_BCLK Route [ 137.322933] tlv320aic3262-codec 0-0018: ASoC: Failed to add route DACCLK -> DAC_CLK -> ASI2_BCLK Route [ 137.332238] tlv320aic3262-codec 0-0018: Conditional paths are not supported for supply widgets (DAC_MOD_CLK -> [DAC_MOD_CLK] -> ASI2_BCLK Route) [ 137.345173] tlv320aic3262-codec 0-0018: ASoC: no dapm match for DAC_MOD_CLK --> DAC_MOD_CLK --> ASI2_BCLK Route [ 137.355257] tlv320aic3262-codec 0-0018: ASoC: Failed to add route DAC_MOD_CLK -> DAC_MOD_CLK -> ASI2_BCLK Route [ 137.365330] tlv320aic3262-codec 0-0018: Conditional paths are not supported for supply widgets (ADCCLK -> [ADC_CLK] -> ASI2_BCLK Route) [ 137.377483] tlv320aic3262-codec 0-0018: ASoC: no dapm match for ADCCLK --> ADC_CLK --> ASI2_BCLK Route [ 137.386778] tlv320aic3262-codec 0-0018: ASoC: Failed to add route ADCCLK -> ADC_CLK -> ASI2_BCLK Route [ 137.396082] tlv320aic3262-codec 0-0018: Conditional paths are not supported for supply widgets (ADC_MOD_CLK -> [ADC_MOD_CLK] -> ASI2_BCLK Route) [ 137.409020] tlv320aic3262-codec 0-0018: ASoC: no dapm match for ADC_MOD_CLK --> ADC_MOD_CLK --> ASI2_BCLK Route [ 137.419108] tlv320aic3262-codec 0-0018: ASoC: Failed to add route ADC_MOD_CLK -> ADC_MOD_CLK -> ASI2_BCLK Route [ 137.429198] tlv320aic3262-codec 0-0018: Conditional paths are not supported for supply widgets (DACCLK -> [DAC_CLK] -> ASI3_BCLK Route) [ 137.441362] tlv320aic3262-codec 0-0018: ASoC: no dapm match for DACCLK --> DAC_CLK --> ASI3_BCLK Route [ 137.450656] tlv320aic3262-codec 0-0018: ASoC: Failed to add route DACCLK -> DAC_CLK -> ASI3_BCLK Route [ 137.459967] tlv320aic3262-codec 0-0018: Conditional paths are not supported for supply widgets (DAC_MOD_CLK -> [DAC_MOD_CLK] -> ASI3_BCLK Route) [ 137.472903] tlv320aic3262-codec 0-0018: ASoC: no dapm match for DAC_MOD_CLK --> DAC_MOD_CLK --> ASI3_BCLK Route [ 137.482984] tlv320aic3262-codec 0-0018: ASoC: Failed to add route DAC_MOD_CLK -> DAC_MOD_CLK -> ASI3_BCLK Route [ 137.493060] tlv320aic3262-codec 0-0018: Conditional paths are not supported for supply widgets (ADCCLK -> [ADC_CLK] -> ASI3_BCLK Route) [ 137.505223] tlv320aic3262-codec 0-0018: ASoC: no dapm match for ADCCLK --> ADC_CLK --> ASI3_BCLK Route [ 137.514515] tlv320aic3262-codec 0-0018: ASoC: Failed to add route ADCCLK -> ADC_CLK -> ASI3_BCLK Route [ 137.523813] tlv320aic3262-codec 0-0018: Conditional paths are not supported for supply widgets (ADC_MOD_CLK -> [ADC_MOD_CLK] -> ASI3_BCLK Route) [ 137.536754] tlv320aic3262-codec 0-0018: ASoC: no dapm match for ADC_MOD_CLK --> ADC_MOD_CLK --> ASI3_BCLK Route [ 137.546838] tlv320aic3262-codec 0-0018: ASoC: Failed to add route ADC_MOD_CLK -> ADC_MOD_CLK -> ASI3_BCLK Route [ 137.556925] tlv320aic3262-codec 0-0018: Connecting non-supply widget to supply widget is not supported (ASI1_BCLK Route -> ASI1_BCLK) [ 137.568905] tlv320aic3262-codec 0-0018: ASoC: no dapm match for ASI1_BCLK Route --> (null) --> ASI1_BCLK [ 137.578374] tlv320aic3262-codec 0-0018: ASoC: Failed to add route ASI1_BCLK Route -> direct -> ASI1_BCLK [ 137.587858] tlv320aic3262-codec 0-0018: Connecting non-supply widget to supply widget is not supported (ASI2_BCLK Route -> ASI2_BCLK) [ 137.599841] tlv320aic3262-codec 0-0018: ASoC: no dapm match for ASI2_BCLK Route --> (null) --> ASI2_BCLK [ 137.609322] tlv320aic3262-codec 0-0018: ASoC: Failed to add route ASI2_BCLK Route -> direct -> ASI2_BCLK [ 137.618803] tlv320aic3262-codec 0-0018: Connecting non-supply widget to supply widget is not supported (ASI3_BCLK Route -> ASI3_BCLK) [ 137.630786] tlv320aic3262-codec 0-0018: ASoC: no dapm match for ASI3_BCLK Route --> (null) --> ASI3_BCLK [ 137.640254] tlv320aic3262-codec 0-0018: ASoC: Failed to add route ASI3_BCLK Route -> direct -> ASI3_BCLK [ 137.649896] tlv320aic3262-codec 0-0018: Direct firmware load for tlv320aic3262_fw_v1.bin failed with error -2 [ 137.659843] tlv320aic3262-codec 0-0018: request_firmware failed [ 137.687717] tlv320aic3262-codec 0-0018: Control not supported for path DAC MiniDSP IN1 Route -> [NULL] -> Left DAC [ 137.698057] tlv320aic3262-codec 0-0018: ASoC: no dapm match for DAC MiniDSP IN1 Route --> NULL --> Left DAC [ 137.707789] tlv320aic3262-codec 0-0018: ASoC: Failed to add route DAC MiniDSP IN1 Route -> NULL -> Left DAC [ 137.717521] tlv320aic3262-codec 0-0018: Control not supported for path DAC MiniDSP IN1 Route -> [NULL] -> Right DAC [ 137.727944] tlv320aic3262-codec 0-0018: ASoC: no dapm match for DAC MiniDSP IN1 Route --> NULL --> Right DAC [ 137.737767] tlv320aic3262-codec 0-0018: ASoC: Failed to add route DAC MiniDSP IN1 Route -> NULL -> Right DAC [ 137.747584] tlv320aic3262-codec 0-0018: Control not supported for path DAC MiniDSP IN2 Route -> [NULL] -> Left DAC [ 137.757926] tlv320aic3262-codec 0-0018: ASoC: no dapm match for DAC MiniDSP IN2 Route --> NULL --> Left DAC [ 137.767654] tlv320aic3262-codec 0-0018: ASoC: Failed to add route DAC MiniDSP IN2 Route -> NULL -> Left DAC [ 137.777383] tlv320aic3262-codec 0-0018: Control not supported for path DAC MiniDSP IN2 Route -> [NULL] -> Right DAC [ 137.787805] tlv320aic3262-codec 0-0018: ASoC: no dapm match for DAC MiniDSP IN2 Route --> NULL --> Right DAC [ 137.797628] tlv320aic3262-codec 0-0018: ASoC: Failed to add route DAC MiniDSP IN2 Route -> NULL -> Right DAC [ 137.807445] tlv320aic3262-codec 0-0018: Control not supported for path DAC MiniDSP IN3 Route -> [NULL] -> Left DAC [ 137.817789] tlv320aic3262-codec 0-0018: ASoC: no dapm match for DAC MiniDSP IN3 Route --> NULL --> Left DAC [ 137.827523] tlv320aic3262-codec 0-0018: ASoC: Failed to add route DAC MiniDSP IN3 Route -> NULL -> Left DAC [ 137.837261] tlv320aic3262-codec 0-0018: Control not supported for path DAC MiniDSP IN3 Route -> [NULL] -> Right DAC [ 137.847681] tlv320aic3262-codec 0-0018: ASoC: no dapm match for DAC MiniDSP IN3 Route --> NULL --> Right DAC [ 137.857504] tlv320aic3262-codec 0-0018: ASoC: Failed to add route DAC MiniDSP IN3 Route -> NULL -> Right DAC [ 137.893132] asoc-simple-card sound: soc_probe_component: snd_soc_dapm_add_routes failed: -22 [ 137.901790] asoc-simple-card sound: ASoC: failed to instantiate card -22 [ 137.908635] asoc-simple-card: probe of sound failed with error -22
I wonder if the driver is not compatible with my kernel version, which could be causing these issues. Do you have any idea of what the problem would be? Any help in getting my errors to resolve would be greatly appreciated. Let me know if you need any other information from me.
Thanks,
Eric