mirror of
https://gitlab.freedesktop.org/pipewire/pipewire.git
synced 2025-11-05 13:30:02 -05:00
thread: emit a warning when calling unimplemented functions
These are fallback functions that are not implemented. It is expected that the thread-utils is used from the context, which is a complete implementation provided by module-rt.
This commit is contained in:
parent
b178d222d5
commit
25f40e4c2a
1 changed files with 14 additions and 1 deletions
|
|
@ -116,6 +116,17 @@ static int impl_get_rt_range(void *object, const struct spa_dict *props,
|
||||||
*max = sched_get_priority_max(SCHED_OTHER);
|
*max = sched_get_priority_max(SCHED_OTHER);
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
static int impl_acquire_rt(void *object, struct spa_thread *thread, int priority)
|
||||||
|
{
|
||||||
|
pw_log_warn("acquire_rt thread:%p prio:%d not implemented", thread, priority);
|
||||||
|
return -ENOTSUP;
|
||||||
|
}
|
||||||
|
|
||||||
|
static int impl_drop_rt(void *object, struct spa_thread *thread)
|
||||||
|
{
|
||||||
|
pw_log_warn("drop_rt thread:%p not implemented", thread);
|
||||||
|
return -ENOTSUP;
|
||||||
|
}
|
||||||
|
|
||||||
static struct {
|
static struct {
|
||||||
struct spa_thread_utils utils;
|
struct spa_thread_utils utils;
|
||||||
|
|
@ -128,7 +139,9 @@ static struct {
|
||||||
{ SPA_VERSION_THREAD_UTILS_METHODS,
|
{ SPA_VERSION_THREAD_UTILS_METHODS,
|
||||||
.create = impl_create,
|
.create = impl_create,
|
||||||
.join = impl_join,
|
.join = impl_join,
|
||||||
.get_rt_range = impl_get_rt_range
|
.get_rt_range = impl_get_rt_range,
|
||||||
|
.acquire_rt = impl_acquire_rt,
|
||||||
|
.drop_rt = impl_drop_rt,
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue