Lines Matching refs:component
59 struct snd_soc_component *component = snd_soc_dapm_to_component(w->dapm); in aic32x4_reset_adc() local
69 adc_reg = snd_soc_component_read(component, AIC32X4_ADCSETUP); in aic32x4_reset_adc()
70 snd_soc_component_write(component, AIC32X4_ADCSETUP, adc_reg | in aic32x4_reset_adc()
72 snd_soc_component_write(component, AIC32X4_ADCSETUP, adc_reg); in aic32x4_reset_adc()
81 struct snd_soc_component *component = snd_soc_dapm_to_component(w->dapm); in mic_bias_event() local
86 snd_soc_component_update_bits(component, AIC32X4_MICBIAS, in mic_bias_event()
93 snd_soc_component_update_bits(component, AIC32X4_MICBIAS, in mic_bias_event()
107 struct snd_soc_component *component = snd_kcontrol_chip(kcontrol); in aic32x4_get_mfp1_gpio() local
110 val = snd_soc_component_read(component, AIC32X4_DINCTL); in aic32x4_get_mfp1_gpio()
120 struct snd_soc_component *component = snd_kcontrol_chip(kcontrol); in aic32x4_set_mfp2_gpio() local
124 val = snd_soc_component_read(component, AIC32X4_DOUTCTL); in aic32x4_set_mfp2_gpio()
140 snd_soc_component_write(component, AIC32X4_DOUTCTL, val); in aic32x4_set_mfp2_gpio()
148 struct snd_soc_component *component = snd_kcontrol_chip(kcontrol); in aic32x4_get_mfp3_gpio() local
151 val = snd_soc_component_read(component, AIC32X4_SCLKCTL); in aic32x4_get_mfp3_gpio()
161 struct snd_soc_component *component = snd_kcontrol_chip(kcontrol); in aic32x4_set_mfp4_gpio() local
165 val = snd_soc_component_read(component, AIC32X4_MISOCTL); in aic32x4_set_mfp4_gpio()
181 snd_soc_component_write(component, AIC32X4_MISOCTL, val); in aic32x4_set_mfp4_gpio()
189 struct snd_soc_component *component = snd_kcontrol_chip(kcontrol); in aic32x4_get_mfp5_gpio() local
192 val = snd_soc_component_read(component, AIC32X4_GPIOCTL); in aic32x4_get_mfp5_gpio()
201 struct snd_soc_component *component = snd_kcontrol_chip(kcontrol); in aic32x4_set_mfp5_gpio() local
205 val = snd_soc_component_read(component, AIC32X4_GPIOCTL); in aic32x4_set_mfp5_gpio()
221 snd_soc_component_write(component, AIC32X4_GPIOCTL, val); in aic32x4_set_mfp5_gpio()
600 struct snd_soc_component *component = codec_dai->component; in aic32x4_set_dai_sysclk() local
604 pll = devm_clk_get(component->dev, "pll"); in aic32x4_set_dai_sysclk()
615 struct snd_soc_component *component = codec_dai->component; in aic32x4_set_dai_fmt() local
616 struct aic32x4_priv *aic32x4 = snd_soc_component_get_drvdata(component); in aic32x4_set_dai_fmt()
661 snd_soc_component_update_bits(component, AIC32X4_IFACE1, in aic32x4_set_dai_fmt()
664 snd_soc_component_update_bits(component, AIC32X4_IFACE2, in aic32x4_set_dai_fmt()
666 snd_soc_component_update_bits(component, AIC32X4_IFACE3, in aic32x4_set_dai_fmt()
672 static int aic32x4_set_aosr(struct snd_soc_component *component, u8 aosr) in aic32x4_set_aosr() argument
674 return snd_soc_component_write(component, AIC32X4_AOSR, aosr); in aic32x4_set_aosr()
677 static int aic32x4_set_dosr(struct snd_soc_component *component, u16 dosr) in aic32x4_set_dosr() argument
679 snd_soc_component_write(component, AIC32X4_DOSRMSB, dosr >> 8); in aic32x4_set_dosr()
680 snd_soc_component_write(component, AIC32X4_DOSRLSB, in aic32x4_set_dosr()
686 static int aic32x4_set_processing_blocks(struct snd_soc_component *component, in aic32x4_set_processing_blocks() argument
689 struct aic32x4_priv *aic32x4 = snd_soc_component_get_drvdata(component); in aic32x4_set_processing_blocks()
695 snd_soc_component_write(component, AIC32X4_DACSPB, p_block); in aic32x4_set_processing_blocks()
700 snd_soc_component_write(component, AIC32X4_ADCSPB, r_block); in aic32x4_set_processing_blocks()
701 snd_soc_component_write(component, AIC32X4_DACSPB, p_block); in aic32x4_set_processing_blocks()
707 static int aic32x4_setup_clocks(struct snd_soc_component *component, in aic32x4_setup_clocks() argument
711 struct aic32x4_priv *aic32x4 = snd_soc_component_get_drvdata(component); in aic32x4_setup_clocks()
729 ret = devm_clk_bulk_get(component->dev, ARRAY_SIZE(clocks), clocks); in aic32x4_setup_clocks()
739 aic32x4_set_processing_blocks(component, 0, 1); in aic32x4_setup_clocks()
741 aic32x4_set_processing_blocks(component, 1, 1); in aic32x4_setup_clocks()
748 aic32x4_set_processing_blocks(component, 0, 1); in aic32x4_setup_clocks()
750 aic32x4_set_processing_blocks(component, 1, 9); in aic32x4_setup_clocks()
757 aic32x4_set_processing_blocks(component, 0, 1); in aic32x4_setup_clocks()
759 aic32x4_set_processing_blocks(component, 13, 19); in aic32x4_setup_clocks()
761 dev_err(component->dev, "Sampling rate not supported\n"); in aic32x4_setup_clocks()
799 aic32x4_set_aosr(component, in aic32x4_setup_clocks()
807 aic32x4_set_dosr(component, in aic32x4_setup_clocks()
821 dev_err(component->dev, in aic32x4_setup_clocks()
830 struct snd_soc_component *component = dai->component; in aic32x4_hw_params() local
831 struct aic32x4_priv *aic32x4 = snd_soc_component_get_drvdata(component); in aic32x4_hw_params()
835 aic32x4_setup_clocks(component, params_rate(params), in aic32x4_hw_params()
857 snd_soc_component_update_bits(component, AIC32X4_IFACE1, in aic32x4_hw_params()
868 snd_soc_component_update_bits(component, AIC32X4_DACSETUP, in aic32x4_hw_params()
876 struct snd_soc_component *component = dai->component; in aic32x4_mute() local
878 snd_soc_component_update_bits(component, AIC32X4_DACMUTE, in aic32x4_mute()
884 static int aic32x4_set_bias_level(struct snd_soc_component *component, in aic32x4_set_bias_level() argument
895 ret = devm_clk_bulk_get(component->dev, ARRAY_SIZE(clocks), clocks); in aic32x4_set_bias_level()
903 dev_err(component->dev, "Failed to enable clocks\n"); in aic32x4_set_bias_level()
911 if (snd_soc_component_get_bias_level(component) == SND_SOC_BIAS_OFF) in aic32x4_set_bias_level()
953 static void aic32x4_setup_gpios(struct snd_soc_component *component) in aic32x4_setup_gpios() argument
955 struct aic32x4_priv *aic32x4 = snd_soc_component_get_drvdata(component); in aic32x4_setup_gpios()
960 snd_soc_component_write(component, AIC32X4_DINCTL, in aic32x4_setup_gpios()
962 snd_soc_add_component_controls(component, aic32x4_mfp1, in aic32x4_setup_gpios()
968 snd_soc_component_write(component, AIC32X4_DOUTCTL, in aic32x4_setup_gpios()
970 snd_soc_add_component_controls(component, aic32x4_mfp2, in aic32x4_setup_gpios()
976 snd_soc_component_write(component, AIC32X4_SCLKCTL, in aic32x4_setup_gpios()
978 snd_soc_add_component_controls(component, aic32x4_mfp3, in aic32x4_setup_gpios()
984 snd_soc_component_write(component, AIC32X4_MISOCTL, in aic32x4_setup_gpios()
986 snd_soc_add_component_controls(component, aic32x4_mfp4, in aic32x4_setup_gpios()
992 snd_soc_component_write(component, AIC32X4_GPIOCTL, in aic32x4_setup_gpios()
994 snd_soc_add_component_controls(component, aic32x4_mfp5, in aic32x4_setup_gpios()
999 static int aic32x4_component_probe(struct snd_soc_component *component) in aic32x4_component_probe() argument
1001 struct aic32x4_priv *aic32x4 = snd_soc_component_get_drvdata(component); in aic32x4_component_probe()
1012 ret = devm_clk_bulk_get(component->dev, ARRAY_SIZE(clocks), clocks); in aic32x4_component_probe()
1017 aic32x4_setup_gpios(component); in aic32x4_component_probe()
1024 snd_soc_component_write(component, AIC32X4_MICBIAS, in aic32x4_component_probe()
1028 snd_soc_component_write(component, AIC32X4_PWRCFG, AIC32X4_AVDDWEAKDISABLE); in aic32x4_component_probe()
1032 snd_soc_component_write(component, AIC32X4_LDOCTL, tmp_reg); in aic32x4_component_probe()
1034 tmp_reg = snd_soc_component_read(component, AIC32X4_CMMODE); in aic32x4_component_probe()
1039 snd_soc_component_write(component, AIC32X4_CMMODE, tmp_reg); in aic32x4_component_probe()
1043 snd_soc_component_write(component, AIC32X4_LMICPGANIN, in aic32x4_component_probe()
1046 snd_soc_component_write(component, AIC32X4_LMICPGANIN, in aic32x4_component_probe()
1049 snd_soc_component_write(component, AIC32X4_RMICPGANIN, in aic32x4_component_probe()
1052 snd_soc_component_write(component, AIC32X4_RMICPGANIN, in aic32x4_component_probe()
1060 tmp_reg = snd_soc_component_read(component, AIC32X4_ADCSETUP); in aic32x4_component_probe()
1061 snd_soc_component_write(component, AIC32X4_ADCSETUP, tmp_reg | in aic32x4_component_probe()
1063 snd_soc_component_write(component, AIC32X4_ADCSETUP, tmp_reg); in aic32x4_component_probe()
1069 snd_soc_component_write(component, AIC32X4_REFPOWERUP, in aic32x4_component_probe()
1148 static int aic32x4_tas2505_component_probe(struct snd_soc_component *component) in aic32x4_tas2505_component_probe() argument
1150 struct aic32x4_priv *aic32x4 = snd_soc_component_get_drvdata(component); in aic32x4_tas2505_component_probe()
1161 ret = devm_clk_bulk_get(component->dev, ARRAY_SIZE(clocks), clocks); in aic32x4_tas2505_component_probe()
1166 aic32x4_setup_gpios(component); in aic32x4_tas2505_component_probe()
1173 snd_soc_component_write(component, AIC32X4_PWRCFG, AIC32X4_AVDDWEAKDISABLE); in aic32x4_tas2505_component_probe()
1177 snd_soc_component_write(component, AIC32X4_LDOCTL, tmp_reg); in aic32x4_tas2505_component_probe()
1179 tmp_reg = snd_soc_component_read(component, AIC32X4_CMMODE); in aic32x4_tas2505_component_probe()
1184 snd_soc_component_write(component, AIC32X4_CMMODE, tmp_reg); in aic32x4_tas2505_component_probe()
1190 snd_soc_component_write(component, TAS2505_REFPOWERUP, in aic32x4_tas2505_component_probe()