audio: Allow to inherit Binder RT priority in AIDL
This option is on by default for HIDL interfaces, however
in AIDL it needs to be enabled explicitly.
Bug: 331469541
Test: m
Change-Id: I971185a46da4222160fb04b8b77f805ef0396562
diff --git a/audio/aidl/default/EffectFactory.cpp b/audio/aidl/default/EffectFactory.cpp
index ba5b141..e3894f9 100644
--- a/audio/aidl/default/EffectFactory.cpp
+++ b/audio/aidl/default/EffectFactory.cpp
@@ -145,6 +145,7 @@
*_aidl_return = effectSp;
ndk::SpAIBinder effectBinder = effectSp->asBinder();
AIBinder_setMinSchedulerPolicy(effectBinder.get(), SCHED_NORMAL, ANDROID_PRIORITY_AUDIO);
+ AIBinder_setInheritRt(effectBinder.get(), true);
mEffectMap[std::weak_ptr<IEffect>(effectSp)] =
std::make_pair(in_impl_uuid, std::move(effectBinder));
return ndk::ScopedAStatus::ok();