Lines Matching refs:component
40 struct snd_soc_component *component; member
190 static void rt286_index_sync(struct snd_soc_component *component) in rt286_index_sync() argument
192 struct rt286_priv *rt286 = snd_soc_component_get_drvdata(component); in rt286_index_sync()
196 snd_soc_component_write(component, rt286->index_cache[i].reg, in rt286_index_sync()
223 if (!rt286->component) in rt286_jack_detect()
226 dapm = snd_soc_component_get_dapm(rt286->component); in rt286_jack_detect()
314 static int rt286_mic_detect(struct snd_soc_component *component, in rt286_mic_detect() argument
317 struct snd_soc_dapm_context *dapm = snd_soc_component_get_dapm(component); in rt286_mic_detect()
318 struct rt286_priv *rt286 = snd_soc_component_get_drvdata(component); in rt286_mic_detect()
343 struct snd_soc_component *component = snd_soc_dapm_to_component(source->dapm); in is_mclk_mode() local
344 struct rt286_priv *rt286 = snd_soc_component_get_drvdata(component); in is_mclk_mode()
443 struct snd_soc_component *component = snd_soc_dapm_to_component(w->dapm); in rt286_spk_event() local
447 snd_soc_component_write(component, in rt286_spk_event()
451 snd_soc_component_write(component, in rt286_spk_event()
465 struct snd_soc_component *component = snd_soc_dapm_to_component(w->dapm); in rt286_set_dmic1_event() local
469 snd_soc_component_write(component, RT286_SET_PIN_DMIC1, 0x20); in rt286_set_dmic1_event()
472 snd_soc_component_write(component, RT286_SET_PIN_DMIC1, 0); in rt286_set_dmic1_event()
484 struct snd_soc_component *component = snd_soc_dapm_to_component(w->dapm); in rt286_ldo2_event() local
488 snd_soc_component_update_bits(component, RT286_POWER_CTRL2, 0x38, 0x08); in rt286_ldo2_event()
491 snd_soc_component_update_bits(component, RT286_POWER_CTRL2, 0x38, 0x30); in rt286_ldo2_event()
503 struct snd_soc_component *component = snd_soc_dapm_to_component(w->dapm); in rt286_mic1_event() local
507 snd_soc_component_update_bits(component, in rt286_mic1_event()
509 snd_soc_component_update_bits(component, in rt286_mic1_event()
513 snd_soc_component_update_bits(component, in rt286_mic1_event()
515 snd_soc_component_update_bits(component, in rt286_mic1_event()
683 struct snd_soc_component *component = dai->component; in rt286_hw_params() local
684 struct rt286_priv *rt286 = snd_soc_component_get_drvdata(component); in rt286_hw_params()
696 dev_err(component->dev, "Unsupported sample rate %d\n", in rt286_hw_params()
704 dev_err(component->dev, "Sys_clk is not matched (%d %d)\n", in rt286_hw_params()
712 dev_err(component->dev, "Sys_clk is not matched (%d %d)\n", in rt286_hw_params()
723 dev_err(component->dev, "Unsupported channels %d\n", in rt286_hw_params()
753 snd_soc_component_update_bits(component, in rt286_hw_params()
755 dev_dbg(component->dev, "format val = 0x%x\n", val); in rt286_hw_params()
757 snd_soc_component_update_bits(component, RT286_DAC_FORMAT, 0x407f, val); in rt286_hw_params()
758 snd_soc_component_update_bits(component, RT286_ADC_FORMAT, 0x407f, val); in rt286_hw_params()
765 struct snd_soc_component *component = dai->component; in rt286_set_dai_fmt() local
769 snd_soc_component_update_bits(component, in rt286_set_dai_fmt()
773 snd_soc_component_update_bits(component, in rt286_set_dai_fmt()
782 snd_soc_component_update_bits(component, in rt286_set_dai_fmt()
786 snd_soc_component_update_bits(component, in rt286_set_dai_fmt()
790 snd_soc_component_update_bits(component, in rt286_set_dai_fmt()
794 snd_soc_component_update_bits(component, in rt286_set_dai_fmt()
801 snd_soc_component_update_bits(component, RT286_DAC_FORMAT, 0x8000, 0); in rt286_set_dai_fmt()
802 snd_soc_component_update_bits(component, RT286_ADC_FORMAT, 0x8000, 0); in rt286_set_dai_fmt()
810 struct snd_soc_component *component = dai->component; in rt286_set_dai_sysclk() local
811 struct rt286_priv *rt286 = snd_soc_component_get_drvdata(component); in rt286_set_dai_sysclk()
813 dev_dbg(component->dev, "%s freq=%d\n", __func__, freq); in rt286_set_dai_sysclk()
816 snd_soc_component_update_bits(component, in rt286_set_dai_sysclk()
818 snd_soc_component_update_bits(component, in rt286_set_dai_sysclk()
821 snd_soc_component_update_bits(component, in rt286_set_dai_sysclk()
823 snd_soc_component_update_bits(component, in rt286_set_dai_sysclk()
825 snd_soc_component_update_bits(component, in rt286_set_dai_sysclk()
832 dev_err(component->dev, "Should not use MCLK\n"); in rt286_set_dai_sysclk()
835 snd_soc_component_update_bits(component, in rt286_set_dai_sysclk()
840 dev_err(component->dev, "Should not use MCLK\n"); in rt286_set_dai_sysclk()
843 snd_soc_component_update_bits(component, in rt286_set_dai_sysclk()
848 snd_soc_component_update_bits(component, in rt286_set_dai_sysclk()
850 snd_soc_component_update_bits(component, in rt286_set_dai_sysclk()
855 snd_soc_component_update_bits(component, in rt286_set_dai_sysclk()
857 snd_soc_component_update_bits(component, in rt286_set_dai_sysclk()
861 dev_err(component->dev, "Unsupported system clock\n"); in rt286_set_dai_sysclk()
873 struct snd_soc_component *component = dai->component; in rt286_set_bclk_ratio() local
875 dev_dbg(component->dev, "%s ratio=%d\n", __func__, ratio); in rt286_set_bclk_ratio()
877 snd_soc_component_update_bits(component, in rt286_set_bclk_ratio()
880 snd_soc_component_update_bits(component, in rt286_set_bclk_ratio()
887 static int rt286_set_bias_level(struct snd_soc_component *component, in rt286_set_bias_level() argument
892 if (SND_SOC_BIAS_STANDBY == snd_soc_component_get_bias_level(component)) { in rt286_set_bias_level()
893 snd_soc_component_write(component, in rt286_set_bias_level()
895 snd_soc_component_update_bits(component, in rt286_set_bias_level()
902 snd_soc_component_update_bits(component, in rt286_set_bias_level()
908 snd_soc_component_write(component, in rt286_set_bias_level()
945 static int rt286_probe(struct snd_soc_component *component) in rt286_probe() argument
947 struct rt286_priv *rt286 = snd_soc_component_get_drvdata(component); in rt286_probe()
949 rt286->component = component; in rt286_probe()
958 static void rt286_remove(struct snd_soc_component *component) in rt286_remove() argument
960 struct rt286_priv *rt286 = snd_soc_component_get_drvdata(component); in rt286_remove()
963 rt286->component = NULL; in rt286_remove()
967 static int rt286_suspend(struct snd_soc_component *component) in rt286_suspend() argument
969 struct rt286_priv *rt286 = snd_soc_component_get_drvdata(component); in rt286_suspend()
977 static int rt286_resume(struct snd_soc_component *component) in rt286_resume() argument
979 struct rt286_priv *rt286 = snd_soc_component_get_drvdata(component); in rt286_resume()
982 rt286_index_sync(component); in rt286_resume()