The new method hasExplicitIdentity will track whether the caller is
within a Binder.clearCallingIdentity/restoreCallingIdentity block based
on packing this state information into the token returned by clearCallingIdentity.
Bug: b/252975769
Test: android.os.cts.BinderTest
Change-Id: I162db933f9e52cd6f9f46796bda11ad6216d3d66
ServiceManager.getDeclaredInstances is needed for Remote Key
Provisioning mainline module to get all the implementations for
IRemotelyProvisionedComponent.
Test: build + usage in Remote Key Provisioning mainline module.
Change-Id: I92545104fa9bc190fe7c2f84b33d5f8693fcc2a4
Log.wtf on eng builds when setWarnOnBlocking is enabled. Previously,
setWarnOnBlocking would only log a WTF on userdebug builds.
Bug: 32715088
Test: Manual
Change-Id: Iab416c58827db558d21e518c09af1dac1569ebe8
Requirement to use stable AIDL parcelables in priv-apps.
Bug: 254476191
Test: aidl_integration_test, build target added which uses this
Change-Id: Ib2434e5566bf8bd804f76cf1e63ec1df0e904d77
Defines a new PermissionEnforcer class used to check permission as part
of the @EnforcePermission AIDL annotation. It is registered as a system
service to avoid the cost of creating a new object for each new client.
Bug: 234083358
Test: TH
Change-Id: I2bd23f62a0d207ddac6bbe69666ced96e77ba16f
Merged-In: I2bd23f62a0d207ddac6bbe69666ced96e77ba16f
Change the sense of the run-time switches so that ANGLE can be an
optional GLES driver or the default system GLES driver. When ANGLE is
the system GLES driver, also handle the case of there being no legacy
GLES driver.
Test: logcat
Test: atest CtsAngleIntegrationHostTestCases
Test: atest CtsEffectTestCases:android.effect.cts.EffectTest#test5_effectCreate
Bug: 224558229
Change-Id: Ie53f5221d51b62db226c0c634537959612a06655
Merged-In: Ie53f5221d51b62db226c0c634537959612a06655
Any AIDL interface that has @VintfStabilty should be
able to be used everywhere.
Bug: 254476191
Test: aidl_integration_test
Change-Id: I3138a6e4dbfdfb972d87e7c4eb9b591be40b6d39
All the code using getCallingUid here should be
ripped out anyway because it's Java-centric. Here
are some of the issues with the current stuff around
here:
- it's broken because it won't handle things happening in
native code
- it's slow (e.g. big transactions are already logged in
native code anyway)
Bug: 254835230
Test: boots, atest MicrodroidTestApp (with new tests)
Change-Id: I7315059bff138966e9509f1d529a6417466d2b7f
Platform API, in order to fix bugs like b/254835230 where
certain utilities call getCallingUid, which doesn't make
sense for RPC calls.
Bug: 254835230
Test: android.os.ParcelTest
Change-Id: If2dd13d8edd515c945ccde2a2554f6f2b7b87b26
Update documentation for methods areAllEffectsSupported and areAllPrimitivesSupported to explain the default behavior for empty queries. The behavior remains unchanged.
Change-Id: I23dd792af7e3ee2c70fec136fb7db4965a7195be
Fix: 237509304
Test: N/A
Previously, for each binder interface, we populated a cache of all
txn codes to names on the first binder txn to that interface. This
skewed the binder txn latency significantly for the first txn to an
interface.
Now, we lazily populate the cache on each new binder txn.
Test: atest open-prebuilt-calculator --rebuild-module-info
--tf-template metric_post_processor=
google/template/postprocessors/metric-file-aggregate.xml
(neglible startup time diff locally)
Bug: 246650647
Change-Id: Ib569ebe34e7ef6bb4fa6e53defedcb33ed824308
Merged-In: Ib569ebe34e7ef6bb4fa6e53defedcb33ed824308
This works around b/156126072 which introduces app startup latencies
that are multiplied with binder txn tracing enabled.
Skiping tracing interfaces without binder txn names avoids tracing
interfaces like ContentProviders and app-defined interfaces. This is
still an improvement on the status quo since we still trace the
auto-generated framework interfaces.
When we fix sporadic binder calls in the app-startup critical path, we
can remove the restriction and enable tracing more broadly.
Note that we still keep the old behavior of 'best effort' trace names
when binder call stack sampling tracing is enabled
Test: Manual
Bug: 246650647
Change-Id: Id04b701f97241cbd5d14bbb368fdd8527b6f8c93
Previously, binder txns were only traced for txns from sysui/launcher
to system_server.
ag/Iffc4bb534d239c07d2e4d43ab43a9ed76abe7496 enabled binder txn tracking
more broadly
Removed the special case for sysui/launcher and cleaned up the code
Test: Manual
Bug: 161393989
Change-Id: I9d46d2362ca0ca33bc2477d68092f7ba5fe9c8ac
Merged-In: I9d46d2362ca0ca33bc2477d68092f7ba5fe9c8ac
Previously, binder txns were only traced for txns from sysui/launcher
to system_server.
aosp/I57857443495475b1d2efa82cbcb448af5d37a79a and
aosp/I01d520afa8e26eabb97318192151b707b002c28b enabled aidl tracing
if aidl#gen_trace or aidl#generate_traces respectively is true.
Guarded tracing on the availability of txn names instead
Test: Manual
Bug: 161393989
Change-Id: Iffc4bb534d239c07d2e4d43ab43a9ed76abe7496
Merged-In: Iffc4bb534d239c07d2e4d43ab43a9ed76abe7496
This API will get the advertised memory size from the bootloader parameter
passed to the kernel. The advertised memory size might be different from
the MemTotal value in /proc/meminfo. This could be due the original design
manufacturer (ODM) reserved part of the memory for the Trusted Execution
Environment.
Test: Run test caes
Bug: 231718727
Change-Id: I06494cb9013048d73a83f2180a9241c2259d46eb
The method parseSize() will parse the strings that match
the regular expression:
"^((\\s*[-+]?[0-9]+)\\s*(B|K|KB|M|MB|G|GB|Ki|KiB|Mi|MiB|Gi|GiB)\\s*)$"
For example: 12GB, +100MB, 23MiB.
It will return the size in bytes.
Test: atest
Bug: 231718727
Change-Id: Id4b9084d2ff8a0a8bd23ddb8a7e10dcf17391c49
This is a partial backport of ag/19532036. It fixes a bug where a
LazyValue might have been pointing to a parcel which was already
recycled.
Bug: 240138318
Test: atest android.os.cts.ParcelTest android.os.cts.BundleTest
android.os.BundleTest android.os.ParcelTest
android.os.BundleRecylingTest
Test: Running PoC app from linked bug
Change-Id: I3acf7127fdf373ee8b38a55702ae315be499601c
Merged-In: I8a878a6d0055b04b2611909b4b17977ba5677a4f
(cherry picked from commit d2f9cc6342)
Merged-In: I3acf7127fdf373ee8b38a55702ae315be499601c