core: Expose API to elevate a thread to realtime priority

This should make it easier for clients to elevate their audio threads to
real time priority without having to dig through much through specific
system internals.
This commit is contained in:
Arun Raghavan 2018-04-21 09:45:26 +05:30
parent 651a3d108e
commit 878ef44079
17 changed files with 205 additions and 184 deletions

View file

@ -29,6 +29,7 @@
#include <pulse/rtclock.h>
#include <pulse/timeval.h>
#include <pulse/util.h>
#include <pulse/volume.h>
#include <pulse/xmalloc.h>
@ -1504,7 +1505,7 @@ static void thread_func(void *userdata) {
pa_log_debug("Thread starting up");
if (u->core->realtime_scheduling)
pa_make_realtime(u->core->realtime_priority);
pa_thread_make_realtime(u->core->realtime_priority);
pa_thread_mq_install(&u->thread_mq);