Lines Matching defs:path

203  * the size of the generic function and at the same time the fast path of the
244 * have changed. E.g. if the source state of a widget changes or a path is added
261 * have changed. E.g. if the sink state of a widget changes or a path is added
271 * for the widgets connected to a path
272 * @p: The path to invalidate
274 * Resets the cached number of inputs for the sink of the path and the cached
275 * number of outputs for the source of the path.
277 * This function must be called when a path is added, removed or the connected
293 * so there is no need to re-check the path.
509 struct snd_soc_dapm_path *path)
513 list_add_tail(&path->list_kcontrol, &data->paths);
534 #define dapm_kcontrol_for_each_path(path, kcontrol) \
535 list_for_each_entry(path, dapm_kcontrol_get_path_list(kcontrol), \
751 struct snd_soc_dapm_path *path, const char *control_name,
765 * decide which path to connect, it will try to match
777 path->name = e->texts[i];
778 path->connect = (i == item);
800 * which path of a kcontrol it is setting the initial
807 * first path is the left channel, and all remaining
822 * decide which path to connect, it will try to match
833 struct snd_soc_dapm_path *path, const char *control_name)
838 for (i = 0; i < path->sink->num_kcontrols; i++) {
839 if (!strcmp(control_name, path->sink->kcontrol_news[i].name)) {
840 path->name = path->sink->kcontrol_news[i].name;
841 dapm_set_mixer_path_status(path, i, nth_path++);
988 struct snd_soc_dapm_path *path;
994 snd_soc_dapm_widget_for_each_source_path(w, path) {
996 if (path->name != (char *)w->kcontrol_news[i].name)
1005 dapm_kcontrol_add_path(w->kcontrols[i], path);
1011 path->source,
1024 struct snd_soc_dapm_path *path;
1057 snd_soc_dapm_widget_for_each_path(w, dir, path) {
1058 if (path->name)
1059 dapm_kcontrol_add_path(w->kcontrols[0], path);
1167 struct snd_soc_dapm_path *path;
1171 snd_soc_dapm_widget_for_each_path(widget, rdir, path) {
1172 if (path->weak || path->is_supply)
1175 if (path->walking)
1178 if (path->connect) {
1179 path->walking = 1;
1180 invalidate_paths_ep(path->node[dir], dir);
1181 path->walking = 0;
1190 * generic function and at the same time the fast path of the specialized
1202 struct snd_soc_dapm_path *path;
1224 snd_soc_dapm_widget_for_each_path(widget, rdir, path) {
1227 if (path->weak || path->is_supply)
1230 if (path->walking)
1233 trace_snd_soc_dapm_path(widget, dir, path);
1235 if (path->connect) {
1236 path->walking = 1;
1237 con += fn(path->node[dir], list, custom_stop_condition);
1238 path->walking = 0;
1248 * Recursively check for a completed path to an active or physically connected
1266 * Recursively check for a completed path to an active or physically connected
1284 * snd_soc_dapm_dai_get_connected_widgets - query audio path and it's widgets.
1291 * Queries DAPM graph as to whether a valid audio stream path exists for
1456 struct snd_soc_dapm_path *path;
1461 snd_soc_dapm_widget_for_each_sink_path(w, path) {
1464 if (path->weak)
1467 if (path->connected &&
1468 !path->connected(path->source, path->sink))
1471 if (dapm_widget_power_check(path->sink))
1884 struct snd_soc_dapm_path *path;
1894 snd_soc_dapm_widget_for_each_source_path(w, path)
1895 dapm_widget_set_peer_power(path->source, power, path->connect);
1899 snd_soc_dapm_widget_for_each_sink_path(w, path)
1900 dapm_widget_set_peer_power(path->sink, power,
1901 path->connect);
1949 * Scan each dapm widget for complete audio path.
1950 * A complete path is a route that has valid endpoints i.e.:-
2255 * soc_dapm_connect_path() - Connects or disconnects a path
2256 * @path: The path to update
2257 * @connect: The new connect state of the path. True if the path is connected,
2259 * @reason: The reason why the path changed (for debugging only)
2261 static void soc_dapm_connect_path(struct snd_soc_dapm_path *path,
2264 if (path->connect == connect)
2267 path->connect = connect;
2268 dapm_mark_dirty(path->source, reason);
2269 dapm_mark_dirty(path->sink, reason);
2270 dapm_path_invalidate(path);
2277 struct snd_soc_dapm_path *path;
2283 /* find dapm widget path assoc with kcontrol */
2284 dapm_kcontrol_for_each_path(path, kcontrol) {
2286 /* we now need to match the string in the enum to the path */
2287 if (e && !(strcmp(path->name, e->texts[mux])))
2292 soc_dapm_connect_path(path, connect, "mux update");
2324 struct snd_soc_dapm_path *path;
2329 /* find dapm widget path assoc with kcontrol */
2330 dapm_kcontrol_for_each_path(path, kcontrol) {
2338 * first path (when 'found == 0') is the left channel,
2349 * It passes 'connect' as the path connect status for
2354 soc_dapm_connect_path(path, rconnect, "mixer update");
2356 soc_dapm_connect_path(path, connect, "mixer update");
2477 static void dapm_free_path(struct snd_soc_dapm_path *path)
2479 list_del(&path->list_node[SND_SOC_DAPM_DIR_IN]);
2480 list_del(&path->list_node[SND_SOC_DAPM_DIR_OUT]);
2481 list_del(&path->list_kcontrol);
2482 list_del(&path->list);
2483 kfree(path);
2495 * While removing the path, remove reference to it from both
2496 * source and sink widgets so that path is removed only once.
2610 * stream or path usage.
2634 * stream or path usage.
2728 * This function must be called whenever a path is added or removed to a widget.
2812 "Direct connection between demux and mixer/mux not supported for path %s -> [%s] -> %s\n",
2817 "Control not supported for path %s -> [%s] -> %s\n",
2833 struct snd_soc_dapm_path *path;
2861 path = kzalloc(sizeof(struct snd_soc_dapm_path), GFP_KERNEL);
2862 if (!path)
2865 path->node[SND_SOC_DAPM_DIR_IN] = wsource;
2866 path->node[SND_SOC_DAPM_DIR_OUT] = wsink;
2870 path->connected = connected;
2871 INIT_LIST_HEAD(&path->list);
2872 INIT_LIST_HEAD(&path->list_kcontrol);
2875 path->is_supply = 1;
2879 path->connect = 1;
2883 ret = dapm_connect_mux(dapm, path, control, wsource);
2893 ret = dapm_connect_mux(dapm, path, control, wsink);
2900 ret = dapm_connect_mixer(dapm, path, control);
2909 list_add(&path->list, &dapm->card->paths);
2911 list_add(&path->list_node[dir], &widgets[dir]->edges[dir]);
2918 if (dapm->card->instantiated && path->connect)
2919 dapm_path_invalidate(path);
2923 kfree(path);
3030 struct snd_soc_dapm_path *path, *p;
3056 path = NULL;
3062 path = p;
3066 if (path) {
3067 wsource = path->source;
3068 wsink = path->sink;
3072 if (path->connect)
3073 dapm_path_invalidate(path);
3075 dapm_free_path(path);
3077 /* Update any path related flags */
3094 * Connects 2 dapm widgets together via a named audio path. The sink is
3157 struct snd_soc_dapm_path *path;
3176 snd_soc_dapm_widget_for_each_sink_path(source, path) {
3177 if (path->sink == sink) {
3178 path->weak = 1;
3184 dev_err(dapm->dev, "ASoC: No path found for weak route %s->%s\n",
3829 struct snd_soc_dapm_path *path;
3851 snd_soc_dapm_widget_for_each_source_path(w, path) {
3852 source = path->source->priv;
3864 snd_soc_dapm_widget_for_each_sink_path(w, path) {
3865 sink = path->sink->priv;
3912 snd_soc_dapm_widget_for_each_source_path(w, path) {
3913 source = path->source->priv;
3923 snd_soc_dapm_widget_for_each_sink_path(w, path) {
3924 sink = path->sink->priv;
3946 struct snd_soc_dapm_path *path;
3964 snd_soc_dapm_widget_for_each_sink_path(w, path) {
3965 sink = path->sink->priv;
3977 snd_soc_dapm_widget_for_each_sink_path(w, path) {
3978 sink = path->sink->priv;
3989 snd_soc_dapm_widget_for_each_source_path(w, path) {
3990 source = path->source->priv;
3995 snd_soc_dapm_widget_for_each_sink_path(w, path) {
3996 sink = path->sink->priv;
4001 snd_soc_dapm_widget_for_each_source_path(w, path) {
4002 source = path->source->priv;
4008 snd_soc_dapm_widget_for_each_sink_path(w, path) {
4009 sink = path->sink->priv;
4756 * system is disabled a path between two endpoints flagged as ignoring
4757 * suspend will not be disabled. The path must already be enabled via