audio: Speaker has no sound [1/1]

PD#IPTV-3107

Problem:
Speaker has no sound

Solution:
modify dts and ad82584f

Verify:
Verify by Android P S905D3 AC202

Change-Id: I92ddb6a86b31dcd2c37311a0fc9b1a2cefc29d4e
Signed-off-by: GongWei Chen <gongwei.chen@amlogic.com>
This commit is contained in:
Gongwei Chen
2019-05-31 14:59:10 +08:00
committed by Luan Yuan
parent c418d0fd6c
commit fe40c1f4c0
5 changed files with 33 additions and 15 deletions

View File

@@ -1107,7 +1107,6 @@
reg = <0x31>;
status = "okay";
reset_pin = <&gpio_ao GPIOAO_9 0>;
enable_pin = <&gpio GPIOC_4 0>;
no_mclk;
};
@@ -1163,6 +1162,12 @@
*/
samesource_sel = <3>;
/*enable default mclk(12.288M), before extern codec start*/
start_clk_enable = <1>;
/*tdm clk tuning enable*/
clk_tuning_enable = <1>;
status = "okay";
};
@@ -1252,6 +1257,9 @@
pinctrl-names = "spdif_pins";
pinctrl-0 = <&spdifout>;/* bob remove &spdifin*/
/*spdif clk tuning enable*/
clk_tuning_enable = <1>;
status = "okay";
};
spdifb: spdif@1 {

View File

@@ -1107,7 +1107,6 @@
reg = <0x31>;
status = "okay";
reset_pin = <&gpio_ao GPIOAO_9 0>;
enable_pin = <&gpio GPIOC_4 0>;
no_mclk;
};
@@ -1163,6 +1162,12 @@
*/
samesource_sel = <3>;
/*enable default mclk(12.288M), before extern codec start*/
start_clk_enable = <1>;
/*tdm clk tuning enable*/
clk_tuning_enable = <1>;
status = "okay";
};
@@ -1252,6 +1257,9 @@
pinctrl-names = "spdif_pins";
pinctrl-0 = <&spdifout>;/* bob remove &spdifin*/
/*spdif clk tuning enable*/
clk_tuning_enable = <1>;
status = "okay";
};
spdifb: spdif@1 {

View File

@@ -1106,7 +1106,6 @@
reg = <0x31>;
status = "okay";
reset_pin = <&gpio_ao GPIOAO_9 0>;
enable_pin = <&gpio GPIOC_4 0>;
no_mclk;
};
@@ -1254,6 +1253,9 @@
pinctrl-names = "spdif_pins";
pinctrl-0 = <&spdifout>;/* bob remove &spdifin*/
/*spdif clk tuning enable*/
clk_tuning_enable = <1>;
status = "okay";
};
spdifb: spdif@1 {

View File

@@ -1106,7 +1106,6 @@
reg = <0x31>;
status = "okay";
reset_pin = <&gpio_ao GPIOAO_9 0>;
enable_pin = <&gpio GPIOC_4 0>;
no_mclk;
};
@@ -1160,6 +1159,12 @@
*/
samesource_sel = <3>;
/*enable default mclk(12.288M), before extern codec start*/
start_clk_enable = <1>;
/*tdm clk tuning enable*/
clk_tuning_enable = <1>;
status = "okay";
};
@@ -1249,6 +1254,9 @@
pinctrl-names = "spdif_pins";
pinctrl-0 = <&spdifout>;/* bob remove &spdifin*/
/*spdif clk tuning enable*/
clk_tuning_enable = <1>;
status = "okay";
};
spdifb: spdif@1 {

View File

@@ -600,7 +600,7 @@ struct ad82584f_priv {
unsigned char Ch2_vol;
unsigned char master_vol;
unsigned char mute_val;
unsigned int inited;
#ifdef CONFIG_HAS_EARLYSUSPEND
struct early_suspend early_suspend;
#endif
@@ -699,7 +699,6 @@ static int ad82584f_set_bias_level(struct snd_soc_codec *codec,
return 0;
}
static int ad82584f_init(struct snd_soc_codec *codec);
static int ad82584f_prepare(struct snd_pcm_substream *substream,
struct snd_soc_dai *dai)
{
@@ -714,14 +713,6 @@ static int ad82584f_prepare(struct snd_pcm_substream *substream,
/*unmute,default power-on is mute.*/
snd_soc_write(codec, 0x02, 0x00);
#else
struct snd_soc_codec *codec = dai->codec;
struct ad82584f_priv *ad82584f = snd_soc_codec_get_drvdata(codec);
if (ad82584f->inited == 0) {
ad82584f_init(codec);
ad82584f->inited = 1;
}
#endif
return 0;
@@ -772,6 +763,7 @@ static int reset_ad82584f_GPIO(struct snd_soc_codec *codec)
struct ad82584f_priv *ad82584f = snd_soc_codec_get_drvdata(codec);
struct ad82584f_platform_data *pdata = ad82584f->pdata;
int ret = 0;
if (pdata->reset_pin < 0)
return 0;
@@ -1008,7 +1000,7 @@ static int ad82584f_i2c_probe(struct i2c_client *i2c,
return -ENOMEM;
}
ad82584f->pdata = pdata;
ad82584f->inited = 0;
ad82584f_parse_dt(ad82584f, i2c->dev.of_node);
ret = snd_soc_register_codec(&i2c->dev, &soc_codec_dev_ad82584f,