Part Number:TLV320AIC3111
Hi,
I am trying to use a TLV320AIC3111 with an NXP i.MX8M running Linux. I followed the instructions here http://www.ti.com/tool/tlv320aic31xxsw-linux; I enabled SND_SOC_TLV320AIC31XX with menuconfig, and I put the following entries in the device tree:
&i2c3 {
clock-frequency = <100000>;
pinctrl-names = "default";
pinctrl-0 = <&pinctrl_i2c3>;
status = "okay";
tlv320aic311x: tlv320aic311x@18 {
compatible = "ti,tlv320aic311x";
reg = <0x18>;
ai31xx-micbias-vg = <MICBIAS_2_0V>;
reset-gpios = <&gpio4 28 GPIO_ACTIVE_LOW>;
AVDD-supply = <®_audio_board>;
HPVDD-supply = <®_audio_board>;
SPRVDD-supply = <®_audio_board>;
SPLVDD-supply = <®_audio_board>;
IOVDD-supply = <®_audio_board>;
DVDD-supply = <®_audio_board>;
};
};
&sai1 {
pinctrl-names = "default";
pinctrl-0 = <&pinctrl_sai1>;
assigned-clocks = <&clk IMX8MM_CLK_SAI1_SRC>,
<&clk IMX8MM_CLK_SAI1_DIV>;
assigned-clock-parents = <&clk IMX8MM_AUDIO_PLL1_OUT>;
assigned-clock-rates = <0>, <24576000>;
status = "okay";
};
sound-tlv320aic311x {
compatible = "ti,tlv320aic311x";
model = "tlv320aic311x-audio";
audio-cpu = <&sai1>;
audio-codec = <&tlv320aic311x>;
audio-routing =
"Speaker Left", "SPL",
"Speaker Right", "SPR",
"MIC1LM","Mic";
};
I'm using the 3111 EVM, detached from the USB board, for now, so the regulators aren't actually under the i.MX board's control. I commented out the following lines in tlv320aic31xx.c:
/*for (i = 0; i < ARRAY_SIZE(aic31xx->supplies); i++)
aic31xx->supplies[i].supply = aic31xx_supply_names[i];
ret = devm_regulator_bulk_get(aic31xx->dev,
ARRAY_SIZE(aic31xx->supplies),
aic31xx->supplies);
if (ret != 0)
dev_err(aic31xx->dev, "Failed to request supplies: %d\n", ret);*/
I get the following error in my dmesg when I grep for "tlv":
[ 4.310678] tlv320aic31xx-codec: probe of 2-0018 failed with error 157556304
I'm using I2C 2, and the address of the codec is 0x18, so this makes me wonder if there's an I2C problem. I've used I2C successfully for other devices on this board, and 18 shows up when I run i2cdetect - 2:
0 1 2 3 4 5 6 7 8 9 a b c d e f
00: -- -- -- -- -- -- -- -- -- -- -- -- --
10: UU UU UU UU -- -- -- -- 18 -- -- -- -- -- -- --
20: UU -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
30: -- -- -- -- -- -- -- -- -- -- -- -- UU -- -- --
40: 40 -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
50: 50 -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
60: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
70: -- -- -- -- -- -- -- --
Any ideas?
Thanks,
Dave