Merge remote-tracking branches 'asoc/fix/rt5677', 'asoc/fix/st', 'asoc/fix/sun4i...
authorMark Brown <broonie@kernel.org>
Wed, 25 Nov 2015 17:57:54 +0000 (17:57 +0000)
committerMark Brown <broonie@kernel.org>
Wed, 25 Nov 2015 17:57:54 +0000 (17:57 +0000)
1  2  3  4  5  6  7 
sound/soc/codecs/wm8960.c
sound/soc/soc-topology.c

index 056375339ea32948207723b1affd84ebdd0b1730,e3b7d0c57411870176c5e1e1398101f5641f77ad,056375339ea32948207723b1affd84ebdd0b1730,056375339ea32948207723b1affd84ebdd0b1730,056375339ea32948207723b1affd84ebdd0b1730,bbe24275f8c938c2fef6eb743e45395ca235d744,056375339ea32948207723b1affd84ebdd0b1730..5380798883b5d342df4dee0ffdd54e3b474ceac6
@@@@@@@@ -201,7 -201,7 -201,7 -201,7 -201,7 -201,7 -201,7 +201,7 @@@@@@@@ static int wm8960_put_deemph(struct snd
       {
        struct snd_soc_codec *codec = snd_soc_kcontrol_codec(kcontrol);
        struct wm8960_priv *wm8960 = snd_soc_codec_get_drvdata(codec);
 -   -  int deemph = ucontrol->value.integer.value[0];
 +   +  unsigned int deemph = ucontrol->value.integer.value[0];
       
        if (deemph > 1)
                return -EINVAL;
        return wm8960_set_deemph(codec);
       }
       
 -   - static const DECLARE_TLV_DB_SCALE(adc_tlv, -9700, 50, 0);
 -   - static const DECLARE_TLV_DB_SCALE(dac_tlv, -12700, 50, 1);
 +   + static const DECLARE_TLV_DB_SCALE(adc_tlv, -9750, 50, 1);
 +   + static const DECLARE_TLV_DB_SCALE(inpga_tlv, -1725, 75, 0);
 +   + static const DECLARE_TLV_DB_SCALE(dac_tlv, -12750, 50, 1);
       static const DECLARE_TLV_DB_SCALE(bypass_tlv, -2100, 300, 0);
       static const DECLARE_TLV_DB_SCALE(out_tlv, -12100, 100, 1);
 -   - static const DECLARE_TLV_DB_SCALE(boost_tlv, -1200, 300, 1);
 +   + static const DECLARE_TLV_DB_SCALE(lineinboost_tlv, -1500, 300, 1);
 +   + static const unsigned int micboost_tlv[] = {
 +   +  TLV_DB_RANGE_HEAD(2),
 +   +  0, 1, TLV_DB_SCALE_ITEM(0, 1300, 0),
 +   +  2, 3, TLV_DB_SCALE_ITEM(2000, 900, 0),
 +   + };
       
       static const struct snd_kcontrol_new wm8960_snd_controls[] = {
       SOC_DOUBLE_R_TLV("Capture Volume", WM8960_LINVOL, WM8960_RINVOL,
 -   -           0, 63, 0, adc_tlv),
 +   +           0, 63, 0, inpga_tlv),
       SOC_DOUBLE_R("Capture Volume ZC Switch", WM8960_LINVOL, WM8960_RINVOL,
        6, 1, 0),
       SOC_DOUBLE_R("Capture Switch", WM8960_LINVOL, WM8960_RINVOL,
----- - 7, 1, 0),
+++++ + 7, 1, 1),
       
       SOC_SINGLE_TLV("Right Input Boost Mixer RINPUT3 Volume",
 -   -         WM8960_INBMIX1, 4, 7, 0, boost_tlv),
 +   +         WM8960_INBMIX1, 4, 7, 0, lineinboost_tlv),
       SOC_SINGLE_TLV("Right Input Boost Mixer RINPUT2 Volume",
 -   -         WM8960_INBMIX1, 1, 7, 0, boost_tlv),
 +   +         WM8960_INBMIX1, 1, 7, 0, lineinboost_tlv),
       SOC_SINGLE_TLV("Left Input Boost Mixer LINPUT3 Volume",
 -   -         WM8960_INBMIX2, 4, 7, 0, boost_tlv),
 +   +         WM8960_INBMIX2, 4, 7, 0, lineinboost_tlv),
       SOC_SINGLE_TLV("Left Input Boost Mixer LINPUT2 Volume",
 -   -         WM8960_INBMIX2, 1, 7, 0, boost_tlv),
 +   +         WM8960_INBMIX2, 1, 7, 0, lineinboost_tlv),
 +   + SOC_SINGLE_TLV("Right Input Boost Mixer RINPUT1 Volume",
 +   +          WM8960_RINPATH, 4, 3, 0, micboost_tlv),
 +   + SOC_SINGLE_TLV("Left Input Boost Mixer LINPUT1 Volume",
 +   +          WM8960_LINPATH, 4, 3, 0, micboost_tlv),
       
       SOC_DOUBLE_R_TLV("Playback Volume", WM8960_LDAC, WM8960_RDAC,
                 0, 255, 0, dac_tlv),
diff --combined sound/soc/soc-topology.c
index cce63fe65dd97ccb8dcb2b2362da6eb81319954f,69d01cd925ce28fb5fc5e798880f391ec207fff0,8d7ec80af51b499738dc2032356896a08144078a,8d7ec80af51b499738dc2032356896a08144078a,50f21ed00cfa375685d967ece4c17ccc7a86df91,69d01cd925ce28fb5fc5e798880f391ec207fff0,8d7ec80af51b499738dc2032356896a08144078a..6963ba20991c10066fdad2ad65f3102fc5752424
@@@@@@@@ -531,7 -531,7 -531,7 -531,7 -531,7 -531,7 -531,7 +531,7 @@@@@@@@ static int soc_tplg_kcontrol_bind_io(st
                /* TLV bytes controls need standard kcontrol info handler,
                 * TLV callback and extended put/get handlers.
                 */
---- --         k->info = snd_soc_bytes_info;
++++ ++         k->info = snd_soc_bytes_info_ext;
                k->tlv.c = snd_soc_bytes_tlv_callback;
       
                ext_ops = tplg->bytes_ext_ops;
@@@@@@@@ -1558,7 -1558,7 -1558,7 -1558,7 -1558,7 -1558,7 -1558,7 +1558,7 @@@@@@@@ static int soc_tplg_pcm_dai_elems_load(
        pcm_dai = (struct snd_soc_tplg_pcm_dai *)tplg->pos;
       
        if (soc_tplg_check_elem_count(tplg,
 -   -          sizeof(struct snd_soc_tplg_pcm_dai), count,
 +   +          sizeof(struct snd_soc_tplg_pcm), count,
                hdr->payload_size, "PCM DAI")) {
                dev_err(tplg->dev, "ASoC: invalid count %d for PCM DAI elems\n",
                        count);
        }
       
        dev_dbg(tplg->dev, "ASoC: adding %d PCM DAIs\n", count);
 -   -  tplg->pos += sizeof(struct snd_soc_tplg_pcm_dai) * count;
 +   +  tplg->pos += sizeof(struct snd_soc_tplg_pcm) * count;
       
        dobj = kzalloc(sizeof(struct snd_soc_dobj), GFP_KERNEL);
        if (dobj == NULL)
@@@@@@@@ -1805,7 -1805,6 -1805,6 -1805,6 -1805,6 -1805,6 -1805,6 +1805,7 @@@@@@@@ void snd_soc_tplg_widget_remove_all(str
                snd_soc_tplg_widget_remove(w);
                snd_soc_dapm_free_widget(w);
        }
 ++++++ snd_soc_dapm_reset_cache(dapm);
       }
       EXPORT_SYMBOL_GPL(snd_soc_tplg_widget_remove_all);