audioserver: Ensure minimum binder priority set
Prevents binder threads from waiting as runnable and
helps priority inversion on mutexes. Those issues
can cause sporadic audio glitches.
Test: instrumeted logging
Bug: 261646227
Change-Id: Ic96f8c2f35fc1096d560b16a702392c807f0504e
diff --git a/services/audioflinger/Effects.cpp b/services/audioflinger/Effects.cpp
index 24fe6f6..9ebff0b 100644
--- a/services/audioflinger/Effects.cpp
+++ b/services/audioflinger/Effects.cpp
@@ -1730,6 +1730,7 @@
mNotifyFramesProcessed(notifyFramesProcessed)
{
ALOGV("constructor %p client %p", this, client.get());
+ setMinSchedulerPolicy(SCHED_NORMAL, ANDROID_PRIORITY_AUDIO);
if (client == 0) {
return;