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

Commit 8b187f4a authored by Elliott Hughes's avatar Elliott Hughes Committed by Gerrit Code Review
Browse files

Merge "Move frameworks/av off <sys/atomics.h>."

parents d5516339 63492411
Loading
Loading
Loading
Loading
+2 −3
Original line number Diff line number Diff line
@@ -27,7 +27,6 @@
#include <media/stagefright/MetaData.h>

#include <ui/GraphicBuffer.h>
#include <sys/atomics.h>

namespace android {

@@ -92,7 +91,7 @@ void MediaBuffer::release() {
        return;
    }

    int prevCount = __atomic_dec(&mRefCount);
    int prevCount = __sync_fetch_and_sub(&mRefCount, 1);
    if (prevCount == 1) {
        if (mObserver == NULL) {
            delete this;
@@ -112,7 +111,7 @@ void MediaBuffer::claim() {
}

void MediaBuffer::add_ref() {
    (void) __atomic_inc(&mRefCount);
    (void) __sync_fetch_and_add(&mRefCount, 1);
}

void *MediaBuffer::data() const {
+0 −1
Original line number Diff line number Diff line
@@ -26,7 +26,6 @@
#define ATRACE_TAG ATRACE_TAG_AUDIO

#include "Configuration.h"
#include <sys/atomics.h>
#include <time.h>
#include <utils/Log.h>
#include <utils/Trace.h>