mirror of
https://gitlab.freedesktop.org/pipewire/pipewire.git
synced 2025-10-31 22:25:38 -04:00
loop: spa_loop_invoke -> spa_loop_locked where possible
When we simply need to change some state for the code executed in the loop, we can use locked() instead of invoke(). This is more efficient and avoids some context switches in the normal case.
This commit is contained in:
parent
b943c31fd8
commit
c45d667934
29 changed files with 75 additions and 75 deletions
|
|
@ -2220,7 +2220,7 @@ impl_node_port_set_io(void *object,
|
|||
case SPA_IO_Buffers:
|
||||
if (this->data_loop) {
|
||||
struct io_data d = { .port = port, .data = data, .size = size };
|
||||
spa_loop_invoke(this->data_loop, do_set_port_io, 0, NULL, 0, true, &d);
|
||||
spa_loop_locked(this->data_loop, do_set_port_io, 0, NULL, 0, &d);
|
||||
}
|
||||
else
|
||||
port->io = data;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue