Revert "libsnapshot: set thread priority"
This reverts commit db560090e4
.
Reason for revert: breakage on aosp-main
Change-Id: Ib3384dce1e08dd19bce305eee4249d7167d74e10
This commit is contained in:
parent
db560090e4
commit
0168ec74d0
2 changed files with 2 additions and 8 deletions
|
@ -577,10 +577,8 @@ bool MergeWorker::Run() {
|
|||
SNAP_LOG(ERROR) << "Merge terminated early...";
|
||||
return true;
|
||||
}
|
||||
auto merge_thread_priority = android::base::GetUintProperty<uint>(
|
||||
"ro.virtual_ab.merge_thread_priority", ANDROID_PRIORITY_BACKGROUND);
|
||||
|
||||
if (!SetThreadPriority(merge_thread_priority)) {
|
||||
if (!SetThreadPriority(ANDROID_PRIORITY_BACKGROUND)) {
|
||||
SNAP_PLOG(ERROR) << "Failed to set thread priority";
|
||||
}
|
||||
|
||||
|
|
|
@ -17,10 +17,8 @@
|
|||
#include <libsnapshot/cow_format.h>
|
||||
#include <pthread.h>
|
||||
|
||||
#include "android-base/properties.h"
|
||||
#include "read_worker.h"
|
||||
#include "snapuserd_core.h"
|
||||
#include "user-space-merge/worker.h"
|
||||
#include "utility.h"
|
||||
|
||||
namespace android {
|
||||
|
@ -261,10 +259,8 @@ bool ReadWorker::Run() {
|
|||
SNAP_LOG(INFO) << "Processing snapshot I/O requests....";
|
||||
|
||||
pthread_setname_np(pthread_self(), "ReadWorker");
|
||||
auto worker_thread_priority = android::base::GetUintProperty<uint>(
|
||||
"ro.virtual_ab.worker_thread_priority", ANDROID_PRIORITY_NORMAL);
|
||||
|
||||
if (!SetThreadPriority(worker_thread_priority)) {
|
||||
if (!SetThreadPriority(ANDROID_PRIORITY_NORMAL)) {
|
||||
SNAP_PLOG(ERROR) << "Failed to set thread priority";
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue