Lines Matching refs:wm8770

102 	struct wm8770_priv *wm8770 = container_of(nb, struct wm8770_priv, \
105 regcache_mark_dirty(wm8770->regmap); \
412 struct wm8770_priv *wm8770; in wm8770_hw_params() local
419 wm8770 = snd_soc_component_get_drvdata(component); in wm8770_hw_params()
452 ratio = wm8770->sysclk / params_rate(params); in wm8770_hw_params()
460 wm8770->sysclk, params_rate(params)); in wm8770_hw_params()
488 struct wm8770_priv *wm8770; in wm8770_set_sysclk() local
491 wm8770 = snd_soc_component_get_drvdata(component); in wm8770_set_sysclk()
492 wm8770->sysclk = freq; in wm8770_set_sysclk()
500 struct wm8770_priv *wm8770; in wm8770_set_bias_level() local
502 wm8770 = snd_soc_component_get_drvdata(component); in wm8770_set_bias_level()
511 ret = regulator_bulk_enable(ARRAY_SIZE(wm8770->supplies), in wm8770_set_bias_level()
512 wm8770->supplies); in wm8770_set_bias_level()
520 regcache_sync(wm8770->regmap); in wm8770_set_bias_level()
529 regulator_bulk_disable(ARRAY_SIZE(wm8770->supplies), in wm8770_set_bias_level()
530 wm8770->supplies); in wm8770_set_bias_level()
570 struct wm8770_priv *wm8770; in wm8770_probe() local
573 wm8770 = snd_soc_component_get_drvdata(component); in wm8770_probe()
574 wm8770->component = component; in wm8770_probe()
576 ret = regulator_bulk_enable(ARRAY_SIZE(wm8770->supplies), in wm8770_probe()
577 wm8770->supplies); in wm8770_probe()
605 regulator_bulk_disable(ARRAY_SIZE(wm8770->supplies), wm8770->supplies); in wm8770_probe()
642 struct wm8770_priv *wm8770; in wm8770_spi_probe() local
645 wm8770 = devm_kzalloc(&spi->dev, sizeof(struct wm8770_priv), in wm8770_spi_probe()
647 if (!wm8770) in wm8770_spi_probe()
650 for (i = 0; i < ARRAY_SIZE(wm8770->supplies); i++) in wm8770_spi_probe()
651 wm8770->supplies[i].supply = wm8770_supply_names[i]; in wm8770_spi_probe()
653 ret = devm_regulator_bulk_get(&spi->dev, ARRAY_SIZE(wm8770->supplies), in wm8770_spi_probe()
654 wm8770->supplies); in wm8770_spi_probe()
660 wm8770->disable_nb[0].notifier_call = wm8770_regulator_event_0; in wm8770_spi_probe()
661 wm8770->disable_nb[1].notifier_call = wm8770_regulator_event_1; in wm8770_spi_probe()
662 wm8770->disable_nb[2].notifier_call = wm8770_regulator_event_2; in wm8770_spi_probe()
665 for (i = 0; i < ARRAY_SIZE(wm8770->supplies); i++) { in wm8770_spi_probe()
667 wm8770->supplies[i].consumer, in wm8770_spi_probe()
668 &wm8770->disable_nb[i]); in wm8770_spi_probe()
676 wm8770->regmap = devm_regmap_init_spi(spi, &wm8770_regmap); in wm8770_spi_probe()
677 if (IS_ERR(wm8770->regmap)) in wm8770_spi_probe()
678 return PTR_ERR(wm8770->regmap); in wm8770_spi_probe()
680 spi_set_drvdata(spi, wm8770); in wm8770_spi_probe()