Lines Matching +full:zero +full:- +full:initialised
1 // SPDX-License-Identifier: GPL-2.0
3 // soc-card.c
16 case -EPROBE_DEFER: in _soc_card_ret()
17 case -ENOTSUPP: in _soc_card_ret()
21 dev_err(card->dev, in _soc_card_ret()
23 func, card->name, ret); in _soc_card_ret()
32 struct snd_card *card = soc_card->snd_card; in snd_soc_card_get_kcontrol()
38 list_for_each_entry(kctl, &card->controls, list) in snd_soc_card_get_kcontrol()
39 if (!strncmp(kctl->id.name, name, sizeof(kctl->id.name))) in snd_soc_card_get_kcontrol()
46 * snd_soc_card_jack_new - Create a new jack
57 * Returns zero if successful, or a negative error code on failure.
58 * On success jack will be initialised.
66 mutex_init(&jack->mutex); in snd_soc_card_jack_new()
67 jack->card = card; in snd_soc_card_jack_new()
68 INIT_LIST_HEAD(&jack->pins); in snd_soc_card_jack_new()
69 INIT_LIST_HEAD(&jack->jack_zones); in snd_soc_card_jack_new()
70 BLOCKING_INIT_NOTIFIER_HEAD(&jack->notifier); in snd_soc_card_jack_new()
72 ret = snd_jack_new(card->snd_card, id, type, &jack->jack, false, false); in snd_soc_card_jack_new()
87 if (card->suspend_pre) in snd_soc_card_suspend_pre()
88 ret = card->suspend_pre(card); in snd_soc_card_suspend_pre()
97 if (card->suspend_post) in snd_soc_card_suspend_post()
98 ret = card->suspend_post(card); in snd_soc_card_suspend_post()
107 if (card->resume_pre) in snd_soc_card_resume_pre()
108 ret = card->resume_pre(card); in snd_soc_card_resume_pre()
117 if (card->resume_post) in snd_soc_card_resume_post()
118 ret = card->resume_post(card); in snd_soc_card_resume_post()
125 if (card->probe) { in snd_soc_card_probe()
126 int ret = card->probe(card); in snd_soc_card_probe()
132 * It has "card->probe" and "card->late_probe" callbacks. in snd_soc_card_probe()
140 card->probed = 1; in snd_soc_card_probe()
148 if (card->late_probe) { in snd_soc_card_late_probe()
149 int ret = card->late_probe(card); in snd_soc_card_late_probe()
156 * It has "card->probe" and "card->late_probe" callbacks, in snd_soc_card_late_probe()
158 * This means, we can set "card->probed" flag afer "late_probe" in snd_soc_card_late_probe()
165 card->probed = 1; in snd_soc_card_late_probe()
174 if (card->probed && in snd_soc_card_remove()
175 card->remove) in snd_soc_card_remove()
176 ret = card->remove(card); in snd_soc_card_remove()
178 card->probed = 0; in snd_soc_card_remove()
189 if (card && card->set_bias_level) in snd_soc_card_set_bias_level()
190 ret = card->set_bias_level(card, dapm, level); in snd_soc_card_set_bias_level()
201 if (card && card->set_bias_level_post) in snd_soc_card_set_bias_level_post()
202 ret = card->set_bias_level_post(card, dapm, level); in snd_soc_card_set_bias_level_post()
212 if (card->add_dai_link) in snd_soc_card_add_dai_link()
213 ret = card->add_dai_link(card, dai_link); in snd_soc_card_add_dai_link()
222 if (card->remove_dai_link) in snd_soc_card_remove_dai_link()
223 card->remove_dai_link(card, dai_link); in snd_soc_card_remove_dai_link()