Create PROCESS_CAPABILITY_IMPLICT_CPU_TIME
Replace the FREEZER_CUTOFF_ADJ check with a granted capability. The advantage of this capability over the check is the capability can easily be propogated, which should work without additional effort when FREEZER_CUTOFF_ADJ gets changed. The goal of this change is closely mirror to prior behavior of the FREEZER_CUTOFF_ADJ based check on freeze policy evaluation, but there are a couple scenarios that will see a change in behavior (for the better). - using BIND_ABOVE_CLIENT will no longer cause a process to accidentally freeze themselves. - Cached UI process will no be frozen if bound to by a unfrozen process. Additional changes: - Change the aconfig flag name to better reflect the nature of the two cpu time capabilities. - Grant attaching processes CPU_TIME to avoid their getting frozen. - Update CachedAppOptimizer#onBlockingFileLock to consider all unfreeze scenarios when evaluating a blocked process. Flag: com.android.server.am.cpu_time_capability_based_freeze_policy Fixes: 402822818 Bug: 403034947 Test: atest MockingOomAdjusterTests Change-Id: Ic22d79cd323e20f19fdd5da9bc5eb3ded02c7a95
Loading
Please register or sign in to comment