The "legacy" fs-verity was introduced in P in Pixel 3 kernel. During
fs-verity upstream to Linux, the API has changed. During Pixel 4 / Q
development, fs-verity was upstreamed to Linux kernel. By setting
ro.apk_verity.mode = 2, device vendors such as Pixel 4 can opt in to
enable the support. The feature has become mandatory for new devices
shipped with R.
Since Pixel 3 family is no longer supported, it's time to remove the
dead code.
Bug: 120629632
Test: m
Test: TH
Change-Id: I6dacd9bbd38b502ee510ff12970e76342d7b72dd
This method is used for accumulation of long values: if
the key does not exist, one is created. If one already exists,
the passed value is added to the previous value.
This method is similar to the existing
SparseDoubleArray.incrementValue() method
Bug: 215427055
Test: atest FrameworksCoreTests:SparseLongArrayTest
Change-Id: I771d9bc2bdd12ca4260b20186ced70f5862b6f56
This reverts commit 331be9a643.
Reintroducing ag/16366278 since it seems unrelated to b/214053959 (more details on b/214053959#comment55).
Original commit message:
Migrate unsafe parcel APIs in framework-minus-apex
Migrate the following unsafe parcel APIs in framework-minus-apex:
* Parcel.readSerializable()
* Parcel.readArrayList()
* Parcel.readList()
* Parcel.readParcelable()
* Parcel.readParcelableList()
* Parcel.readSparseArray()
This CL was generated by applying lint fixes that infer the expected
type from the caller code and provide that as the type parameter
(ag/16365240).
A few observations:
* In some classes we couldn't migrate because the class also belonged to
another build module whose min SDK wasn't current (as is the case for
framework-minus-apex), hence I suppressed the lint check
(since I'll eventually submit the lint check to the tree).
* In some cases, I needed to do the cast in
https://stackoverflow.com/a/1080525/5765705 to make the compiler happy
since there isn't another way of providing a class of type
Class<MyClassWithGenerics<T>>.
* In the readSerializable() case, the new API also requires the class
loader, that was inferred to by InferredClass.class.getClassLoader().
* Note that automatic formatting and import rely on running hooked up
to the IDE, which wasn't the case here.
Bug: 195622897
Change-Id: I272432e6e082a973f7a50492ec35d79c2b577c93
Test: TH passes
This facilitates exposing the Parsed_ classes as
@SystemApi(client = SYSTEM_SERVER) while keeping everything inside
services.jar rather than having it split across both jars.
This reverts getPackageArchiveInfo to use legacy PackageParser, since
framework.jar can no longer access the moved classes.
Bug: 214038417
Test: presubmit, no logic changes
Change-Id: I152d70fb4f643d32efb012cfb20b0fbc5f88f2d8
Currently, 'dumpsys activity' can dump the state of some managers:
- AutofillManager
- ContentCapturemaanger
- UiTranslationController
But the support for these custom dumping is hardcoded into
Activity itself, which makes it harder to extend. For example,
automotive builds provide an app-side Car object, which currently
cannot be dumped.
This CL makes the mechanism more flexible by providing a couple new
public / SystemAPIs that let Automotive (or other mainline modules)
extend it.
Examples:
$ adb shell dumpsys activity com.android.car.carlauncher/.CarLauncher --list-dumpables
$ adb shell dumpsys activity com.android.car.carlauncher/.CarLauncher --dump-dumpable CarUserManager
$ adb shell dumpsys activity service com.android.systemui/.SystemUIService CarUserManager
NOTE: this CL only adds the new APIs; a follow-up CL will change the
existing managers to use them.
Test: see above
Test: m update-api
Bug: 149254050
CTS-Coverage-Bug: 149254050
Change-Id: I6920ff3542d3d75edd667c2c7658e9d0a7af534f
Also, introduce ModemPowerProfile to handle the data in the modem
element.
Bug: 207697945
Test: atest PowerProfileTest
Change-Id: I6f692106309644a1b9a6d4ad2adc9eb08a598b26
Unless we are looking at stack traces (e.g. from strict mode) it's not
possible to identify which type of object is not being closed (most
methods are 'close' or 'release). Change the logged text to clarify.
Change-Id: Ib90eac716f43c2c2caf8d8c6fb64a7bd90562da9
Test: manual
Migrate the following unsafe parcel APIs in framework-minus-apex:
* Parcel.readSerializable()
* Parcel.readArrayList()
* Parcel.readList()
* Parcel.readParcelable()
* Parcel.readParcelableList()
* Parcel.readSparseArray()
This CL was generated by applying lint fixes that infer the expected
type from the caller code and provide that as the type parameter
(ag/16365240).
A few observations:
* In some classes we couldn't migrate because the class also belonged to
another build module whose min SDK wasn't current (as is the case for
framework-minus-apex), hence I suppressed the lint check
(since I'll eventually submit the lint check to the tree).
* In some cases, I needed to do the cast in
https://stackoverflow.com/a/1080525/5765705 to make the compiler happy
since there isn't another way of providing a class of type
Class<MyClassWithGenerics<T>>.
* In the readSerializable() case, the new API also requires the class
loader, that was inferred to by InferredClass.class.getClassLoader().
* Note that automatic formatting and import rely on running hooked up
to the IDE, which wasn't the case here.
Bug: 195622897
Test: TH passes
Change-Id: I11a27b9bdab7959ee86e90aa1e1cbebd7aaf883c
For power users, the monitoring on phantom processes could be turned
off from the Settings->Developer Options->Feature flags.
Bug: 210353231
Bug: 205156966
Test: Manual
Test: atest AppChildProcessTest
Test: atest CtsAppTestCases:ActivityManagerTest
Change-Id: I05f5b43e281b98676c615d350c213620d3d72b5c
Instead of having only one switch to enable all binder tracing,
we seperate between stack tracking and tracing. Stack tracking
still works as before. However, the more lightweight option,
tracing using android.os.Trace, is toggleable separately and will
work on the receiver side without dumping the entire stack trace.
We also make the tracing more efficient by caching
getTransactionName and concatting the class name.
Also, enable this selectively for SysUI+Launcher, which is
currently the focus of always-on-tracing effort to figure out
what kind of binder calls these processes are calling which seems
to contribute a huge amount of jank (long binder calls are in
>= 50% of janky traces).
Test: external/perfetto/tools/record_android_trace gfx view freq sched wm am aidl
Test: atest aidl_unittests
Bug: 202278427
Change-Id: I4d803d073cc4b69d07fa433bfef7e1c7f45132b7
NetworkTemplate with MATCH_CARRIER can be created in NPMS,
and can be backup by SettingsBackupAgent. However, since
the meteredness is not stored in the backup. After incorrectly
deducing from match rule, meteredness always becomes
METERED_ALL after restoring from backup.
This change also adds debug log if any non-persistable template
is being backed up.
Test: TH, dedicated test is included in the follow-up CL.
Bug: 204830222
Change-Id: I865b1d6e571ed998a75b776f01afc7c2534af2dc
Changes IPackageManager.aidl methods to use long flags instead of int.
Public API change to be followed.
BUG: 204432643
BUG: 204433659
Test: manual
Change-Id: Ib5c42fef998f0116e312c71d620e1a15329e26e0
Change to using ISO 8601 duration formatting for LocalLog local
timestamps, which makes it consistent with other time / time zone
detection dumpsys for easier comparison.
LocalLog is used by NetworkStack code as a standalone library, so
therefore has to depend on public SDK APIs, hence the use of Duration.
The local timestamp logging mode is only currently used for time / time
zone detection, which is low-frequency logging.
Bug: 204855374
Test: atest core/tests/coretests/src/android/util/LocalLogTest.java
Change-Id: Idce0d39c59670facdf48deca852b862ff0d71991
Execute the on start user lifecycle phase in parallel.
Services will be a added to a new thread pool, and depending
on which category they are in, they will either be executed
right away (bootstrap and core categories), or run in parallel
along with other services in that category (other category).
This change will only apply for non-system users for now.
Additionally, low ram devices will have this change disabled.
Initial results show about 16% improvement in execution times.
Note: This CL does not enable the thread pool, a separate CL will
enable it.
Bug: 197257926
Test: atest UserLifecycleTests
Change-Id: I76ba673f78b69c7f0caac2d843fa77079e92138a
Test: Rebuilt rom and see flag enable.
Bug: 197829997
Change-Id: Ib2490a58c39cfeddc588c5355b652fcb86d391bd
Merged-In: Ib2490a58c39cfeddc588c5355b652fcb86d391bd
It shows the path of the base filename.
Test: atest FrameworksUtilTests:android.util.AtomicFileTest
Fixes: 203131233
Change-Id: Ib8d36610a4c34d210cc465ec8006d4df33ef638d