Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit a770de38 authored by Carter Hsu's avatar Carter Hsu Committed by Automerger Merge Worker
Browse files

AudioFlinger: revert adjust standby delay on VOIP RX output am: 0ca47c2b

parents f427c29a 0ca47c2b
Loading
Loading
Loading
Loading
+1 −6
Original line number Diff line number Diff line
@@ -3571,12 +3571,7 @@ void AudioFlinger::PlaybackThread::cacheParameters_l()
    mIdleSleepTimeUs = idleSleepTimeUs();

    mStandbyDelayNs = AudioFlinger::mStandbyTimeInNsecs;
    // Shorten standby delay on VOIP RX output to avoid delayed routing updates
    // after a call due to call end tone.
    if (mOutput != nullptr && (mOutput->flags & AUDIO_OUTPUT_FLAG_VOIP_RX) != 0) {
        const nsecs_t NS_PER_MS = 1000000;
        mStandbyDelayNs = std::min(mStandbyDelayNs, latency_l() * NS_PER_MS);
    }

    // make sure standby delay is not too short when connected to an A2DP sink to avoid
    // truncating audio when going to standby.
    if (!Intersection(outDeviceTypes(),  getAudioDeviceOutAllA2dpSet()).empty()) {