• Home
  • Raw
  • Download

Lines Matching refs:wm8741

179 	struct wm8741_priv *wm8741 = snd_soc_component_get_drvdata(component);  in wm8741_startup()  local
181 if (wm8741->sysclk) in wm8741_startup()
184 wm8741->sysclk_constraints); in wm8741_startup()
194 struct wm8741_priv *wm8741 = snd_soc_component_get_drvdata(component); in wm8741_hw_params() local
201 if (!wm8741->sysclk) { in wm8741_hw_params()
208 for (i = 0; i < wm8741->sysclk_constraints->count; i++) { in wm8741_hw_params()
209 if (wm8741->sysclk_constraints->list[i] == params_rate(params)) in wm8741_hw_params()
213 if (i == wm8741->sysclk_constraints->count) { in wm8741_hw_params()
215 params_rate(params), wm8741->sysclk); in wm8741_hw_params()
262 struct wm8741_priv *wm8741 = snd_soc_component_get_drvdata(component); in wm8741_set_dai_sysclk() local
268 wm8741->sysclk_constraints = NULL; in wm8741_set_dai_sysclk()
271 wm8741->sysclk_constraints = &constraints_11289; in wm8741_set_dai_sysclk()
274 wm8741->sysclk_constraints = &constraints_12288; in wm8741_set_dai_sysclk()
277 wm8741->sysclk_constraints = &constraints_16384; in wm8741_set_dai_sysclk()
280 wm8741->sysclk_constraints = &constraints_16934; in wm8741_set_dai_sysclk()
283 wm8741->sysclk_constraints = &constraints_18432; in wm8741_set_dai_sysclk()
287 wm8741->sysclk_constraints = &constraints_22579; in wm8741_set_dai_sysclk()
290 wm8741->sysclk_constraints = &constraints_24576; in wm8741_set_dai_sysclk()
293 wm8741->sysclk_constraints = &constraints_36864; in wm8741_set_dai_sysclk()
299 wm8741->sysclk = freq; in wm8741_set_dai_sysclk()
417 struct wm8741_priv *wm8741 = snd_soc_component_get_drvdata(component); in wm8741_configure() local
420 switch (wm8741->pdata.diff_mode) { in wm8741_configure()
427 wm8741->pdata.diff_mode << WM8741_DIFF_SHIFT); in wm8741_configure()
448 struct wm8741_priv *wm8741 = snd_soc_component_get_drvdata(component); in wm8741_add_controls() local
450 switch (wm8741->pdata.diff_mode) { in wm8741_add_controls()
476 struct wm8741_priv *wm8741 = snd_soc_component_get_drvdata(component); in wm8741_probe() local
479 ret = regulator_bulk_enable(ARRAY_SIZE(wm8741->supplies), in wm8741_probe()
480 wm8741->supplies); in wm8741_probe()
508 regulator_bulk_disable(ARRAY_SIZE(wm8741->supplies), wm8741->supplies); in wm8741_probe()
515 struct wm8741_priv *wm8741 = snd_soc_component_get_drvdata(component); in wm8741_remove() local
517 regulator_bulk_disable(ARRAY_SIZE(wm8741->supplies), wm8741->supplies); in wm8741_remove()
550 static int wm8741_set_pdata(struct device *dev, struct wm8741_priv *wm8741) in wm8741_set_pdata() argument
558 wm8741->pdata.diff_mode = diff_mode; in wm8741_set_pdata()
561 memcpy(&wm8741->pdata, pdata, sizeof(wm8741->pdata)); in wm8741_set_pdata()
571 struct wm8741_priv *wm8741; in wm8741_i2c_probe() local
574 wm8741 = devm_kzalloc(&i2c->dev, sizeof(struct wm8741_priv), in wm8741_i2c_probe()
576 if (wm8741 == NULL) in wm8741_i2c_probe()
579 for (i = 0; i < ARRAY_SIZE(wm8741->supplies); i++) in wm8741_i2c_probe()
580 wm8741->supplies[i].supply = wm8741_supply_names[i]; in wm8741_i2c_probe()
582 ret = devm_regulator_bulk_get(&i2c->dev, ARRAY_SIZE(wm8741->supplies), in wm8741_i2c_probe()
583 wm8741->supplies); in wm8741_i2c_probe()
589 wm8741->regmap = devm_regmap_init_i2c(i2c, &wm8741_regmap); in wm8741_i2c_probe()
590 if (IS_ERR(wm8741->regmap)) { in wm8741_i2c_probe()
591 ret = PTR_ERR(wm8741->regmap); in wm8741_i2c_probe()
596 ret = wm8741_set_pdata(&i2c->dev, wm8741); in wm8741_i2c_probe()
602 i2c_set_clientdata(i2c, wm8741); in wm8741_i2c_probe()
629 struct wm8741_priv *wm8741; in wm8741_spi_probe() local
632 wm8741 = devm_kzalloc(&spi->dev, sizeof(struct wm8741_priv), in wm8741_spi_probe()
634 if (wm8741 == NULL) in wm8741_spi_probe()
637 for (i = 0; i < ARRAY_SIZE(wm8741->supplies); i++) in wm8741_spi_probe()
638 wm8741->supplies[i].supply = wm8741_supply_names[i]; in wm8741_spi_probe()
640 ret = devm_regulator_bulk_get(&spi->dev, ARRAY_SIZE(wm8741->supplies), in wm8741_spi_probe()
641 wm8741->supplies); in wm8741_spi_probe()
647 wm8741->regmap = devm_regmap_init_spi(spi, &wm8741_regmap); in wm8741_spi_probe()
648 if (IS_ERR(wm8741->regmap)) { in wm8741_spi_probe()
649 ret = PTR_ERR(wm8741->regmap); in wm8741_spi_probe()
654 ret = wm8741_set_pdata(&spi->dev, wm8741); in wm8741_spi_probe()
660 spi_set_drvdata(spi, wm8741); in wm8741_spi_probe()