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

Commit 12c5fbeb authored by Android Build Coastguard Worker's avatar Android Build Coastguard Worker
Browse files

Snap for 12517605 from 3d37c355 to 25Q1-release

Change-Id: I5c4f1f76603fb0df91bbfe86696d64a3b39637fb
parents 1adc92d3 3d37c355
Loading
Loading
Loading
Loading
+2 −3
Original line number Diff line number Diff line
@@ -2221,11 +2221,10 @@ status_t AudioTrack::obtainBuffer(Buffer* audioBuffer, const struct timespec *re
        {   // start of lock scope
            AutoMutex lock(mLock);

            uint32_t newSequence = mSequence;
            // did previous obtainBuffer() fail due to media server death or voluntary invalidation?
            if (status == DEAD_OBJECT) {
                // re-create track, unless someone else has already done so
                if (newSequence == oldSequence) {
                if (mSequence == oldSequence) {
                    status = restoreTrack_l("obtainBuffer");
                    if (status != NO_ERROR) {
                        buffer.mFrameCount = 0;
@@ -2235,7 +2234,7 @@ status_t AudioTrack::obtainBuffer(Buffer* audioBuffer, const struct timespec *re
                    }
                }
            }
            oldSequence = newSequence;
            oldSequence = mSequence;

            if (status == NOT_ENOUGH_DATA) {
                restartIfDisabled();
+16 −2
Original line number Diff line number Diff line
@@ -544,7 +544,14 @@ status_t StreamHalAidl::exit() {
}

void StreamHalAidl::onAsyncTransferReady() {
    if (auto state = getState(); state == StreamDescriptor::State::TRANSFERRING) {
    StreamDescriptor::State state;
    {
        // Use 'mCommandReplyLock' to ensure that 'sendCommand' has finished updating the state
        // after the reply from the 'burst' command.
        std::lock_guard l(mCommandReplyLock);
        state = getState();
    }
    if (state == StreamDescriptor::State::TRANSFERRING) {
        // Retrieve the current state together with position counters unconditionally
        // to ensure that the state on our side gets updated.
        sendCommand(makeHalCommand<HalCommand::Tag::getStatus>(),
@@ -555,7 +562,14 @@ void StreamHalAidl::onAsyncTransferReady() {
}

void StreamHalAidl::onAsyncDrainReady() {
    if (auto state = getState(); state == StreamDescriptor::State::DRAINING) {
    StreamDescriptor::State state;
    {
        // Use 'mCommandReplyLock' to ensure that 'sendCommand' has finished updating the state
        // after the reply from the 'drain' command.
        std::lock_guard l(mCommandReplyLock);
        state = getState();
    }
    if (state == StreamDescriptor::State::DRAINING) {
        // Retrieve the current state together with position counters unconditionally
        // to ensure that the state on our side gets updated.
        sendCommand(makeHalCommand<HalCommand::Tag::getStatus>(), nullptr,
+0 −2
Original line number Diff line number Diff line
@@ -96,8 +96,6 @@ cc_library_static {
                "-DARM",
                "-DARMV7",
                "-DASM_OPT",
                // don't actually generate neon instructions, see bug 26932980
                "-mfpu=vfpv3",
            ],
            local_include_dirs: [
                "src/asm/ARMV7",
+1 −1
Original line number Diff line number Diff line
@@ -4121,7 +4121,7 @@ void AudioFlinger::updateSecondaryOutputsForTrack_l(
                                                       frameCountToBeReady,
                                                       track->getSpeed(),
                                                       1.f /* volume */,
                                                       track->getPortMute() /* muted */);
                                                       false /* muted */);
        status = patchTrack->initCheck();
        if (status != NO_ERROR) {
            ALOGE("Secondary output patchTrack init failed: %d", status);