Lines Matching refs:component
719 struct snd_soc_component *component = file->private_data; in topology_name_read() local
720 struct snd_soc_card *card = component->card; in topology_name_read()
725 len = scnprintf(buf, sizeof(buf), "%s/%s\n", component->driver->topology_name_prefix, in topology_name_read()
770 static int avs_component_probe(struct snd_soc_component *component) in avs_component_probe() argument
772 struct snd_soc_card *card = component->card; in avs_component_probe()
779 dev_dbg(card->dev, "probing %s card %s\n", component->name, card->name); in avs_component_probe()
781 acomp = to_avs_soc_component(component); in avs_component_probe()
782 adev = to_avs_dev(component->dev); in avs_component_probe()
784 acomp->tplg = avs_tplg_new(component); in avs_component_probe()
792 filename = kasprintf(GFP_KERNEL, "%s/%s", component->driver->topology_name_prefix, in avs_component_probe()
797 ret = avs_load_topology(component, filename); in avs_component_probe()
812 filename = kasprintf(GFP_KERNEL, "%s/%s", component->driver->topology_name_prefix, in avs_component_probe()
818 ret = avs_load_topology(component, filename); in avs_component_probe()
831 debugfs_create_file("topology_name", 0444, component->debugfs_root, component, in avs_component_probe()
841 avs_remove_topology(component); in avs_component_probe()
845 static void avs_component_remove(struct snd_soc_component *component) in avs_component_remove() argument
847 struct avs_soc_component *acomp = to_avs_soc_component(component); in avs_component_remove()
849 struct avs_dev *adev = to_avs_dev(component->dev); in avs_component_remove()
852 mach = dev_get_platdata(component->card->dev); in avs_component_remove()
859 ret = avs_remove_topology(component); in avs_component_remove()
861 dev_err(component->dev, "unload topology failed: %d\n", ret); in avs_component_remove()
956 static int avs_component_pm_op(struct snd_soc_component *component, bool be, in avs_component_pm_op() argument
964 for_each_component_dais(component, dai) { in avs_component_pm_op()
995 static int avs_component_resume_hw_params(struct snd_soc_component *component, bool be) in avs_component_resume_hw_params() argument
997 return avs_component_pm_op(component, be, &avs_dai_resume_hw_params); in avs_component_resume_hw_params()
1000 static int avs_component_resume_prepare(struct snd_soc_component *component, bool be) in avs_component_resume_prepare() argument
1009 return avs_component_pm_op(component, be, prepare_cb); in avs_component_resume_prepare()
1012 static int avs_component_suspend_hw_free(struct snd_soc_component *component, bool be) in avs_component_suspend_hw_free() argument
1021 return avs_component_pm_op(component, be, hw_free_cb); in avs_component_suspend_hw_free()
1024 static int avs_component_suspend(struct snd_soc_component *component) in avs_component_suspend() argument
1032 ret = avs_component_suspend_hw_free(component, false); in avs_component_suspend()
1036 return avs_component_suspend_hw_free(component, true); in avs_component_suspend()
1039 static int avs_component_resume(struct snd_soc_component *component) in avs_component_resume() argument
1047 ret = avs_component_resume_hw_params(component, true); in avs_component_resume()
1051 ret = avs_component_resume_hw_params(component, false); in avs_component_resume()
1056 ret = avs_component_resume_prepare(component, true); in avs_component_resume()
1060 return avs_component_resume_prepare(component, false); in avs_component_resume()
1081 static int avs_component_open(struct snd_soc_component *component, in avs_component_open() argument
1100 avs_component_pointer(struct snd_soc_component *component, struct snd_pcm_substream *substream) in avs_component_pointer() argument
1120 static int avs_component_mmap(struct snd_soc_component *component, in avs_component_mmap() argument
1129 static int avs_component_construct(struct snd_soc_component *component, in avs_component_construct() argument
1137 SNDRV_DMA_TYPE_DEV_SG, component->dev, 0, in avs_component_construct()
1142 SNDRV_DMA_TYPE_DEV_SG, component->dev, 0, in avs_component_construct()
1315 static void avs_component_hda_unregister_dais(struct snd_soc_component *component) in avs_component_hda_unregister_dais() argument
1322 mach = dev_get_platdata(component->card->dev); in avs_component_hda_unregister_dais()
1326 for_each_component_dais_safe(component, dai, save) { in avs_component_hda_unregister_dais()
1339 static int avs_component_hda_probe(struct snd_soc_component *component) in avs_component_hda_probe() argument
1349 mach = dev_get_platdata(component->card->dev); in avs_component_hda_probe()
1359 dais = devm_kcalloc(component->dev, pcm_count, sizeof(*dais), in avs_component_hda_probe()
1365 dapm = snd_soc_component_get_dapm(component); in avs_component_hda_probe()
1373 dais[i].name = devm_kasprintf(component->dev, GFP_KERNEL, in avs_component_hda_probe()
1382 devm_kasprintf(component->dev, GFP_KERNEL, in avs_component_hda_probe()
1392 devm_kasprintf(component->dev, GFP_KERNEL, in avs_component_hda_probe()
1400 dai = snd_soc_register_dai(component, &dais[i], false); in avs_component_hda_probe()
1402 dev_err(component->dev, "register dai for %s failed\n", in avs_component_hda_probe()
1410 dev_err(component->dev, "create widgets failed: %d\n", in avs_component_hda_probe()
1416 ret = avs_component_probe(component); in avs_component_hda_probe()
1419 avs_component_hda_unregister_dais(component); in avs_component_hda_probe()
1424 static void avs_component_hda_remove(struct snd_soc_component *component) in avs_component_hda_remove() argument
1426 avs_component_hda_unregister_dais(component); in avs_component_hda_remove()
1427 avs_component_remove(component); in avs_component_hda_remove()
1430 static int avs_component_hda_open(struct snd_soc_component *component, in avs_component_hda_open() argument
1477 static int avs_component_hda_close(struct snd_soc_component *component, in avs_component_hda_close() argument