summaryrefslogtreecommitdiff
path: root/tools/aapt2/java/JavaClassGenerator_test.cpp
diff options
context:
space:
mode:
authorHui Yu <huiyu@google.com>2021-05-18 16:47:34 -0700
committerHui Yu <huiyu@google.com>2021-05-21 10:51:53 -0700
commitfbf67aac21f5d082b6b584f5c2afce26ec7f23c7 (patch)
treeef9ca0d6cc0b7efb101f343fd7488482b0d0eeb9 /tools/aapt2/java/JavaClassGenerator_test.cpp
parentfc0a05e3e495f770fbb9badc4d5bae21c74a448c (diff)
All FGS exemptions should be propagated via service bindings.
Previously, the BG-FGS-start capability can be passed down over service binding, this was implemented in OomAdjuster, due to performance reason, only an subset of FGS exemptions are passed down. This new implementation move it out of OomAdjuster and can pass all FGS exemptions. Instead of in OomAdjuster it can passed down over infinite number of levels of chain binding, the new implementation will be passed down one level. First we call shouldAllowFgsStartForegroundLocked() on the callingUid that starts the FGS, if the return is DENIED, we check if callingUid has any service that is bound by another UID(clientUid), we call shouldAllowFgsStartForegroundLocked() on clientUid. To check if a BG-FGS-start is allowed by any clientUid over service binding, looking for ""Background started FGS: " string in logcat, if the "clientCallingPackage" field is non-null, the reason BG-FGS-start is because of a clientUid and clientCallingPackage is clientUid's packageName. Bug: 188086703 Test: atest cts/tests/app/src/android/app/cts/ActivityManagerFgsBgStartTest.java#testFgsBindingFlagNone Change-Id: Ia692201909cc5095f4aa25ba5a1588510054fb80
Diffstat (limited to 'tools/aapt2/java/JavaClassGenerator_test.cpp')
0 files changed, 0 insertions, 0 deletions