Skip to content

Commit

Permalink
Merge remote-tracking branches 'asoc/topic/rt5514', 'asoc/topic/rt564…
Browse files Browse the repository at this point in the history
…0', 'asoc/topic/rt5645', 'asoc/topic/rt5659' and 'asoc/topic/rt5660' into asoc-next
  • Loading branch information
broonie committed Feb 19, 2017
6 parents 8237d99 + e98aa52 + 4a312c9 + cec5582 + 13861a4 + 969f751 commit a564394
Show file tree
Hide file tree
Showing 5 changed files with 63 additions and 59 deletions.
1 change: 0 additions & 1 deletion sound/soc/codecs/rt5514-spi.c
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,6 @@
#include <linux/gpio.h>
#include <linux/sched.h>
#include <linux/uaccess.h>
#include <linux/miscdevice.h>
#include <linux/regulator/consumer.h>
#include <linux/pm_qos.h>
#include <linux/sysfs.h>
Expand Down
12 changes: 6 additions & 6 deletions sound/soc/codecs/rt5640.c
Original file line number Diff line number Diff line change
Expand Up @@ -995,7 +995,7 @@ static int rt5640_hp_event(struct snd_soc_dapm_widget *w,

case SND_SOC_DAPM_PRE_PMD:
rt5640->hp_mute = 1;
usleep_range(70000, 75000);
msleep(70);
break;

default:
Expand Down Expand Up @@ -1059,7 +1059,7 @@ static int rt5640_hp_post_event(struct snd_soc_dapm_widget *w,
switch (event) {
case SND_SOC_DAPM_POST_PMU:
if (!rt5640->hp_mute)
usleep_range(80000, 85000);
msleep(80);

break;

Expand Down Expand Up @@ -1227,6 +1227,10 @@ static const struct snd_soc_dapm_widget rt5640_dapm_widgets[] = {
RT5640_PWR_DAC_L1_BIT, 0, NULL, 0),
SND_SOC_DAPM_SUPPLY("DAC R1 Power", RT5640_PWR_DIG1,
RT5640_PWR_DAC_R1_BIT, 0, NULL, 0),
SND_SOC_DAPM_SUPPLY("DAC L2 Power", RT5640_PWR_DIG1,
RT5640_PWR_DAC_L2_BIT, 0, NULL, 0),
SND_SOC_DAPM_SUPPLY("DAC R2 Power", RT5640_PWR_DIG1,
RT5640_PWR_DAC_R2_BIT, 0, NULL, 0),
/* SPK/OUT Mixer */
SND_SOC_DAPM_MIXER("SPK MIXL", RT5640_PWR_MIXER, RT5640_PWR_SM_L_BIT,
0, rt5640_spk_l_mix, ARRAY_SIZE(rt5640_spk_l_mix)),
Expand Down Expand Up @@ -1322,10 +1326,6 @@ static const struct snd_soc_dapm_widget rt5640_specific_dapm_widgets[] = {
rt5640_mono_mix, ARRAY_SIZE(rt5640_mono_mix)),
SND_SOC_DAPM_SUPPLY("Improve MONO Amp Drv", RT5640_PWR_ANLG1,
RT5640_PWR_MA_BIT, 0, NULL, 0),
SND_SOC_DAPM_SUPPLY("DAC L2 Power", RT5640_PWR_DIG1,
RT5640_PWR_DAC_L2_BIT, 0, NULL, 0),
SND_SOC_DAPM_SUPPLY("DAC R2 Power", RT5640_PWR_DIG1,
RT5640_PWR_DAC_R2_BIT, 0, NULL, 0),

SND_SOC_DAPM_OUTPUT("MONOP"),
SND_SOC_DAPM_OUTPUT("MONON"),
Expand Down
12 changes: 9 additions & 3 deletions sound/soc/codecs/rt5645.c
Original file line number Diff line number Diff line change
Expand Up @@ -3109,7 +3109,7 @@ static int rt5645_jack_detect(struct snd_soc_codec *codec, int jack_insert)
unsigned int val;

if (jack_insert) {
regmap_write(rt5645->regmap, RT5645_CHARGE_PUMP, 0x0006);
regmap_write(rt5645->regmap, RT5645_CHARGE_PUMP, 0x0e06);

/* for jack type detect */
snd_soc_dapm_force_enable_pin(dapm, "LDO2");
Expand Down Expand Up @@ -3660,8 +3660,14 @@ static int rt5645_i2c_probe(struct i2c_client *i2c,
GPIOD_IN);

if (IS_ERR(rt5645->gpiod_hp_det)) {
dev_err(&i2c->dev, "failed to initialize gpiod\n");
return PTR_ERR(rt5645->gpiod_hp_det);
dev_info(&i2c->dev, "failed to initialize gpiod\n");
ret = PTR_ERR(rt5645->gpiod_hp_det);
/*
* Continue if optional gpiod is missing, bail for all other
* errors, including -EPROBE_DEFER
*/
if (ret != -ENOENT)
return ret;
}

for (i = 0; i < ARRAY_SIZE(rt5645->supplies); i++)
Expand Down
Loading

0 comments on commit a564394

Please sign in to comment.