mirror of
https://gitlab.freedesktop.org/pipewire/pipewire.git
synced 2026-05-30 21:37:53 -04:00
context: run nodes in the same node.group
When one of the nodes from a group is running, all the other nodes in the group should run as well. The link group is only for the session manager to avoid linking the same link group to avoid loops, like linking the output of a loopback to the input. The problem is that we removed the node.link-group from driver nodes (in ACP and elsewhere) but now the source/sink pairs (when in the same group like for pro-audio) don't run together in all cases, causing sync issues. See #5210
This commit is contained in:
parent
a1c1d9f9f1
commit
1be2c0cc3d
1 changed files with 5 additions and 7 deletions
|
|
@ -1046,17 +1046,15 @@ static inline int run_nodes(struct pw_context *context, struct pw_impl_node *nod
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
/* now go through all the nodes that have the same link group and
|
/* now go through all the nodes that share groups and link_groups
|
||||||
* that are not yet visited. Note how nodes with the same group
|
* that are not yet visited */
|
||||||
* don't get included here. They were added to the same driver but
|
if (node->groups != NULL || node->link_groups != NULL) {
|
||||||
* need to otherwise stay idle unless some non-passive link activates
|
|
||||||
* them. */
|
|
||||||
if (node->link_groups != NULL) {
|
|
||||||
spa_list_for_each(t, nodes, sort_link) {
|
spa_list_for_each(t, nodes, sort_link) {
|
||||||
if (t->exported || !t->active ||
|
if (t->exported || !t->active ||
|
||||||
SPA_FLAG_IS_SET(t->checked, 1u<<direction))
|
SPA_FLAG_IS_SET(t->checked, 1u<<direction))
|
||||||
continue;
|
continue;
|
||||||
if (pw_strv_find_common(t->link_groups, node->link_groups) < 0)
|
if (pw_strv_find_common(t->groups, node->groups) < 0 &&
|
||||||
|
pw_strv_find_common(t->link_groups, node->link_groups) < 0)
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
pw_log_debug(" group %p: '%s'", t, t->name);
|
pw_log_debug(" group %p: '%s'", t, t->name);
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue