aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMartin Liu <liumartin@google.com>2020-06-02 21:01:39 +0000
committerAutomerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>2020-06-02 21:01:39 +0000
commitf6dc513ad77f32447c916edbdbed4955d1624c93 (patch)
tree717cb0f2e6c61f039055865a0cde22505ad5cde1
parentb286ce53766861ad1910d04beb5fafb18e6333bc (diff)
parentdfc73bc2fe5d0fa2fa4a8caa9522a1419453485b (diff)
downloadlmkd-f6dc513ad77f32447c916edbdbed4955d1624c93.tar.gz
Original change: https://googleplex-android-review.googlesource.com/c/platform/system/memory/lmkd/+/11699841 Change-Id: I4fc231e488289620dd00a37d1f19de9460a15af8
-rw-r--r--lmkd.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/lmkd.cpp b/lmkd.cpp
index 098fe9f..882ae4a 100644
--- a/lmkd.cpp
+++ b/lmkd.cpp
@@ -2387,7 +2387,7 @@ static void mp_event_psi(int data, uint32_t events, struct polling_params *poll_
"kB < %" PRId64 "kB) and thrashing (%" PRId64 "%%)",
mi.field.free_swap * page_k, swap_low_threshold * page_k, thrashing);
/* Do not kill perceptible apps unless below min watermark */
- if (wmark < WMARK_LOW) {
+ if (wmark > WMARK_MIN) {
min_score_adj = PERCEPTIBLE_APP_ADJ + 1;
}
} else if (swap_is_low && wmark < WMARK_HIGH) {
@@ -2397,7 +2397,7 @@ static void mp_event_psi(int data, uint32_t events, struct polling_params *poll_
PRId64 "kB < %" PRId64 "kB)", wmark > WMARK_LOW ? "min" : "low",
mi.field.free_swap * page_k, swap_low_threshold * page_k);
/* Do not kill perceptible apps unless below min watermark */
- if (wmark < WMARK_LOW) {
+ if (wmark > WMARK_MIN) {
min_score_adj = PERCEPTIBLE_APP_ADJ + 1;
}
} else if (wmark < WMARK_HIGH && thrashing > thrashing_limit) {