Lines Matching full:wm5110
3 * wm5110.c -- WM5110 ALSA SoC Audio driver
31 #include "wm5110.h"
35 #define DRV_NAME "wm5110-codec"
512 struct wm5110_priv *wm5110 = snd_soc_component_get_drvdata(component); in wm5110_in_analog_ev() local
526 wm5110->in_value |= 0x3 << ((w->shift ^ 0x1) * 2); in wm5110_in_analog_ev()
527 wm5110->in_pre_pending++; in wm5110_in_analog_ev()
528 wm5110->in_post_pending++; in wm5110_in_analog_ev()
531 wm5110->in_pga_cache[w->shift] = snd_soc_component_read(component, reg); in wm5110_in_analog_ev()
536 wm5110->in_pre_pending--; in wm5110_in_analog_ev()
537 if (wm5110->in_pre_pending == 0) { in wm5110_in_analog_ev()
538 analog_seq[1].def = wm5110->in_value; in wm5110_in_analog_ev()
545 wm5110->in_value = 0; in wm5110_in_analog_ev()
551 wm5110->in_pga_cache[w->shift]); in wm5110_in_analog_ev()
553 wm5110->in_post_pending--; in wm5110_in_analog_ev()
554 if (wm5110->in_post_pending == 0) in wm5110_in_analog_ev()
2053 struct wm5110_priv *wm5110 = snd_soc_component_get_drvdata(component); in wm5110_set_fll() local
2057 return arizona_set_fll(&wm5110->fll[0], source, Fref, Fout); in wm5110_set_fll()
2059 return arizona_set_fll(&wm5110->fll[1], source, Fref, Fout); in wm5110_set_fll()
2061 return arizona_set_fll_refclk(&wm5110->fll[0], source, Fref, in wm5110_set_fll()
2064 return arizona_set_fll_refclk(&wm5110->fll[1], source, Fref, in wm5110_set_fll()
2082 .name = "wm5110-aif1",
2104 .name = "wm5110-aif2",
2126 .name = "wm5110-aif3",
2148 .name = "wm5110-slim1",
2167 .name = "wm5110-slim2",
2186 .name = "wm5110-slim3",
2205 .name = "wm5110-cpu-voicectrl",
2216 .name = "wm5110-dsp-voicectrl",
2226 .name = "wm5110-cpu-trace",
2237 .name = "wm5110-dsp-trace",
2256 if (strcmp(snd_soc_rtd_to_codec(rtd, 0)->name, "wm5110-dsp-voicectrl") == 0) { in wm5110_open()
2258 } else if (strcmp(snd_soc_rtd_to_codec(rtd, 0)->name, "wm5110-dsp-trace") == 0) { in wm5110_open()
2397 struct wm5110_priv *wm5110; in wm5110_probe() local
2400 wm5110 = devm_kzalloc(&pdev->dev, sizeof(struct wm5110_priv), in wm5110_probe()
2402 if (wm5110 == NULL) in wm5110_probe()
2404 platform_set_drvdata(pdev, wm5110); in wm5110_probe()
2414 wm5110->core.arizona = arizona; in wm5110_probe()
2415 wm5110->core.num_inputs = 8; in wm5110_probe()
2418 wm5110->core.adsp[i].part = "wm5110"; in wm5110_probe()
2419 wm5110->core.adsp[i].cs_dsp.num = i + 1; in wm5110_probe()
2420 wm5110->core.adsp[i].cs_dsp.type = WMFW_ADSP2; in wm5110_probe()
2421 wm5110->core.adsp[i].cs_dsp.dev = arizona->dev; in wm5110_probe()
2422 wm5110->core.adsp[i].cs_dsp.regmap = arizona->regmap; in wm5110_probe()
2424 wm5110->core.adsp[i].cs_dsp.base = ARIZONA_DSP1_CONTROL_1 in wm5110_probe()
2426 wm5110->core.adsp[i].cs_dsp.mem = wm5110_dsp_regions[i]; in wm5110_probe()
2427 wm5110->core.adsp[i].cs_dsp.num_mems in wm5110_probe()
2430 ret = wm_adsp2_init(&wm5110->core.adsp[i]); in wm5110_probe()
2436 ret = arizona_jack_codec_dev_probe(&wm5110->core, &pdev->dev); in wm5110_probe()
2440 for (i = 0; i < ARRAY_SIZE(wm5110->fll); i++) in wm5110_probe()
2441 wm5110->fll[i].vco_mult = 3; in wm5110_probe()
2445 &wm5110->fll[0]); in wm5110_probe()
2448 &wm5110->fll[1]); in wm5110_probe()
2457 arizona_init_dai(&wm5110->core, i); in wm5110_probe()
2469 wm5110); in wm5110_probe()
2505 arizona_free_irq(arizona, ARIZONA_IRQ_DSP_IRQ1, wm5110); in wm5110_probe()
2508 arizona_jack_codec_dev_remove(&wm5110->core); in wm5110_probe()
2515 struct wm5110_priv *wm5110 = platform_get_drvdata(pdev); in wm5110_remove() local
2516 struct arizona *arizona = wm5110->core.arizona; in wm5110_remove()
2522 wm_adsp2_remove(&wm5110->core.adsp[i]); in wm5110_remove()
2527 arizona_free_irq(arizona, ARIZONA_IRQ_DSP_IRQ1, wm5110); in wm5110_remove()
2529 arizona_jack_codec_dev_remove(&wm5110->core); in wm5110_remove()
2534 .name = "wm5110-codec",
2542 MODULE_DESCRIPTION("ASoC WM5110 driver");
2545 MODULE_ALIAS("platform:wm5110-codec");