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

Commit ed457786 authored by TreeHugger Robot's avatar TreeHugger Robot Committed by Android (Google) Code Review
Browse files

Merge "audiopolicy: increase binder command timeout for some commmands" into pi-dev

parents 53676d02 09e621a7
Loading
Loading
Loading
Loading
+14 −1
Original line number Diff line number Diff line
@@ -883,7 +883,20 @@ status_t BnAudioPolicyService::onTransact(
            break;
    }

    TimeCheck check("IAudioPolicyService");
    // FIXME: extend timeout for SET_DEVICE_CONNECTION_STATE and HANDLE_DEVICE_CONFIG_CHANGE
    // while we investigate why BT A2DP device connection/disconnection can sometimes
    // take more than 5 seconds
    uint32_t timeoutMs = TimeCheck::kDefaultTimeOutMs;
    switch (code) {
        case SET_DEVICE_CONNECTION_STATE:
        case HANDLE_DEVICE_CONFIG_CHANGE:
            timeoutMs *= 2;
            break;
        default:
            break;
    }

    TimeCheck check("IAudioPolicyService", timeoutMs);

    switch (code) {
        case SET_DEVICE_CONNECTION_STATE: {