It used to be in system server, but this is for a class in boot
classpath so we can move it to AndroidRuntime.cpp and avoid system
server dirtying memory for these methods.
Test: m
Bug: 162110941
Change-Id: Ifda5957aab757fe47c97b1aee0a6a8b7a059ac3d
Currently, socket tagging is implemented in the framework. The
Java code is in NetworkManagmentSocketTagger.java and the JNI is
in libandroid and loaded by the general framework JNI loader.
- Move the Java implementation to TrafficStats, which is the only
caller of NetworkManagmentSocketTagger. This simplifies the
code a bit because a number of methods can be deleted.
- Move the JNI code to a new JNI library in the APEX. The library
depends only on the NDK and statically links the NDK-only
version of libnativehelper. Its size is only 5k on ARM and 10k
on ARM64.
- Temporarily make the framework depend on this library until the
rest of the T connectivity code moves to the APEX.
Test: atest NetworkUsageStatsTest CtsNetTestCases:TrafficStatsTest
Change-Id: I050c7c515237f68b78d08987bc443f50a7949c06
Previously the SurfaceControlFpsListener is a hidden API which only
allows platform code access. This patch renames it to follow the
callback convention and raises it to be a system API in order to allow
system applications to access the FPS count of a task and its children.
The FPS count access is guarded by a permission ACCESS_FPS_COUNTER.
To follow the API convention and properly check the permission, the
register/unregister callback APIs are moved to WindowManager and
permission check is done in the System Server.
Minor: Rename to SurfaceControlFpsCallback to TaskFpsCallback in order
to follow the API naming convention.
Bug: b/199920468
CTS-Coverage-Bug: b/199920468
Test: atest TaskFpsCallbackTest
Change-Id: I6b0a0ad6500278b3da09059e9c2ede28d9a743aa
Bug: 203492478
Test: manual -
1. Build a system image and flash it to a device.
2. adb shell setprop dalvik.vm.extra-opts '-verbose:image'
3. adb shell setprop dalvik.vm.profilebootclasspath true
4. adb shell setprop ctl.restart zygote
5. See the boot image extension being compiled in memory
(http://gpaste/4688561208033280).
Change-Id: I69c11e3e41b9ab142b427ee054c2a6275ff089de
This is an eBPF usermap read via libmeminfo. System server
already has permissions to do so (as it already does so for the
total GPU mem stats).
Change-Id: I9e3c4dc9144708c630215e309b7ff394abbdcd76
Test: manual, statsd_testdrive 10064
Bug: 208440056
This matches behaviour described in:
https://developer.android.com/training/articles/perf-jni#extended-checking
All output from CheckJNI state was disabled as part of quietening
logspam, but now we log a message only if CheckJNI is
enabled. CheckJNI is off by default and only used as a developer
correctness tool.
Bug: N/A
Test: adb root; adb shell stop; \
adb shell setprop dalvik.vm.checkjni 1; \
adb shell start; adb logcat -d | grep CheckJNI
Change-Id: I93bc2d097a8769b7768c633b705b29fc1aac634a
* changes:
Move common audio AIDL types to audio.media.audio.common
MediaFormat: Add more audio MIME types
Add android.media.audio.common.AidlConversion class
Add a new header library, libandroid_runtime_vm_headers,
that exposes AndroidRuntimeGetJavaVM.
Test: boots
Bug: 190450693
Change-Id: I64053b56eb1290cff8ea191b1cc592fbc9702ce8
Bug: 192020504
Test: Check logcat with and without the flag.
Change-Id: Ia46a011125a6e245bbd9065d708d1f905d56e3af
Merged-In: Ia46a011125a6e245bbd9065d708d1f905d56e3af
(cherry picked from commit f2a815dcbf)
ART will refuse to load on-device generated artifacts if odsign
verification status suggests files have been tampered with.
(cherry picked from commit a8b24392a1)
Bug: 180949581
Test: manual
Merged-In: I772b5b7b191310bf7c7797161a304a1ab6f53c5e
Change-Id: Ia0e5ebf4c763678fef55139af60b169f0e6fdeee
ART will refuse to load on-device generated artifacts if odsign
verification status suggests files have been tampered with.
Bug: 180949581
Test: manual
Change-Id: I772b5b7b191310bf7c7797161a304a1ab6f53c5e
Add a new header library, libandroid_runtime_threads_headers,
that exposes javaAttachThread / javaDetachThread.
Also change the return value from int to bool, since the client
may not know about JNI_OK.
Test: boots
Bug: 190450693
Change-Id: Ifedd34a8c8a1847d89c9f2f7919ff7e4b13b7446
This reverts commit 516cb2d025.
Reason for revert: Add back after merging f2fs/f2fs-tools changes removing immutable bit stuffs
Bug: 188928405
Change-Id: I6a6fcde1190bff14abe1a67a75b8e7be95d89072
This reverts commit e41b029d85.
Reason for revert: b/189985437
com.android.tradefed.targetprep.TargetSetupError[APK_INSTALLATION_FAILED|520001|DEPENDENCY_ISSUE]: Failed to install com.android.devicehealthchecks with ...
Change-Id: I06fe7d94f6dab474c74b093de8692f08d4031b62
Attribution source is the abstraction to capture the data
flows for private data across apps. Checking permissions
for an attribution source does this for all apps in the
chain that would receive the data as well as the relevant
app ops are checked/noted/started as needed.
Teach speech recognition service about attribution
chains. If an implementation does nothing the OS
would enforce permisisons and do blame as always.
This apporach leads to double blaming and doesn't
support attribition chains where app calls into
the default recognizer which calls into the on
device recognizer (this nests recursively). If the
implementer takes advantage of the attribution chain
mechanims the permissions for the entire chain are
checked at mic access time and all apps are blamed
only once.
Fixed a few bugs around finishing ops for attribution
chains. Also ensured that any app death in a started
attribution chain would lead to finishing the op for
this app
bug: 158792096
Test: (added tests for speech reco)
atest CtsMediaTestCases
atest CtsPermissionTestCases
atest CtsPermission2TestCases
atest CtsPermission3TestCases
atest CtsPermission4TestCases
atest CtsPermission5TestCases
atest CtsAppOpsTestCases
atest CtsAppOps2TestCases
Merged-In: Ic92c7adc14bd2d135ac13b96f17a1b393dd562e4
Change-Id: Ic92c7adc14bd2d135ac13b96f17a1b393dd562e4
Modern f2fs implementations starting in S support compression
natively within the file system. The data blocks of specific
installation artifacts [eg. .apk, .so, ...] can be compressed
at the file system level, making them look and act like any
other uncompressed file, but consuming a fraction of the space.
However, the unused space is not free'd automatically. Instead,
we must manually tell the file system to release the extra
blocks [the delta between the compressed and uncompressed block
counts] back to the free pool.
Because of how compression works within the file system, once
the blocks have been released, the file becomes read-only and
cannot be modified until the free'd blocks have again been
reserved from the free pool. For these installation artifacts,
that is not a concern.
Test: atest CtsAppSecurityHostTestCases:SplitTests
Test: atest CtsAppSecurityHostTestCases:IsolatedSplitsTests
Test: atest CtsAppSecurityHostTestCases:PkgInstallSignatureVerificationTest
Test: atest CtsLibnativehelperTestCases
Test: atest PackageManagerTests
Test: Manual. Boot the device and see cblocks for stub APKs are released
Test: Manual. Disable and re-enable stub APK and see cblocks are released
Bug: 188928405
Change-Id: I4b29dab263d02a79d7b1593d35ae28101d33679a