summaryrefslogtreecommitdiff
path: root/services/core/java/com/android/server/am/ActivityManagerService.java
diff options
context:
space:
mode:
authorSuprabh Shukla <suprabh@google.com>2024-03-21 23:27:34 +0000
committerAndroid Build Cherrypicker Worker <android-build-cherrypicker-worker@google.com>2024-03-21 23:27:34 +0000
commit2db4d2ef1ff228f090de338cb6a1d34709bf8de2 (patch)
treedb66d51d29436dee751cb9294fa6bf99f7f5ce7c /services/core/java/com/android/server/am/ActivityManagerService.java
parentffe63966ee48b35a567e483983a2f73a42e5c253 (diff)
downloadbase-2db4d2ef1ff228f090de338cb6a1d34709bf8de2.tar.gz
Always process state changes below TOP_THRESHOLD
Sometimes, we deliberately send a process-state TOP change before the normal oom adjuster update gets triggered for resuming activities. In this case, there may be a duplicate notification for the same process-state change with a newer procStateSeq. We need to ensure we always process these notifications and notify activity manager on completion. These are redundant notifications but should be rare and cheap enough to always process - even if they do not end up changing any of the firewall state. Also modifying the log in ActivityManager to report a wtf whenever the wait timeouts to help emphasize this discrepancy. Test: atest FrameworksServicesTests:NetworkPolicyManagerServiceTest Fixes: 327303931 (cherry picked from https://googleplex-android-review.googlesource.com/q/commit:28afbd2a2183162a38d261c79abdfb50be65e896) Merged-In: I4884072bd6d7820acee67851d7504886564e2348 Change-Id: I4884072bd6d7820acee67851d7504886564e2348
Diffstat (limited to 'services/core/java/com/android/server/am/ActivityManagerService.java')
-rw-r--r--services/core/java/com/android/server/am/ActivityManagerService.java2
1 files changed, 1 insertions, 1 deletions
diff --git a/services/core/java/com/android/server/am/ActivityManagerService.java b/services/core/java/com/android/server/am/ActivityManagerService.java
index 2ee39c577977..09c1dea2f65a 100644
--- a/services/core/java/com/android/server/am/ActivityManagerService.java
+++ b/services/core/java/com/android/server/am/ActivityManagerService.java
@@ -19423,7 +19423,7 @@ public class ActivityManagerService extends IActivityManager.Stub
record.procStateSeqWaitingForNetwork = 0;
final long totalTime = SystemClock.uptimeMillis() - startTime;
if (totalTime >= mConstants.mNetworkAccessTimeoutMs || DEBUG_NETWORK) {
- Slog.w(TAG_NETWORK, "Total time waited for network rules to get updated: "
+ Slog.wtf(TAG_NETWORK, "Total time waited for network rules to get updated: "
+ totalTime + ". Uid: " + callingUid + " procStateSeq: "
+ procStateSeq + " UidRec: " + record
+ " validateUidRec: "