]> git.ipfire.org Git - thirdparty/kernel/linux.git/commitdiff
ASoC: tegra: tegra210: use snd_kcontrol_chip() instead of snd_soc_kcontrol_component()
authorKuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Tue, 14 Oct 2025 04:27:56 +0000 (04:27 +0000)
committerMark Brown <broonie@kernel.org>
Mon, 20 Oct 2025 01:44:29 +0000 (02:44 +0100)
We have very similar name functions (A)(B). Both gets component from
snd_kcontrol, but (A) is used in callback functions which is registered
through snd_soc_add_component_controls(), (B) is used through
snd_soc_dapm_new_widgets().

(A) snd_soc_kcontrol_component()
(B) snd_soc_dapm_kcontrol_component()

(B) is using very picky way to get component but using it is necessary in
ASoC. But (A) is just wrapper function to snd_kcontrol_chip(), and directly
using it without wrapper is very common way on ALSA.
To reduce confusions of similar function, let's use common way on (A).

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://patch.msgid.link/87ecr6m7jn.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>
sound/soc/tegra/tegra210_admaif.c
sound/soc/tegra/tegra210_adx.c
sound/soc/tegra/tegra210_amx.c
sound/soc/tegra/tegra210_dmic.c
sound/soc/tegra/tegra210_i2s.c
sound/soc/tegra/tegra210_mbdrc.c
sound/soc/tegra/tegra210_mixer.c
sound/soc/tegra/tegra210_mvc.c
sound/soc/tegra/tegra210_ope.c
sound/soc/tegra/tegra210_peq.c
sound/soc/tegra/tegra210_sfc.c

index f88d6a2356e07a6271d3f011c94708fc5fb15d44..f9f6040c4e3465ea11aa2320224aff4b9af3d87e 100644 (file)
@@ -493,7 +493,7 @@ static int tegra_admaif_trigger(struct snd_pcm_substream *substream, int cmd,
 static int tegra210_admaif_pget_mono_to_stereo(struct snd_kcontrol *kcontrol,
        struct snd_ctl_elem_value *ucontrol)
 {
-       struct snd_soc_component *cmpnt = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *cmpnt = snd_kcontrol_chip(kcontrol);
        struct tegra_admaif *admaif = snd_soc_component_get_drvdata(cmpnt);
        struct soc_enum *ec = (struct soc_enum *)kcontrol->private_value;
 
@@ -506,7 +506,7 @@ static int tegra210_admaif_pget_mono_to_stereo(struct snd_kcontrol *kcontrol,
 static int tegra210_admaif_pput_mono_to_stereo(struct snd_kcontrol *kcontrol,
        struct snd_ctl_elem_value *ucontrol)
 {
-       struct snd_soc_component *cmpnt = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *cmpnt = snd_kcontrol_chip(kcontrol);
        struct tegra_admaif *admaif = snd_soc_component_get_drvdata(cmpnt);
        struct soc_enum *ec = (struct soc_enum *)kcontrol->private_value;
        unsigned int value = ucontrol->value.enumerated.item[0];
@@ -522,7 +522,7 @@ static int tegra210_admaif_pput_mono_to_stereo(struct snd_kcontrol *kcontrol,
 static int tegra210_admaif_cget_mono_to_stereo(struct snd_kcontrol *kcontrol,
        struct snd_ctl_elem_value *ucontrol)
 {
-       struct snd_soc_component *cmpnt = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *cmpnt = snd_kcontrol_chip(kcontrol);
        struct tegra_admaif *admaif = snd_soc_component_get_drvdata(cmpnt);
        struct soc_enum *ec = (struct soc_enum *)kcontrol->private_value;
 
@@ -535,7 +535,7 @@ static int tegra210_admaif_cget_mono_to_stereo(struct snd_kcontrol *kcontrol,
 static int tegra210_admaif_cput_mono_to_stereo(struct snd_kcontrol *kcontrol,
        struct snd_ctl_elem_value *ucontrol)
 {
-       struct snd_soc_component *cmpnt = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *cmpnt = snd_kcontrol_chip(kcontrol);
        struct tegra_admaif *admaif = snd_soc_component_get_drvdata(cmpnt);
        struct soc_enum *ec = (struct soc_enum *)kcontrol->private_value;
        unsigned int value = ucontrol->value.enumerated.item[0];
@@ -551,7 +551,7 @@ static int tegra210_admaif_cput_mono_to_stereo(struct snd_kcontrol *kcontrol,
 static int tegra210_admaif_pget_stereo_to_mono(struct snd_kcontrol *kcontrol,
        struct snd_ctl_elem_value *ucontrol)
 {
-       struct snd_soc_component *cmpnt = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *cmpnt = snd_kcontrol_chip(kcontrol);
        struct tegra_admaif *admaif = snd_soc_component_get_drvdata(cmpnt);
        struct soc_enum *ec = (struct soc_enum *)kcontrol->private_value;
 
@@ -564,7 +564,7 @@ static int tegra210_admaif_pget_stereo_to_mono(struct snd_kcontrol *kcontrol,
 static int tegra210_admaif_pput_stereo_to_mono(struct snd_kcontrol *kcontrol,
        struct snd_ctl_elem_value *ucontrol)
 {
-       struct snd_soc_component *cmpnt = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *cmpnt = snd_kcontrol_chip(kcontrol);
        struct tegra_admaif *admaif = snd_soc_component_get_drvdata(cmpnt);
        struct soc_enum *ec = (struct soc_enum *)kcontrol->private_value;
        unsigned int value = ucontrol->value.enumerated.item[0];
@@ -580,7 +580,7 @@ static int tegra210_admaif_pput_stereo_to_mono(struct snd_kcontrol *kcontrol,
 static int tegra210_admaif_cget_stereo_to_mono(struct snd_kcontrol *kcontrol,
        struct snd_ctl_elem_value *ucontrol)
 {
-       struct snd_soc_component *cmpnt = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *cmpnt = snd_kcontrol_chip(kcontrol);
        struct tegra_admaif *admaif = snd_soc_component_get_drvdata(cmpnt);
        struct soc_enum *ec = (struct soc_enum *)kcontrol->private_value;
 
@@ -593,7 +593,7 @@ static int tegra210_admaif_cget_stereo_to_mono(struct snd_kcontrol *kcontrol,
 static int tegra210_admaif_cput_stereo_to_mono(struct snd_kcontrol *kcontrol,
        struct snd_ctl_elem_value *ucontrol)
 {
-       struct snd_soc_component *cmpnt = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *cmpnt = snd_kcontrol_chip(kcontrol);
        struct tegra_admaif *admaif = snd_soc_component_get_drvdata(cmpnt);
        struct soc_enum *ec = (struct soc_enum *)kcontrol->private_value;
        unsigned int value = ucontrol->value.enumerated.item[0];
index ad7cd865504781202b0b8cd87ca244ed966a04ee..6c9a410085bc558ac5f631f5ebf5eca0fa8ea0d4 100644 (file)
@@ -186,7 +186,7 @@ static int tegra210_adx_in_hw_params(struct snd_pcm_substream *substream,
 static int tegra210_adx_get_byte_map(struct snd_kcontrol *kcontrol,
                                     struct snd_ctl_elem_value *ucontrol)
 {
-       struct snd_soc_component *cmpnt = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *cmpnt = snd_kcontrol_chip(kcontrol);
        struct tegra210_adx *adx = snd_soc_component_get_drvdata(cmpnt);
        struct soc_mixer_control *mc;
        unsigned char *bytes_map = (unsigned char *)adx->map;
@@ -216,7 +216,7 @@ static int tegra210_adx_get_byte_map(struct snd_kcontrol *kcontrol,
 static int tegra210_adx_put_byte_map(struct snd_kcontrol *kcontrol,
                                     struct snd_ctl_elem_value *ucontrol)
 {
-       struct snd_soc_component *cmpnt = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *cmpnt = snd_kcontrol_chip(kcontrol);
        struct tegra210_adx *adx = snd_soc_component_get_drvdata(cmpnt);
        unsigned char *bytes_map = (unsigned char *)adx->map;
        int value = ucontrol->value.integer.value[0];
index 7f558c40e097bd12fa84aeace41c75c956c12deb..c94f8c84e04f45ca380bbf23aeafcc349d5f4634 100644 (file)
@@ -208,7 +208,7 @@ static int tegra210_amx_out_hw_params(struct snd_pcm_substream *substream,
 static int tegra210_amx_get_byte_map(struct snd_kcontrol *kcontrol,
                                     struct snd_ctl_elem_value *ucontrol)
 {
-       struct snd_soc_component *cmpnt = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *cmpnt = snd_kcontrol_chip(kcontrol);
        struct soc_mixer_control *mc =
                (struct soc_mixer_control *)kcontrol->private_value;
        struct tegra210_amx *amx = snd_soc_component_get_drvdata(cmpnt);
@@ -241,7 +241,7 @@ static int tegra210_amx_put_byte_map(struct snd_kcontrol *kcontrol,
 {
        struct soc_mixer_control *mc =
                (struct soc_mixer_control *)kcontrol->private_value;
-       struct snd_soc_component *cmpnt = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *cmpnt = snd_kcontrol_chip(kcontrol);
        struct tegra210_amx *amx = snd_soc_component_get_drvdata(cmpnt);
        unsigned char *bytes_map = (unsigned char *)amx->map;
        int reg = mc->reg;
index e4a1445712659e97c0b13c7ee6749bb320cffe06..66fff53aeaa69889e67d7b477c0f1b8f0becd33e 100644 (file)
@@ -160,7 +160,7 @@ static int tegra210_dmic_hw_params(struct snd_pcm_substream *substream,
 static int tegra210_dmic_get_boost_gain(struct snd_kcontrol *kcontrol,
                                        struct snd_ctl_elem_value *ucontrol)
 {
-       struct snd_soc_component *comp = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *comp = snd_kcontrol_chip(kcontrol);
        struct tegra210_dmic *dmic = snd_soc_component_get_drvdata(comp);
 
        ucontrol->value.integer.value[0] = dmic->boost_gain;
@@ -171,7 +171,7 @@ static int tegra210_dmic_get_boost_gain(struct snd_kcontrol *kcontrol,
 static int tegra210_dmic_put_boost_gain(struct snd_kcontrol *kcontrol,
                                        struct snd_ctl_elem_value *ucontrol)
 {
-       struct snd_soc_component *comp = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *comp = snd_kcontrol_chip(kcontrol);
        struct tegra210_dmic *dmic = snd_soc_component_get_drvdata(comp);
        int value = ucontrol->value.integer.value[0];
 
@@ -186,7 +186,7 @@ static int tegra210_dmic_put_boost_gain(struct snd_kcontrol *kcontrol,
 static int tegra210_dmic_get_ch_select(struct snd_kcontrol *kcontrol,
                                       struct snd_ctl_elem_value *ucontrol)
 {
-       struct snd_soc_component *comp = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *comp = snd_kcontrol_chip(kcontrol);
        struct tegra210_dmic *dmic = snd_soc_component_get_drvdata(comp);
 
        ucontrol->value.enumerated.item[0] = dmic->ch_select;
@@ -197,7 +197,7 @@ static int tegra210_dmic_get_ch_select(struct snd_kcontrol *kcontrol,
 static int tegra210_dmic_put_ch_select(struct snd_kcontrol *kcontrol,
                                       struct snd_ctl_elem_value *ucontrol)
 {
-       struct snd_soc_component *comp = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *comp = snd_kcontrol_chip(kcontrol);
        struct tegra210_dmic *dmic = snd_soc_component_get_drvdata(comp);
        unsigned int value = ucontrol->value.enumerated.item[0];
 
@@ -212,7 +212,7 @@ static int tegra210_dmic_put_ch_select(struct snd_kcontrol *kcontrol,
 static int tegra210_dmic_get_mono_to_stereo(struct snd_kcontrol *kcontrol,
                                            struct snd_ctl_elem_value *ucontrol)
 {
-       struct snd_soc_component *comp = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *comp = snd_kcontrol_chip(kcontrol);
        struct tegra210_dmic *dmic = snd_soc_component_get_drvdata(comp);
 
        ucontrol->value.enumerated.item[0] = dmic->mono_to_stereo;
@@ -223,7 +223,7 @@ static int tegra210_dmic_get_mono_to_stereo(struct snd_kcontrol *kcontrol,
 static int tegra210_dmic_put_mono_to_stereo(struct snd_kcontrol *kcontrol,
                                            struct snd_ctl_elem_value *ucontrol)
 {
-       struct snd_soc_component *comp = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *comp = snd_kcontrol_chip(kcontrol);
        struct tegra210_dmic *dmic = snd_soc_component_get_drvdata(comp);
        unsigned int value = ucontrol->value.enumerated.item[0];
 
@@ -238,7 +238,7 @@ static int tegra210_dmic_put_mono_to_stereo(struct snd_kcontrol *kcontrol,
 static int tegra210_dmic_get_stereo_to_mono(struct snd_kcontrol *kcontrol,
                                            struct snd_ctl_elem_value *ucontrol)
 {
-       struct snd_soc_component *comp = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *comp = snd_kcontrol_chip(kcontrol);
        struct tegra210_dmic *dmic = snd_soc_component_get_drvdata(comp);
 
        ucontrol->value.enumerated.item[0] = dmic->stereo_to_mono;
@@ -249,7 +249,7 @@ static int tegra210_dmic_get_stereo_to_mono(struct snd_kcontrol *kcontrol,
 static int tegra210_dmic_put_stereo_to_mono(struct snd_kcontrol *kcontrol,
                                            struct snd_ctl_elem_value *ucontrol)
 {
-       struct snd_soc_component *comp = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *comp = snd_kcontrol_chip(kcontrol);
        struct tegra210_dmic *dmic = snd_soc_component_get_drvdata(comp);
        unsigned int value = ucontrol->value.enumerated.item[0];
 
@@ -264,7 +264,7 @@ static int tegra210_dmic_put_stereo_to_mono(struct snd_kcontrol *kcontrol,
 static int tegra210_dmic_get_osr_val(struct snd_kcontrol *kcontrol,
                                     struct snd_ctl_elem_value *ucontrol)
 {
-       struct snd_soc_component *comp = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *comp = snd_kcontrol_chip(kcontrol);
        struct tegra210_dmic *dmic = snd_soc_component_get_drvdata(comp);
 
        ucontrol->value.enumerated.item[0] = dmic->osr_val;
@@ -275,7 +275,7 @@ static int tegra210_dmic_get_osr_val(struct snd_kcontrol *kcontrol,
 static int tegra210_dmic_put_osr_val(struct snd_kcontrol *kcontrol,
                                     struct snd_ctl_elem_value *ucontrol)
 {
-       struct snd_soc_component *comp = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *comp = snd_kcontrol_chip(kcontrol);
        struct tegra210_dmic *dmic = snd_soc_component_get_drvdata(comp);
        unsigned int value = ucontrol->value.enumerated.item[0];
 
@@ -290,7 +290,7 @@ static int tegra210_dmic_put_osr_val(struct snd_kcontrol *kcontrol,
 static int tegra210_dmic_get_pol_sel(struct snd_kcontrol *kcontrol,
                                     struct snd_ctl_elem_value *ucontrol)
 {
-       struct snd_soc_component *comp = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *comp = snd_kcontrol_chip(kcontrol);
        struct tegra210_dmic *dmic = snd_soc_component_get_drvdata(comp);
 
        ucontrol->value.enumerated.item[0] = dmic->lrsel;
@@ -301,7 +301,7 @@ static int tegra210_dmic_get_pol_sel(struct snd_kcontrol *kcontrol,
 static int tegra210_dmic_put_pol_sel(struct snd_kcontrol *kcontrol,
                                     struct snd_ctl_elem_value *ucontrol)
 {
-       struct snd_soc_component *comp = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *comp = snd_kcontrol_chip(kcontrol);
        struct tegra210_dmic *dmic = snd_soc_component_get_drvdata(comp);
        unsigned int value = ucontrol->value.enumerated.item[0];
 
index 100277c390017c6f523b294e900b1815df19e283..b91e0e6cd7fe2db21ea5c7595a07ea788ad68153 100644 (file)
@@ -319,7 +319,7 @@ static int tegra210_i2s_set_tdm_slot(struct snd_soc_dai *dai,
 static int tegra210_i2s_get_loopback(struct snd_kcontrol *kcontrol,
                                     struct snd_ctl_elem_value *ucontrol)
 {
-       struct snd_soc_component *compnt = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *compnt = snd_kcontrol_chip(kcontrol);
        struct tegra210_i2s *i2s = snd_soc_component_get_drvdata(compnt);
 
        ucontrol->value.integer.value[0] = i2s->loopback;
@@ -330,7 +330,7 @@ static int tegra210_i2s_get_loopback(struct snd_kcontrol *kcontrol,
 static int tegra210_i2s_put_loopback(struct snd_kcontrol *kcontrol,
                                     struct snd_ctl_elem_value *ucontrol)
 {
-       struct snd_soc_component *compnt = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *compnt = snd_kcontrol_chip(kcontrol);
        struct tegra210_i2s *i2s = snd_soc_component_get_drvdata(compnt);
        int value = ucontrol->value.integer.value[0];
 
@@ -348,7 +348,7 @@ static int tegra210_i2s_put_loopback(struct snd_kcontrol *kcontrol,
 static int tegra210_i2s_get_fsync_width(struct snd_kcontrol *kcontrol,
                                        struct snd_ctl_elem_value *ucontrol)
 {
-       struct snd_soc_component *compnt = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *compnt = snd_kcontrol_chip(kcontrol);
        struct tegra210_i2s *i2s = snd_soc_component_get_drvdata(compnt);
 
        ucontrol->value.integer.value[0] = i2s->fsync_width;
@@ -359,7 +359,7 @@ static int tegra210_i2s_get_fsync_width(struct snd_kcontrol *kcontrol,
 static int tegra210_i2s_put_fsync_width(struct snd_kcontrol *kcontrol,
                                        struct snd_ctl_elem_value *ucontrol)
 {
-       struct snd_soc_component *compnt = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *compnt = snd_kcontrol_chip(kcontrol);
        struct tegra210_i2s *i2s = snd_soc_component_get_drvdata(compnt);
        int value = ucontrol->value.integer.value[0];
 
@@ -386,7 +386,7 @@ static int tegra210_i2s_put_fsync_width(struct snd_kcontrol *kcontrol,
 static int tegra210_i2s_cget_stereo_to_mono(struct snd_kcontrol *kcontrol,
                                            struct snd_ctl_elem_value *ucontrol)
 {
-       struct snd_soc_component *compnt = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *compnt = snd_kcontrol_chip(kcontrol);
        struct tegra210_i2s *i2s = snd_soc_component_get_drvdata(compnt);
 
        ucontrol->value.enumerated.item[0] = i2s->stereo_to_mono[I2S_TX_PATH];
@@ -397,7 +397,7 @@ static int tegra210_i2s_cget_stereo_to_mono(struct snd_kcontrol *kcontrol,
 static int tegra210_i2s_cput_stereo_to_mono(struct snd_kcontrol *kcontrol,
                                            struct snd_ctl_elem_value *ucontrol)
 {
-       struct snd_soc_component *compnt = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *compnt = snd_kcontrol_chip(kcontrol);
        struct tegra210_i2s *i2s = snd_soc_component_get_drvdata(compnt);
        unsigned int value = ucontrol->value.enumerated.item[0];
 
@@ -412,7 +412,7 @@ static int tegra210_i2s_cput_stereo_to_mono(struct snd_kcontrol *kcontrol,
 static int tegra210_i2s_cget_mono_to_stereo(struct snd_kcontrol *kcontrol,
                                            struct snd_ctl_elem_value *ucontrol)
 {
-       struct snd_soc_component *compnt = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *compnt = snd_kcontrol_chip(kcontrol);
        struct tegra210_i2s *i2s = snd_soc_component_get_drvdata(compnt);
 
        ucontrol->value.enumerated.item[0] = i2s->mono_to_stereo[I2S_TX_PATH];
@@ -423,7 +423,7 @@ static int tegra210_i2s_cget_mono_to_stereo(struct snd_kcontrol *kcontrol,
 static int tegra210_i2s_cput_mono_to_stereo(struct snd_kcontrol *kcontrol,
                                            struct snd_ctl_elem_value *ucontrol)
 {
-       struct snd_soc_component *compnt = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *compnt = snd_kcontrol_chip(kcontrol);
        struct tegra210_i2s *i2s = snd_soc_component_get_drvdata(compnt);
        unsigned int value = ucontrol->value.enumerated.item[0];
 
@@ -438,7 +438,7 @@ static int tegra210_i2s_cput_mono_to_stereo(struct snd_kcontrol *kcontrol,
 static int tegra210_i2s_pget_stereo_to_mono(struct snd_kcontrol *kcontrol,
                                            struct snd_ctl_elem_value *ucontrol)
 {
-       struct snd_soc_component *compnt = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *compnt = snd_kcontrol_chip(kcontrol);
        struct tegra210_i2s *i2s = snd_soc_component_get_drvdata(compnt);
 
        ucontrol->value.enumerated.item[0] = i2s->stereo_to_mono[I2S_RX_PATH];
@@ -449,7 +449,7 @@ static int tegra210_i2s_pget_stereo_to_mono(struct snd_kcontrol *kcontrol,
 static int tegra210_i2s_pput_stereo_to_mono(struct snd_kcontrol *kcontrol,
                                            struct snd_ctl_elem_value *ucontrol)
 {
-       struct snd_soc_component *compnt = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *compnt = snd_kcontrol_chip(kcontrol);
        struct tegra210_i2s *i2s = snd_soc_component_get_drvdata(compnt);
        unsigned int value = ucontrol->value.enumerated.item[0];
 
@@ -464,7 +464,7 @@ static int tegra210_i2s_pput_stereo_to_mono(struct snd_kcontrol *kcontrol,
 static int tegra210_i2s_pget_mono_to_stereo(struct snd_kcontrol *kcontrol,
                                            struct snd_ctl_elem_value *ucontrol)
 {
-       struct snd_soc_component *compnt = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *compnt = snd_kcontrol_chip(kcontrol);
        struct tegra210_i2s *i2s = snd_soc_component_get_drvdata(compnt);
 
        ucontrol->value.enumerated.item[0] = i2s->mono_to_stereo[I2S_RX_PATH];
@@ -475,7 +475,7 @@ static int tegra210_i2s_pget_mono_to_stereo(struct snd_kcontrol *kcontrol,
 static int tegra210_i2s_pput_mono_to_stereo(struct snd_kcontrol *kcontrol,
                                            struct snd_ctl_elem_value *ucontrol)
 {
-       struct snd_soc_component *compnt = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *compnt = snd_kcontrol_chip(kcontrol);
        struct tegra210_i2s *i2s = snd_soc_component_get_drvdata(compnt);
        unsigned int value = ucontrol->value.enumerated.item[0];
 
@@ -490,7 +490,7 @@ static int tegra210_i2s_pput_mono_to_stereo(struct snd_kcontrol *kcontrol,
 static int tegra210_i2s_pget_fifo_th(struct snd_kcontrol *kcontrol,
                                     struct snd_ctl_elem_value *ucontrol)
 {
-       struct snd_soc_component *compnt = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *compnt = snd_kcontrol_chip(kcontrol);
        struct tegra210_i2s *i2s = snd_soc_component_get_drvdata(compnt);
 
        ucontrol->value.integer.value[0] = i2s->rx_fifo_th;
@@ -501,7 +501,7 @@ static int tegra210_i2s_pget_fifo_th(struct snd_kcontrol *kcontrol,
 static int tegra210_i2s_pput_fifo_th(struct snd_kcontrol *kcontrol,
                                     struct snd_ctl_elem_value *ucontrol)
 {
-       struct snd_soc_component *compnt = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *compnt = snd_kcontrol_chip(kcontrol);
        struct tegra210_i2s *i2s = snd_soc_component_get_drvdata(compnt);
        int value = ucontrol->value.integer.value[0];
 
@@ -516,7 +516,7 @@ static int tegra210_i2s_pput_fifo_th(struct snd_kcontrol *kcontrol,
 static int tegra210_i2s_get_bclk_ratio(struct snd_kcontrol *kcontrol,
                                       struct snd_ctl_elem_value *ucontrol)
 {
-       struct snd_soc_component *compnt = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *compnt = snd_kcontrol_chip(kcontrol);
        struct tegra210_i2s *i2s = snd_soc_component_get_drvdata(compnt);
 
        ucontrol->value.integer.value[0] = i2s->bclk_ratio;
@@ -527,7 +527,7 @@ static int tegra210_i2s_get_bclk_ratio(struct snd_kcontrol *kcontrol,
 static int tegra210_i2s_put_bclk_ratio(struct snd_kcontrol *kcontrol,
                                       struct snd_ctl_elem_value *ucontrol)
 {
-       struct snd_soc_component *compnt = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *compnt = snd_kcontrol_chip(kcontrol);
        struct tegra210_i2s *i2s = snd_soc_component_get_drvdata(compnt);
        int value = ucontrol->value.integer.value[0];
 
index eeacb12202685866fc1166e2534c25f1f611a3f3..09fe3c5cf540d8eebd64385acd5ffeec36ed2c7b 100644 (file)
@@ -235,7 +235,7 @@ static int tegra210_mbdrc_get(struct snd_kcontrol *kcontrol,
 {
        struct soc_mixer_control *mc =
                (struct soc_mixer_control *)kcontrol->private_value;
-       struct snd_soc_component *cmpnt = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *cmpnt = snd_kcontrol_chip(kcontrol);
        struct tegra210_ope *ope = snd_soc_component_get_drvdata(cmpnt);
        unsigned int val;
 
@@ -251,7 +251,7 @@ static int tegra210_mbdrc_put(struct snd_kcontrol *kcontrol,
 {
        struct soc_mixer_control *mc =
                (struct soc_mixer_control *)kcontrol->private_value;
-       struct snd_soc_component *cmpnt = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *cmpnt = snd_kcontrol_chip(kcontrol);
        struct tegra210_ope *ope = snd_soc_component_get_drvdata(cmpnt);
        unsigned int val = ucontrol->value.integer.value[0];
        bool change = false;
@@ -267,7 +267,7 @@ static int tegra210_mbdrc_put(struct snd_kcontrol *kcontrol,
 static int tegra210_mbdrc_get_enum(struct snd_kcontrol *kcontrol,
                                   struct snd_ctl_elem_value *ucontrol)
 {
-       struct snd_soc_component *cmpnt = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *cmpnt = snd_kcontrol_chip(kcontrol);
        struct tegra210_ope *ope = snd_soc_component_get_drvdata(cmpnt);
        struct soc_enum *e = (struct soc_enum *)kcontrol->private_value;
        unsigned int val;
@@ -282,7 +282,7 @@ static int tegra210_mbdrc_get_enum(struct snd_kcontrol *kcontrol,
 static int tegra210_mbdrc_put_enum(struct snd_kcontrol *kcontrol,
                                   struct snd_ctl_elem_value *ucontrol)
 {
-       struct snd_soc_component *cmpnt = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *cmpnt = snd_kcontrol_chip(kcontrol);
        struct tegra210_ope *ope = snd_soc_component_get_drvdata(cmpnt);
        struct soc_enum *e = (struct soc_enum *)kcontrol->private_value;
        bool change = false;
@@ -305,7 +305,7 @@ static int tegra210_mbdrc_band_params_get(struct snd_kcontrol *kcontrol,
                                          struct snd_ctl_elem_value *ucontrol)
 {
        struct tegra_soc_bytes *params = (void *)kcontrol->private_value;
-       struct snd_soc_component *cmpnt = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *cmpnt = snd_kcontrol_chip(kcontrol);
        struct tegra210_ope *ope = snd_soc_component_get_drvdata(cmpnt);
        u32 *data = (u32 *)ucontrol->value.bytes.data;
        u32 regs = params->soc.base;
@@ -326,7 +326,7 @@ static int tegra210_mbdrc_band_params_put(struct snd_kcontrol *kcontrol,
                                          struct snd_ctl_elem_value *ucontrol)
 {
        struct tegra_soc_bytes *params = (void *)kcontrol->private_value;
-       struct snd_soc_component *cmpnt = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *cmpnt = snd_kcontrol_chip(kcontrol);
        struct tegra210_ope *ope = snd_soc_component_get_drvdata(cmpnt);
        u32 *data = (u32 *)ucontrol->value.bytes.data;
        u32 regs = params->soc.base;
@@ -351,7 +351,7 @@ static int tegra210_mbdrc_threshold_get(struct snd_kcontrol *kcontrol,
                                        struct snd_ctl_elem_value *ucontrol)
 {
        struct tegra_soc_bytes *params = (void *)kcontrol->private_value;
-       struct snd_soc_component *cmpnt = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *cmpnt = snd_kcontrol_chip(kcontrol);
        struct tegra210_ope *ope = snd_soc_component_get_drvdata(cmpnt);
        u32 *data = (u32 *)ucontrol->value.bytes.data;
        u32 regs = params->soc.base;
@@ -379,7 +379,7 @@ static int tegra210_mbdrc_threshold_put(struct snd_kcontrol *kcontrol,
                                        struct snd_ctl_elem_value *ucontrol)
 {
        struct tegra_soc_bytes *params = (void *)kcontrol->private_value;
-       struct snd_soc_component *cmpnt = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *cmpnt = snd_kcontrol_chip(kcontrol);
        struct tegra210_ope *ope = snd_soc_component_get_drvdata(cmpnt);
        u32 *data = (u32 *)ucontrol->value.bytes.data;
        u32 regs = params->soc.base;
@@ -412,7 +412,7 @@ static int tegra210_mbdrc_biquad_coeffs_get(struct snd_kcontrol *kcontrol,
        struct snd_ctl_elem_value *ucontrol)
 {
        struct tegra_soc_bytes *params = (void *)kcontrol->private_value;
-       struct snd_soc_component *cmpnt = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *cmpnt = snd_kcontrol_chip(kcontrol);
        u32 *data = (u32 *)ucontrol->value.bytes.data;
 
        memset(data, 0, params->soc.num_regs * cmpnt->val_bytes);
@@ -424,7 +424,7 @@ static int tegra210_mbdrc_biquad_coeffs_put(struct snd_kcontrol *kcontrol,
                                            struct snd_ctl_elem_value *ucontrol)
 {
        struct tegra_soc_bytes *params = (void *)kcontrol->private_value;
-       struct snd_soc_component *cmpnt = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *cmpnt = snd_kcontrol_chip(kcontrol);
        struct tegra210_ope *ope = snd_soc_component_get_drvdata(cmpnt);
        u32 reg_ctrl = params->soc.base;
        u32 reg_data = reg_ctrl + cmpnt->val_bytes;
@@ -452,7 +452,7 @@ static int tegra210_mbdrc_vol_get(struct snd_kcontrol *kcontrol,
 {
        struct soc_mixer_control *mc =
                (struct soc_mixer_control *)kcontrol->private_value;
-       struct snd_soc_component *cmpnt = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *cmpnt = snd_kcontrol_chip(kcontrol);
        struct tegra210_ope *ope = snd_soc_component_get_drvdata(cmpnt);
        int val;
 
@@ -469,7 +469,7 @@ static int tegra210_mbdrc_vol_put(struct snd_kcontrol *kcontrol,
 {
        struct soc_mixer_control *mc =
                (struct soc_mixer_control *)kcontrol->private_value;
-       struct snd_soc_component *cmpnt = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *cmpnt = snd_kcontrol_chip(kcontrol);
        struct tegra210_ope *ope = snd_soc_component_get_drvdata(cmpnt);
        int val = ucontrol->value.integer.value[0];
        bool change = false;
index 95d69a7e027f54637f48f3bd021b354b4411ccb5..ff8e9f2d7abfd056a19ecd4a16c44447e0ab4d69 100644 (file)
@@ -178,7 +178,7 @@ static int tegra210_mixer_get_gain(struct snd_kcontrol *kcontrol,
 {
        struct soc_mixer_control *mc =
                (struct soc_mixer_control *)kcontrol->private_value;
-       struct snd_soc_component *cmpnt = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *cmpnt = snd_kcontrol_chip(kcontrol);
        struct tegra210_mixer *mixer = snd_soc_component_get_drvdata(cmpnt);
        unsigned int reg = mc->reg;
        unsigned int i;
@@ -197,7 +197,7 @@ static int tegra210_mixer_apply_gain(struct snd_kcontrol *kcontrol,
 {
        struct soc_mixer_control *mc =
                (struct soc_mixer_control *)kcontrol->private_value;
-       struct snd_soc_component *cmpnt = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *cmpnt = snd_kcontrol_chip(kcontrol);
        struct tegra210_mixer *mixer = snd_soc_component_get_drvdata(cmpnt);
        unsigned int reg = mc->reg, id;
        int err;
index 35b14c8396f4387194ed20f66fdf65b8d2d488e7..779d4c199da939976f2c0b3e42b82c39e73b79de 100644 (file)
@@ -109,7 +109,7 @@ static void tegra210_mvc_conv_vol(struct tegra210_mvc *mvc, u8 chan, s32 val)
 
 static u32 tegra210_mvc_get_ctrl_reg(struct snd_kcontrol *kcontrol)
 {
-       struct snd_soc_component *cmpnt = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *cmpnt = snd_kcontrol_chip(kcontrol);
        struct tegra210_mvc *mvc = snd_soc_component_get_drvdata(cmpnt);
        u32 val;
 
@@ -194,7 +194,7 @@ static int tegra210_mvc_update_mute(struct snd_kcontrol *kcontrol,
                                    struct snd_ctl_elem_value *ucontrol,
                                    bool per_chan_ctrl)
 {
-       struct snd_soc_component *cmpnt = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *cmpnt = snd_kcontrol_chip(kcontrol);
        struct tegra210_mvc *mvc = snd_soc_component_get_drvdata(cmpnt);
        u32 mute_val = ucontrol->value.integer.value[0];
        u32 per_ch_ctrl_val;
@@ -260,7 +260,7 @@ static int tegra210_mvc_get_vol(struct snd_kcontrol *kcontrol,
 {
        struct soc_mixer_control *mc =
                (struct soc_mixer_control *)kcontrol->private_value;
-       struct snd_soc_component *cmpnt = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *cmpnt = snd_kcontrol_chip(kcontrol);
        struct tegra210_mvc *mvc = snd_soc_component_get_drvdata(cmpnt);
        u8 chan = TEGRA210_MVC_GET_CHAN(mc->reg, TEGRA210_MVC_TARGET_VOL);
        s32 val = mvc->volume[chan];
@@ -289,7 +289,7 @@ static int tegra210_mvc_update_vol(struct snd_kcontrol *kcontrol,
 {
        struct soc_mixer_control *mc =
                (struct soc_mixer_control *)kcontrol->private_value;
-       struct snd_soc_component *cmpnt = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *cmpnt = snd_kcontrol_chip(kcontrol);
        struct tegra210_mvc *mvc = snd_soc_component_get_drvdata(cmpnt);
        u8 chan = TEGRA210_MVC_GET_CHAN(mc->reg, TEGRA210_MVC_TARGET_VOL);
        int old_volume = mvc->volume[chan];
@@ -394,7 +394,7 @@ static void tegra210_mvc_reset_vol_settings(struct tegra210_mvc *mvc,
 static int tegra210_mvc_get_curve_type(struct snd_kcontrol *kcontrol,
                                       struct snd_ctl_elem_value *ucontrol)
 {
-       struct snd_soc_component *cmpnt = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *cmpnt = snd_kcontrol_chip(kcontrol);
        struct tegra210_mvc *mvc = snd_soc_component_get_drvdata(cmpnt);
 
        ucontrol->value.enumerated.item[0] = mvc->curve_type;
@@ -405,7 +405,7 @@ static int tegra210_mvc_get_curve_type(struct snd_kcontrol *kcontrol,
 static int tegra210_mvc_put_curve_type(struct snd_kcontrol *kcontrol,
                                       struct snd_ctl_elem_value *ucontrol)
 {
-       struct snd_soc_component *cmpnt = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *cmpnt = snd_kcontrol_chip(kcontrol);
        struct tegra210_mvc *mvc = snd_soc_component_get_drvdata(cmpnt);
        unsigned int value;
 
index 5036bcfe082892951429c219a9ffb113e6ba53ff..27db70af27469929f2ba9df4a8599670a31ebc5e 100644 (file)
@@ -202,7 +202,7 @@ static const struct soc_enum tegra210_ope_data_dir_enum =
 static int tegra210_ope_get_data_dir(struct snd_kcontrol *kcontrol,
                                     struct snd_ctl_elem_value *ucontrol)
 {
-       struct snd_soc_component *cmpnt = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *cmpnt = snd_kcontrol_chip(kcontrol);
        struct tegra210_ope *ope = snd_soc_component_get_drvdata(cmpnt);
 
        ucontrol->value.enumerated.item[0] = ope->data_dir;
@@ -213,7 +213,7 @@ static int tegra210_ope_get_data_dir(struct snd_kcontrol *kcontrol,
 static int tegra210_ope_put_data_dir(struct snd_kcontrol *kcontrol,
                                     struct snd_ctl_elem_value *ucontrol)
 {
-       struct snd_soc_component *cmpnt = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *cmpnt = snd_kcontrol_chip(kcontrol);
        struct tegra210_ope *ope = snd_soc_component_get_drvdata(cmpnt);
        unsigned int value = ucontrol->value.enumerated.item[0];
 
index bd8007cc49e1c2c1adeb94223f4ff07a0d53daf4..9a05e6913276c7675ce3ba361ae0b83c3a132f8a 100644 (file)
@@ -100,7 +100,7 @@ static int tegra210_peq_get(struct snd_kcontrol *kcontrol,
 {
        struct soc_mixer_control *mc =
                (struct soc_mixer_control *)kcontrol->private_value;
-       struct snd_soc_component *cmpnt = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *cmpnt = snd_kcontrol_chip(kcontrol);
        struct tegra210_ope *ope = snd_soc_component_get_drvdata(cmpnt);
        unsigned int mask = (1 << fls(mc->max)) - 1;
        unsigned int val;
@@ -123,7 +123,7 @@ static int tegra210_peq_put(struct snd_kcontrol *kcontrol,
 {
        struct soc_mixer_control *mc =
                (struct soc_mixer_control *)kcontrol->private_value;
-       struct snd_soc_component *cmpnt = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *cmpnt = snd_kcontrol_chip(kcontrol);
        struct tegra210_ope *ope = snd_soc_component_get_drvdata(cmpnt);
        unsigned int mask = (1 << fls(mc->max)) - 1;
        bool change = false;
@@ -146,7 +146,7 @@ static int tegra210_peq_ram_get(struct snd_kcontrol *kcontrol,
                                struct snd_ctl_elem_value *ucontrol)
 {
        struct tegra_soc_bytes *params = (void *)kcontrol->private_value;
-       struct snd_soc_component *cmpnt = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *cmpnt = snd_kcontrol_chip(kcontrol);
        struct tegra210_ope *ope = snd_soc_component_get_drvdata(cmpnt);
        u32 i, reg_ctrl = params->soc.base;
        u32 reg_data = reg_ctrl + cmpnt->val_bytes;
@@ -169,7 +169,7 @@ static int tegra210_peq_ram_put(struct snd_kcontrol *kcontrol,
                                     struct snd_ctl_elem_value *ucontrol)
 {
        struct tegra_soc_bytes *params = (void *)kcontrol->private_value;
-       struct snd_soc_component *cmpnt = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *cmpnt = snd_kcontrol_chip(kcontrol);
        struct tegra210_ope *ope = snd_soc_component_get_drvdata(cmpnt);
        u32 i, reg_ctrl = params->soc.base;
        u32 reg_data = reg_ctrl + cmpnt->val_bytes;
index a0bd36f12c68fe48985499ced696ad28bb59d18d..d6341968bebeeb0d1528c7c1b2f49767c8ae1116 100644 (file)
@@ -3276,7 +3276,7 @@ static int tegra210_sfc_init(struct snd_soc_dapm_widget *w,
 static int tegra210_sfc_iget_stereo_to_mono(struct snd_kcontrol *kcontrol,
                                    struct snd_ctl_elem_value *ucontrol)
 {
-       struct snd_soc_component *cmpnt = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *cmpnt = snd_kcontrol_chip(kcontrol);
        struct tegra210_sfc *sfc = snd_soc_component_get_drvdata(cmpnt);
 
        ucontrol->value.enumerated.item[0] = sfc->stereo_to_mono[SFC_RX_PATH];
@@ -3287,7 +3287,7 @@ static int tegra210_sfc_iget_stereo_to_mono(struct snd_kcontrol *kcontrol,
 static int tegra210_sfc_iput_stereo_to_mono(struct snd_kcontrol *kcontrol,
                                    struct snd_ctl_elem_value *ucontrol)
 {
-       struct snd_soc_component *cmpnt = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *cmpnt = snd_kcontrol_chip(kcontrol);
        struct tegra210_sfc *sfc = snd_soc_component_get_drvdata(cmpnt);
        unsigned int value = ucontrol->value.enumerated.item[0];
 
@@ -3302,7 +3302,7 @@ static int tegra210_sfc_iput_stereo_to_mono(struct snd_kcontrol *kcontrol,
 static int tegra210_sfc_iget_mono_to_stereo(struct snd_kcontrol *kcontrol,
                                    struct snd_ctl_elem_value *ucontrol)
 {
-       struct snd_soc_component *cmpnt = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *cmpnt = snd_kcontrol_chip(kcontrol);
        struct tegra210_sfc *sfc = snd_soc_component_get_drvdata(cmpnt);
 
        ucontrol->value.enumerated.item[0] = sfc->mono_to_stereo[SFC_RX_PATH];
@@ -3313,7 +3313,7 @@ static int tegra210_sfc_iget_mono_to_stereo(struct snd_kcontrol *kcontrol,
 static int tegra210_sfc_iput_mono_to_stereo(struct snd_kcontrol *kcontrol,
                                    struct snd_ctl_elem_value *ucontrol)
 {
-       struct snd_soc_component *cmpnt = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *cmpnt = snd_kcontrol_chip(kcontrol);
        struct tegra210_sfc *sfc = snd_soc_component_get_drvdata(cmpnt);
        unsigned int value = ucontrol->value.enumerated.item[0];
 
@@ -3328,7 +3328,7 @@ static int tegra210_sfc_iput_mono_to_stereo(struct snd_kcontrol *kcontrol,
 static int tegra210_sfc_oget_stereo_to_mono(struct snd_kcontrol *kcontrol,
                                    struct snd_ctl_elem_value *ucontrol)
 {
-       struct snd_soc_component *cmpnt = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *cmpnt = snd_kcontrol_chip(kcontrol);
        struct tegra210_sfc *sfc = snd_soc_component_get_drvdata(cmpnt);
 
        ucontrol->value.enumerated.item[0] = sfc->stereo_to_mono[SFC_TX_PATH];
@@ -3339,7 +3339,7 @@ static int tegra210_sfc_oget_stereo_to_mono(struct snd_kcontrol *kcontrol,
 static int tegra210_sfc_oput_stereo_to_mono(struct snd_kcontrol *kcontrol,
                                    struct snd_ctl_elem_value *ucontrol)
 {
-       struct snd_soc_component *cmpnt = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *cmpnt = snd_kcontrol_chip(kcontrol);
        struct tegra210_sfc *sfc = snd_soc_component_get_drvdata(cmpnt);
        unsigned int value = ucontrol->value.enumerated.item[0];
 
@@ -3354,7 +3354,7 @@ static int tegra210_sfc_oput_stereo_to_mono(struct snd_kcontrol *kcontrol,
 static int tegra210_sfc_oget_mono_to_stereo(struct snd_kcontrol *kcontrol,
                                    struct snd_ctl_elem_value *ucontrol)
 {
-       struct snd_soc_component *cmpnt = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *cmpnt = snd_kcontrol_chip(kcontrol);
        struct tegra210_sfc *sfc = snd_soc_component_get_drvdata(cmpnt);
 
        ucontrol->value.enumerated.item[0] = sfc->mono_to_stereo[SFC_TX_PATH];
@@ -3365,7 +3365,7 @@ static int tegra210_sfc_oget_mono_to_stereo(struct snd_kcontrol *kcontrol,
 static int tegra210_sfc_oput_mono_to_stereo(struct snd_kcontrol *kcontrol,
                                    struct snd_ctl_elem_value *ucontrol)
 {
-       struct snd_soc_component *cmpnt = snd_soc_kcontrol_component(kcontrol);
+       struct snd_soc_component *cmpnt = snd_kcontrol_chip(kcontrol);
        struct tegra210_sfc *sfc = snd_soc_component_get_drvdata(cmpnt);
        unsigned int value = ucontrol->value.enumerated.item[0];