• Home
  • Raw
  • Download

Lines Matching full:component

35 void da7219_aad_jack_det(struct snd_soc_component *component, struct snd_soc_jack *jack)  in da7219_aad_jack_det()  argument
37 struct da7219_priv *da7219 = snd_soc_component_get_drvdata(component); in da7219_aad_jack_det()
46 snd_soc_component_update_bits(component, DA7219_ACCDET_CONFIG_1, in da7219_aad_jack_det()
60 struct snd_soc_component *component = da7219_aad->component; in da7219_aad_btn_det_work() local
61 struct snd_soc_dapm_context *dapm = snd_soc_component_get_dapm(component); in da7219_aad_btn_det_work()
62 struct da7219_priv *da7219 = snd_soc_component_get_drvdata(component); in da7219_aad_btn_det_work()
68 snd_soc_component_update_bits(component, DA7219_HP_L_CTRL, in da7219_aad_btn_det_work()
71 snd_soc_component_update_bits(component, DA7219_HP_R_CTRL, in da7219_aad_btn_det_work()
80 statusa = snd_soc_component_read32(component, DA7219_ACCDET_STATUS_A); in da7219_aad_btn_det_work()
88 dev_warn(component->dev, "Mic bias status check timed out"); in da7219_aad_btn_det_work()
98 micbias_ctrl = snd_soc_component_read32(component, DA7219_MICBIAS_CTRL); in da7219_aad_btn_det_work()
99 snd_soc_component_update_bits(component, DA7219_MICBIAS_CTRL, in da7219_aad_btn_det_work()
103 snd_soc_component_write(component, DA7219_MICBIAS_CTRL, micbias_ctrl); in da7219_aad_btn_det_work()
107 snd_soc_component_update_bits(component, DA7219_ACCDET_CONFIG_1, in da7219_aad_btn_det_work()
116 struct snd_soc_component *component = da7219_aad->component; in da7219_aad_hptest_work() local
117 struct snd_soc_dapm_context *dapm = snd_soc_component_get_dapm(component); in da7219_aad_hptest_work()
118 struct da7219_priv *da7219 = snd_soc_component_get_drvdata(component); in da7219_aad_hptest_work()
133 dev_err(component->dev, "Failed to enable mclk - %d\n", ret); in da7219_aad_hptest_work()
148 pll_srm_sts = snd_soc_component_read32(component, DA7219_PLL_SRM_STS); in da7219_aad_hptest_work()
152 pll_ctrl = snd_soc_component_read32(component, DA7219_PLL_CTRL); in da7219_aad_hptest_work()
154 da7219_set_pll(component, DA7219_SYSCLK_PLL, in da7219_aad_hptest_work()
161 gain_ramp_ctrl = snd_soc_component_read32(component, DA7219_GAIN_RAMP_CTRL); in da7219_aad_hptest_work()
162 snd_soc_component_write(component, DA7219_GAIN_RAMP_CTRL, DA7219_GAIN_RAMP_RATE_X8); in da7219_aad_hptest_work()
168 snd_soc_component_write(component, DA7219_TONE_GEN_CFG1, 0); in da7219_aad_hptest_work()
171 snd_soc_component_update_bits(component, DA7219_ACCDET_CONFIG_8, in da7219_aad_hptest_work()
177 snd_soc_component_write(component, DA7219_DAC_L_GAIN, DA7219_DAC_DIGITAL_GAIN_0DB); in da7219_aad_hptest_work()
178 snd_soc_component_write(component, DA7219_DAC_R_GAIN, DA7219_DAC_DIGITAL_GAIN_0DB); in da7219_aad_hptest_work()
179 snd_soc_component_write(component, DA7219_HP_L_GAIN, DA7219_HP_AMP_GAIN_0DB); in da7219_aad_hptest_work()
180 snd_soc_component_write(component, DA7219_HP_R_GAIN, DA7219_HP_AMP_GAIN_0DB); in da7219_aad_hptest_work()
183 snd_soc_component_update_bits(component, DA7219_DAC_FILTERS1, DA7219_HPF_MODE_MASK, in da7219_aad_hptest_work()
185 snd_soc_component_update_bits(component, DA7219_DAC_FILTERS4, DA7219_DAC_EQ_EN_MASK, in da7219_aad_hptest_work()
187 snd_soc_component_update_bits(component, DA7219_DAC_FILTERS5, in da7219_aad_hptest_work()
191 snd_soc_component_update_bits(component, DA7219_CP_CTRL, DA7219_CP_EN_MASK, in da7219_aad_hptest_work()
193 snd_soc_component_update_bits(component, DA7219_DIG_ROUTING_DAC, in da7219_aad_hptest_work()
197 snd_soc_component_update_bits(component, DA7219_DAC_L_CTRL, in da7219_aad_hptest_work()
200 snd_soc_component_update_bits(component, DA7219_DAC_R_CTRL, in da7219_aad_hptest_work()
203 snd_soc_component_update_bits(component, DA7219_MIXOUT_L_SELECT, in da7219_aad_hptest_work()
206 snd_soc_component_update_bits(component, DA7219_MIXOUT_R_SELECT, in da7219_aad_hptest_work()
209 snd_soc_component_update_bits(component, DA7219_DROUTING_ST_OUTFILT_1L, in da7219_aad_hptest_work()
212 snd_soc_component_update_bits(component, DA7219_DROUTING_ST_OUTFILT_1R, in da7219_aad_hptest_work()
215 snd_soc_component_update_bits(component, DA7219_MIXOUT_L_CTRL, in da7219_aad_hptest_work()
218 snd_soc_component_update_bits(component, DA7219_MIXOUT_R_CTRL, in da7219_aad_hptest_work()
221 snd_soc_component_update_bits(component, DA7219_HP_L_CTRL, in da7219_aad_hptest_work()
224 snd_soc_component_update_bits(component, DA7219_HP_R_CTRL, in da7219_aad_hptest_work()
228 snd_soc_component_update_bits(component, DA7219_HP_L_CTRL, in da7219_aad_hptest_work()
231 snd_soc_component_update_bits(component, DA7219_HP_R_CTRL, in da7219_aad_hptest_work()
243 snd_soc_component_write(component, DA7219_TONE_GEN_ON_PER, DA7219_BEEP_ON_PER_MASK); in da7219_aad_hptest_work()
246 snd_soc_component_update_bits(component, DA7219_TONE_GEN_CFG2, in da7219_aad_hptest_work()
250 snd_soc_component_write(component, DA7219_TONE_GEN_CFG1, DA7219_START_STOPN_MASK); in da7219_aad_hptest_work()
255 accdet_cfg8 = snd_soc_component_read32(component, DA7219_ACCDET_CONFIG_8); in da7219_aad_hptest_work()
262 snd_soc_component_write(component, DA7219_TONE_GEN_CFG1, 0); in da7219_aad_hptest_work()
300 snd_soc_component_update_bits(component, DA7219_ACCDET_CONFIG_8, in da7219_aad_hptest_work()
311 snd_soc_component_write(component, DA7219_GAIN_RAMP_CTRL, gain_ramp_ctrl); in da7219_aad_hptest_work()
314 snd_soc_component_update_bits(component, DA7219_HP_L_CTRL, DA7219_HP_L_AMP_OE_MASK, in da7219_aad_hptest_work()
316 snd_soc_component_update_bits(component, DA7219_HP_R_CTRL, DA7219_HP_R_AMP_OE_MASK, in da7219_aad_hptest_work()
322 da7219_set_pll(component, DA7219_SYSCLK_MCLK, 0); in da7219_aad_hptest_work()
349 struct snd_soc_component *component = da7219_aad->component; in da7219_aad_irq_thread() local
350 struct snd_soc_dapm_context *dapm = snd_soc_component_get_dapm(component); in da7219_aad_irq_thread()
351 struct da7219_priv *da7219 = snd_soc_component_get_drvdata(component); in da7219_aad_irq_thread()
364 statusa = snd_soc_component_read32(component, DA7219_ACCDET_STATUS_A); in da7219_aad_irq_thread()
370 dev_dbg(component->dev, "IRQ events = 0x%x|0x%x, status = 0x%x\n", in da7219_aad_irq_thread()
436 snd_soc_component_update_bits(component, DA7219_HP_R_CTRL, in da7219_aad_irq_thread()
438 snd_soc_component_update_bits(component, DA7219_HP_L_CTRL, in da7219_aad_irq_thread()
442 snd_soc_component_update_bits(component, DA7219_ACCDET_CONFIG_1, in da7219_aad_irq_thread()
467 da7219_aad_fw_micbias_pulse_lvl(struct snd_soc_component *component, u32 val) in da7219_aad_fw_micbias_pulse_lvl() argument
475 dev_warn(component->dev, "Invalid micbias pulse level"); in da7219_aad_fw_micbias_pulse_lvl()
481 da7219_aad_fw_btn_cfg(struct snd_soc_component *component, u32 val) in da7219_aad_fw_btn_cfg() argument
499 dev_warn(component->dev, "Invalid button config"); in da7219_aad_fw_btn_cfg()
505 da7219_aad_fw_mic_det_thr(struct snd_soc_component *component, u32 val) in da7219_aad_fw_mic_det_thr() argument
517 dev_warn(component->dev, "Invalid mic detect threshold"); in da7219_aad_fw_mic_det_thr()
523 da7219_aad_fw_jack_ins_deb(struct snd_soc_component *component, u32 val) in da7219_aad_fw_jack_ins_deb() argument
543 dev_warn(component->dev, "Invalid jack insert debounce"); in da7219_aad_fw_jack_ins_deb()
549 da7219_aad_fw_jack_det_rate(struct snd_soc_component *component, const char *str) in da7219_aad_fw_jack_det_rate() argument
560 dev_warn(component->dev, "Invalid jack detect rate"); in da7219_aad_fw_jack_det_rate()
566 da7219_aad_fw_jack_rem_deb(struct snd_soc_component *component, u32 val) in da7219_aad_fw_jack_rem_deb() argument
578 dev_warn(component->dev, "Invalid jack removal debounce"); in da7219_aad_fw_jack_rem_deb()
584 da7219_aad_fw_btn_avg(struct snd_soc_component *component, u32 val) in da7219_aad_fw_btn_avg() argument
596 dev_warn(component->dev, "Invalid button average value"); in da7219_aad_fw_btn_avg()
602 da7219_aad_fw_adc_1bit_rpt(struct snd_soc_component *component, u32 val) in da7219_aad_fw_adc_1bit_rpt() argument
614 dev_warn(component->dev, "Invalid ADC 1-bit repeat value"); in da7219_aad_fw_adc_1bit_rpt()
619 static struct da7219_aad_pdata *da7219_aad_fw_to_pdata(struct snd_soc_component *component) in da7219_aad_fw_to_pdata() argument
621 struct device *dev = component->dev; in da7219_aad_fw_to_pdata()
641 da7219_aad_fw_micbias_pulse_lvl(component, fw_val32); in da7219_aad_fw_to_pdata()
650 aad_pdata->btn_cfg = da7219_aad_fw_btn_cfg(component, fw_val32); in da7219_aad_fw_to_pdata()
656 da7219_aad_fw_mic_det_thr(component, fw_val32); in da7219_aad_fw_to_pdata()
662 da7219_aad_fw_jack_ins_deb(component, fw_val32); in da7219_aad_fw_to_pdata()
668 da7219_aad_fw_jack_det_rate(component, fw_str); in da7219_aad_fw_to_pdata()
674 da7219_aad_fw_jack_rem_deb(component, fw_val32); in da7219_aad_fw_to_pdata()
699 aad_pdata->btn_avg = da7219_aad_fw_btn_avg(component, fw_val32); in da7219_aad_fw_to_pdata()
705 da7219_aad_fw_adc_1bit_rpt(component, fw_val32); in da7219_aad_fw_to_pdata()
712 static void da7219_aad_handle_pdata(struct snd_soc_component *component) in da7219_aad_handle_pdata() argument
714 struct da7219_priv *da7219 = snd_soc_component_get_drvdata(component); in da7219_aad_handle_pdata()
760 snd_soc_component_update_bits(component, DA7219_ACCDET_CONFIG_1, mask, cfg); in da7219_aad_handle_pdata()
795 snd_soc_component_update_bits(component, DA7219_ACCDET_CONFIG_2, mask, cfg); in da7219_aad_handle_pdata()
797 snd_soc_component_write(component, DA7219_ACCDET_CONFIG_3, in da7219_aad_handle_pdata()
799 snd_soc_component_write(component, DA7219_ACCDET_CONFIG_4, in da7219_aad_handle_pdata()
801 snd_soc_component_write(component, DA7219_ACCDET_CONFIG_5, in da7219_aad_handle_pdata()
803 snd_soc_component_write(component, DA7219_ACCDET_CONFIG_6, in da7219_aad_handle_pdata()
826 snd_soc_component_update_bits(component, DA7219_ACCDET_CONFIG_7, mask, cfg); in da7219_aad_handle_pdata()
835 void da7219_aad_suspend(struct snd_soc_component *component) in da7219_aad_suspend() argument
837 struct da7219_priv *da7219 = snd_soc_component_get_drvdata(component); in da7219_aad_suspend()
839 struct snd_soc_dapm_context *dapm = snd_soc_component_get_dapm(component); in da7219_aad_suspend()
844 snd_soc_component_update_bits(component, DA7219_ACCDET_CONFIG_1, in da7219_aad_suspend()
854 micbias_ctrl = snd_soc_component_read32(component, DA7219_MICBIAS_CTRL); in da7219_aad_suspend()
864 void da7219_aad_resume(struct snd_soc_component *component) in da7219_aad_resume() argument
866 struct da7219_priv *da7219 = snd_soc_component_get_drvdata(component); in da7219_aad_resume()
868 struct snd_soc_dapm_context *dapm = snd_soc_component_get_dapm(component); in da7219_aad_resume()
880 snd_soc_component_update_bits(component, DA7219_ACCDET_CONFIG_1, in da7219_aad_resume()
891 int da7219_aad_init(struct snd_soc_component *component) in da7219_aad_init() argument
893 struct da7219_priv *da7219 = snd_soc_component_get_drvdata(component); in da7219_aad_init()
898 da7219_aad = devm_kzalloc(component->dev, sizeof(*da7219_aad), GFP_KERNEL); in da7219_aad_init()
903 da7219_aad->component = component; in da7219_aad_init()
907 da7219->pdata->aad_pdata = da7219_aad_fw_to_pdata(component); in da7219_aad_init()
909 da7219_aad_handle_pdata(component); in da7219_aad_init()
912 snd_soc_component_update_bits(component, DA7219_ACCDET_CONFIG_1, in da7219_aad_init()
923 dev_err(component->dev, "Failed to request IRQ: %d\n", ret); in da7219_aad_init()
936 void da7219_aad_exit(struct snd_soc_component *component) in da7219_aad_exit() argument
938 struct da7219_priv *da7219 = snd_soc_component_get_drvdata(component); in da7219_aad_exit()