Add thread safe annotation in audio flinger effects

Bug: 315995877
Test: atest AudioTrackTest AudioRecordTest audioeffect_tests
Change-Id: I90406c48660aef25ab4402a70a2a45deb6651335
diff --git a/services/audioflinger/Threads.h b/services/audioflinger/Threads.h
index a8e4339..a6888c0 100644
--- a/services/audioflinger/Threads.h
+++ b/services/audioflinger/Threads.h
@@ -437,9 +437,10 @@
                 // integrity of the chains during the process.
                 // Also sets the parameter 'effectChains' to current value of mEffectChains.
     void lockEffectChains_l(Vector<sp<IAfEffectChain>>& effectChains) final
-            REQUIRES(mutex()) EXCLUDES_EffectChain_Mutex;
+            REQUIRES(audio_utils::ThreadBase_Mutex) ACQUIRE(audio_utils::EffectChain_Mutex);
                 // unlock effect chains after process
-    void unlockEffectChains(const Vector<sp<IAfEffectChain>>& effectChains) final;
+    void unlockEffectChains(const Vector<sp<IAfEffectChain>>& effectChains) final
+            RELEASE(audio_utils::EffectChain_Mutex);
                 // get a copy of mEffectChains vector
     Vector<sp<IAfEffectChain>> getEffectChains_l() const final REQUIRES(mutex()) {
         return mEffectChains;