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

Commit a93dbeb7 authored by Steve Kondik's avatar Steve Kondik Committed by Gerrit Code Review
Browse files

Revert "Revert "input: Adjust priority""

 * Fixit.

This reverts commit b7299fc5.

Change-Id: Ic0477225e9b0bb3eb4f2c71ab3b2620f56d947c7
parent a58a9e01
Loading
Loading
Loading
Loading
+8 −2
Original line number Diff line number Diff line
@@ -20,6 +20,7 @@

#include "InputManager.h"

#include <cutils/iosched_policy.h>
#include <cutils/log.h>

namespace android {
@@ -51,13 +52,15 @@ void InputManager::initialize() {
}

status_t InputManager::start() {
    status_t result = mDispatcherThread->run("InputDispatcher", PRIORITY_URGENT_DISPLAY);
    status_t result = mDispatcherThread->run("InputDispatcher",
            PRIORITY_URGENT_DISPLAY + PRIORITY_MORE_FAVORABLE);
    if (result) {
        ALOGE("Could not start InputDispatcher thread due to error %d.", result);
        return result;
    }

    result = mReaderThread->run("InputReader", PRIORITY_URGENT_DISPLAY);
    result = mReaderThread->run("InputReader",
            PRIORITY_URGENT_DISPLAY + PRIORITY_MORE_FAVORABLE);
    if (result) {
        ALOGE("Could not start InputReader thread due to error %d.", result);

@@ -65,6 +68,9 @@ status_t InputManager::start() {
        return result;
    }

    android_set_rt_ioprio(mDispatcherThread->getTid(), 1);
    android_set_rt_ioprio(mReaderThread->getTid(), 1);

    return OK;
}

+2 −0
Original line number Diff line number Diff line
@@ -22,6 +22,7 @@

#include <math.h>

#include <cutils/iosched_policy.h>
#include <cutils/log.h>

#include <ui/Fence.h>
@@ -383,6 +384,7 @@ DispSync::DispSync(const char* name) :
        mThread(new DispSyncThread(name)) {

    mThread->run("DispSync", PRIORITY_URGENT_DISPLAY + PRIORITY_MORE_FAVORABLE);
    android_set_rt_ioprio(mThread->getTid(), 1);

    reset();
    beginResync();
+2 −0
Original line number Diff line number Diff line
@@ -20,6 +20,7 @@
#include <sys/types.h>

#include <cutils/compiler.h>
#include <cutils/iosched_policy.h>

#include <gui/BitTube.h>
#include <gui/IDisplayEventConnection.h>
@@ -92,6 +93,7 @@ void EventThread::sendVsyncHintOnLocked() {

void EventThread::onFirstRef() {
    run("EventThread", PRIORITY_URGENT_DISPLAY + PRIORITY_MORE_FAVORABLE);
    android_set_rt_ioprio(getTid(), 1);
}

sp<EventThread::Connection> EventThread::createEventConnection() const {
+2 −0
Original line number Diff line number Diff line
@@ -27,6 +27,7 @@

#include <EGL/egl.h>

#include <cutils/iosched_policy.h>
#include <cutils/log.h>
#include <cutils/properties.h>

@@ -493,6 +494,7 @@ void SurfaceFlinger::init() {

    mEventControlThread = new EventControlThread(this);
    mEventControlThread->run("EventControl", PRIORITY_URGENT_DISPLAY);
    android_set_rt_ioprio(mEventControlThread->getTid(), 1);

    // initialize our drawing state
    mDrawingState = mCurrentState;
+2 −0
Original line number Diff line number Diff line
@@ -30,6 +30,7 @@

#include <EGL/egl.h>

#include <cutils/iosched_policy.h>
#include <cutils/log.h>
#include <cutils/properties.h>

@@ -541,6 +542,7 @@ void SurfaceFlinger::init() {

    mEventControlThread = new EventControlThread(this);
    mEventControlThread->run("EventControl", PRIORITY_URGENT_DISPLAY);
    android_set_rt_ioprio(mEventControlThread->getTid(), 1);

    // set a fake vsync period if there is no HWComposer
    if (mHwc->initCheck() != NO_ERROR) {