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

Commit e7f8df47 authored by Ricardo Cerqueira's avatar Ricardo Cerqueira Committed by Steve Kondik
Browse files

frameworks/native: Fix toroplus radio with CFLAGS

This is a commit to fix the LTE radio on toroplus,
since the binaries contain a broken reference to
an old no longer existent object. This fixes that
with a CFLAGS to be enabled in the .mk files of the
toroplus device files (like BoardConfig.mk).

Credit for the original fix goes to
Sean McClenaghan (cyberkitsune09@gmail.com)
http://review.cyanogenmod.org/#/c/47134/

PS 2-3: forgot some stuff in the commit message

Change-Id: I2c0f05d1f70b96ad801971f23f6f9cf4e0fa7167

Conflicts:
	libs/gui/Android.mk
parent e02a0d6b
Loading
Loading
Loading
Loading
+7 −3
Original line number Diff line number Diff line
@@ -73,10 +73,10 @@ public:

    /* triggers screen on and waits for it to complete */
    static void unblankDisplay(const sp<IBinder>& display);
    // TODO: Remove me.  Do not use.
    // This is a compatibility shim for one product whose drivers are depending on
    // this legacy function (when they shouldn't).

#if defined(TOROPLUS_RADIO)
    static status_t getDisplayInfo(int32_t displayId, DisplayInfo* info);
#endif

#if defined(ICS_CAMERA_BLOB) || defined(MR0_CAMERA_BLOB)
    static ssize_t getDisplayWidth(int32_t displayId);
@@ -188,6 +188,10 @@ public:
    ScreenshotClient();
    ~ScreenshotClient();

#if defined(TOROPLUS_RADIO)
    status_t update();
#endif

    // frees the previous screenshot and capture a new one
    status_t update(const sp<IBinder>& display);
    status_t update(const sp<IBinder>& display,
+3 −0
Original line number Diff line number Diff line
@@ -53,6 +53,9 @@ endif
ifeq ($(TARGET_BOARD_PLATFORM), tegra3)
	LOCAL_CFLAGS += -DDONT_USE_FENCE_SYNC
endif
ifeq ($(TARGET_TOROPLUS_RADIO), true)
	LOCAL_CFLAGS += -DTOROPLUS_RADIO
endif

include $(BUILD_SHARED_LIBRARY)

+9 −3
Original line number Diff line number Diff line
@@ -655,14 +655,13 @@ void SurfaceComposerClient::unblankDisplay(const sp<IBinder>& token) {
    ComposerService::getComposerService()->unblank(token);
}

// TODO: Remove me.  Do not use.
// This is a compatibility shim for one product whose drivers are depending on
// this legacy function (when they shouldn't).
#if defined(TOROPLUS_RADIO)
status_t SurfaceComposerClient::getDisplayInfo(
        int32_t displayId, DisplayInfo* info)
{
    return getDisplayInfo(getBuiltInDisplay(displayId), info);
}
#endif

#if defined(ICS_CAMERA_BLOB) || defined(MR0_CAMERA_BLOB)
ssize_t SurfaceComposerClient::getDisplayWidth(int32_t displayId) {
@@ -706,6 +705,13 @@ ScreenshotClient::~ScreenshotClient() {
    ScreenshotClient::release();
}

#if defined(TOROPLUS_RADIO)
status_t ScreenshotClient::update() {
    sp<ISurfaceComposer> sm(ComposerService::getComposerService());
    return update(sm->getBuiltInDisplay(0));
}
#endif

sp<CpuConsumer> ScreenshotClient::getCpuConsumer() const {
    if (mCpuConsumer == NULL) {
        mBufferQueue = new BufferQueue();