1368 Commits

Author SHA1 Message Date
Tej Singh
80d273e43d Remove network transport from core/proto
Move the network transport type to proto_logging. It is needed in
atoms.proto, and all atoms.proto dependencies should live in
proto_logging. Previously, networkcapabilities.proto was in
proto_logging, but the majority of that proto is not needed for logging
and is used for incident reports.

Test: m
Bug: 182392879
Change-Id: I24ff96806e417ad4ee89d84f051ea790a416338f
Merged-In: I24ff96806e417ad4ee89d84f051ea790a416338f
2021-03-18 21:05:16 -07:00
Tej Singh
91bceaae7a Move service/enums.proto to proto_logging
Add usb contaminent status to service/enums.proto. It was previously in
usb.proto, but is an enum. Enums.proto is a better fit because other
enums in usb.proto are located in enums.proto, and the enum is also used
by atoms.proto.

Additionally, move the enums.proto file to proto_logging, since all
atoms.proto dependencies should be in proto_logging.

Test: m
Bug: 182392879
Change-Id: I9ea0a1482336694c446e950ea5cb46b95372b76d
Merged-In: I9ea0a1482336694c446e950ea5cb46b95372b76d
2021-03-18 21:04:48 -07:00
Tej Singh
185bb90134 Add usb and networkcapabilities back to core/proto
usb.proto and networkcapabilities.proto were moved to proto_logging
because they were needed in atom.proto. However, the majority of the
protos aren't needed and belong in core/proto. This moves the files back
in preparation for splitting the relevant enums back into proto_logging.

Test: m
Bug: 182392879
Change-Id: I055a3ca44b83921018697bdefec29161b483d0fe
Merged-In: I055a3ca44b83921018697bdefec29161b483d0fe
2021-03-18 21:04:30 -07:00
Neil Fuller
b2973f8213 Add MetricsTimeZoneSuggestion for metrics use
This tracks an internal change.

Bug: 172934905
Test: build / boot / treehugger
Change-Id: I94ab695250cc7d0db294628f9578f3ffa77b998d
2021-03-11 14:34:33 +00:00
Neil Fuller
c3c171cbe5 OWNERS change / new .proto file
Splitting out GeolocationTimeZoneSuggestionProto to
time_zone_detector.proto.

Test: build only
Bug: 172934905
Change-Id: Ib7798955ae7ab3a486aa33d2bed85f4bbd8511e1
2021-03-11 14:28:59 +00:00
Evgenii Stepanov
15cce113f7 Implement memtagMode and nativeHeapZeroInit manifest attrs.
memtagMode allows an app to opt in to MTE in either sync or async mode.

nativeHeapZeroInit enables automatic initialization of heap memory.

Both attributes default to off and can be specified at either
application or process level.

Bug: 135772972
Bug: 177438394
Bug: 178038272
Test: CtsTaggingHostTestCases

Change-Id: I6a481a9d2363997bf954f248d08224c79f0c2afb
Merged-In: I6a481a9d2363997bf954f248d08224c79f0c2afb
2021-02-25 23:38:33 +00:00
Chris Weir
f0ffb60c50 Add support for tracking PANS data usage
Adds support for tracking oemManagedNetwork types (OEM_PAID and
OEM_PRIVATE).

Bug: 174485293
Test: atest NetworkTemplateTest NetworkStatsCollectionTest
NetworkStatsObserversTest NetworkStatsServiceTest NetworkIdentityTest
Test: verify that the bytes go up in PansTest app only when
`ping -I eth2 8.8.8.8` is run as root.

Change-Id: I78660a835f16265ba8e44bb84332c6633dd72b84
2021-02-17 20:32:53 -08:00
Lorenzo Colitti
20987c3175 Add a registerSystemDefaultNetworkCallback method.
This method allows internal components to track the system
default network. This differs from registerDefaultNetworkCallback
because that method sends callbacks for the default network for
the UID that called it. This may not be the system default
network, for example, when a VPN is up and applies to the UID.

Bug: 173331190
Test: new unit tests in ConnectivityServiceTest
Test: new unit tests in ConnectivityManagerTest
Test: new CTS tests in ConnectivityServiceTest
Test: new CTS tests in HostsideVpnTests in other CL in this topic
Change-Id: Id02748a2183f71b71ff2a53a580466b9dcecaa93
2021-02-09 20:58:28 +09:00
Kevin Han
dba83c49dd Add persistence for app hibernation states
Persist hibernation states to disk. This CL persists the user-level
and global hibernation states to disk.

Bug: 175829330
Test: atest AppHibernationServiceTest
Test: atest HibernationStateDiskStoreTest
Change-Id: If58d648d720bed1693b9346c4d0e85074daec931
2021-02-03 18:17:25 -08:00
Neil Fuller
1f5202afe0 Addition of OWNERS / initial .proto file
Addition of OWNERS entry and the file it pertains to.

Test: build only
Bug: 172934905
Change-Id: I986957f7ead522fa8e13fbf7cbd514691d476858
2021-01-07 15:52:12 +00:00
Xin Li
d31ee38811 Merge rvc-qpr-dev-plus-aosp-without-vendor@6881855
Bug: 172690556
Merged-In: I78222391b83a4add8e964340ec08bb8a1306e1c6
Change-Id: I28bbf40820674675ccf765c912aa8140d3f74ab2
2020-12-02 00:38:58 -08:00
Jeffrey Huang
17df403e9e Move enums file to new directory
Bug: 167962588
Test: m -j
Change-Id: I29b21fdc98c6c795902d23f21ef3dfd11d3f3216
Merged-In: I29b21fdc98c6c795902d23f21ef3dfd11d3f3216
2020-11-25 16:14:08 -08:00
sqian
74207ec1fb Introduce new App Ops permission for 3rd-party InCallService
This permission is intended to be used internally as a system App Ops permission, and let CompanionDeviceManager or RoleManager to grant with
users. If it is granted by user, the corresponding companion app has the ability to query the details of the ongoing calls, and also manage its life cycle.

Bug: 169595473
Test: atest ThirdPartyInCallServiceAppOpsPermissionTest
Change-Id: Ie0f790aab2edcd52cfdbded2630347b9f8dd4d49
Merged-In: Ie0f790aab2edcd52cfdbded2630347b9f8dd4d49
(cherry picked from commit 334ab546e46ff5916eb6239f98ee3462498e87c9)
2020-11-09 21:00:55 +00:00
Nikita Iashchenko
ff64fd0f36 Import TLS handshake atom for Conscrypt
Bug: 160345816
Test: m droid
Change-Id: I7ddf7626376bd649c8b10306d464b783cf16959b
Merged-In: I142a792c34dced6b0e27b867ed3a1d95249a5f7f
2020-11-03 16:48:04 +00:00
Shuo Qian
e3edd0a3c3 Try to add AppOps Keys into Proto to unblock my project
My code https://googleplex-android-review.git.corp.google.com/q/topic:%223rd-incall%22+(status:open%20OR%20status:merged),
 which is adding a proto enum for a new AppOps, is causing presubmit
 failure (https://android-build.googleplex.com/builds/tests/view?invocationId=I62800006309385464&redirect=http%3A%2F%2Fsponge2%2F8a607de5-e0c3-4349-b3c4-0ee397685e18&testResultId=TR55614315792892488).
I cannot check in my code because of this failure.

To solve this failure, one of the next step is:
adding AppOps 100-102 there

Test: Treehugger
Bug: 169595473
Change-Id: Ibd0f85575c9bc3d7aca9d5b011f1e5f0cbf960c1
Merged-In: Ibd0f85575c9bc3d7aca9d5b011f1e5f0cbf960c1
(cherry picked from commit 503ee6ad3be976c3a436a783cb4ee65169d92c16)
2020-10-29 22:15:08 +00:00
Govinda Wasserman
6e8d9e5cb6 Merge "Adds Assistant Handles learning state to backed up settings" into rvc-qpr-dev am: 01c000eff1
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/12656264

Change-Id: Id9a1336991a0745f62b33c85250c45cc0f66b4b9
2020-09-23 17:41:15 +00:00
Govinda Wasserman
6c6e754f63 Adds Assistant Handles learning state to backed up settings
This solves the issue where the device would forget the learned state
when restoring from a backup.

Test: Tested locally
BUG: 159807978
FIX: 159807978
Change-Id: Ia1d5926621c4b45402036aaf06cbab19c12869bd
Merged-In: Ia1d5926621c4b45402036aaf06cbab19c12869bd
2020-09-23 02:18:28 +00:00
TreeHugger Robot
8940f10402 Merge "Add a SettingsProvider key for Adaptive connectivity" into rvc-qpr-dev am: b0df580193
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/12383606

Change-Id: I7421c1f07d89d1b7c5371c83ed8a94f7f4ae9c71
2020-08-24 16:05:11 +00:00
Arc Wang
d631c648b3 Add a SettingsProvider key for Adaptive connectivity
Adaptive connectivity is a feature to manage 5G connectivity
for better battery life.

Bug: 162871294
Test: compile
Change-Id: I719e44a29a54ee886e5d3a7180fd3ad9a7dff599
Merged-In: I719e44a29a54ee886e5d3a7180fd3ad9a7dff599
2020-08-24 20:26:16 +08:00
Peiyong Lin
b18a2fccc3 Rename game driver to updatable driver.
Game driver is considered a production name. We should use the term
updatable driver instead of the production name.

Bug: b/164449016
Test: build
Change-Id: I787f97b4801dcc7b5ec2acd569a7ce284c9a1f18
2020-08-14 10:44:59 -07:00
Peiyong Lin
7bc64bdf00 Use more inclusive terms.
BUG: b/162288333
Test: N/A
Change-Id: Icd58adb5eb19395548f20bd9349639e84a0cce88
2020-07-29 16:23:28 -07:00
Peiyong Lin
b967a4c381 Use more inclusive terms inside GraphicsEnvironment.
Bug: b/162288333
Test: N/A
Change-Id: I2f1f13a892be0c8ff3f89e0ceabe39058390727d
2020-07-27 23:57:50 -07:00
TreeHugger Robot
bec22864d7 Merge "Don't count proxied jobs toward scheduling limit." into rvc-dev am: 9994c816a8
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/12122206

Change-Id: I8935806ef8c466be9283107dc33fe73698fabd80
2020-07-13 18:22:23 +00:00
Kweku Adams
c6b55f33ac Don't count proxied jobs toward scheduling limit.
1. Some API calls (such as SyncManager calls) can result in multiple job
schedule calls. Given that underlying implementation detail, we don't
count jobs scheduled via proxy towards the source app's schedule limit.
Calls using scheduleAsPackage for itself will still count.
2. Limit the number of times we log that a specific app has exceeded the
limit to once per minute.
3. Update the error message and documentation to help developers
identify what to do when they encounter the issue.

Bug: 160796417
Test: atest JobSchedulerServiceTest
Test: atest JobSchedulingTest
Change-Id: Ia682aa889ec2a26d373d0309e8c0324570f7d816
Merged-In: Ia682aa889ec2a26d373d0309e8c0324570f7d816
2020-07-10 23:58:27 +00:00
TreeHugger Robot
cd463e4191 Merge "Correct the name of enum UserType item" into rvc-dev am: 06cfd49914
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/11932651

Change-Id: I75103ba087a2539c987a85b73976a9a0a77aa391
2020-06-22 17:21:12 +00:00
TreeHugger Robot
06cfd49914 Merge "Correct the name of enum UserType item" into rvc-dev 2020-06-22 17:06:58 +00:00
lifr
ad14a26c2c Correct the name of enum UserType item
Test: Run statsd_testdrive
Bug: 153942334
Change-Id: Ibefb4a9c03ae0bf3ea9cd2ce186223860aa42e74
2020-06-22 14:34:50 +08:00
TreeHugger Robot
c10dd8bbca Merge "Statsd notif logs: important conversations." into rvc-dev am: 263c7f9bc1
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/11931359

Change-Id: Ia5a8345f679b20f410857eef9227ceca7b573d94
2020-06-19 22:55:14 +00:00
TreeHugger Robot
263c7f9bc1 Merge "Statsd notif logs: important conversations." into rvc-dev 2020-06-19 22:48:49 +00:00
Beth Thibodeau
7a2dfd3422 [DO NOT MERGE] Support toggling resumption in Settings am: c1bc307bce
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/11817534

Change-Id: Ie0520c407c27112a05049ef6627528e204ffdff2
2020-06-19 22:40:39 +00:00
Will Brockman
3ec0934486 Statsd notif logs: important conversations.
Adds an importance level for "important conversation" to the
notification posted and notification channel updated logs.

Bug: 155064930
Change-Id: Ib5a47aeb2da4d8614bfc778f3771479256220b23
Test: atest PreferencesHelperTest NotificationManagerServiceTest
Test: statsd_testdrive
2020-06-19 16:55:02 -04:00
Beth Thibodeau
c1bc307bce [DO NOT MERGE] Support toggling resumption in Settings
Moved setting so we can use Tunable:
adb shell settings put secure qs_media_resumption 1

If setting is changed, removes all existing resume players

Bug: 154039093
Test: manual
Test: atest SettingsProviderTest
Test: atest com.android.systemui.media

Change-Id: Iad056fbad4520cfe762d9e9f5ed62d38ea1117b1
2020-06-18 23:58:11 +00:00
Treehugger Robot
7e57780ddd Merge "Set min_sdk_version to be part of mainline modules" am: 7bca9bf7de am: e4fe4b211d
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1336117

Change-Id: I5ee224d768e9958cf3321f13236b5ea473e33d66
2020-06-18 17:18:10 +00:00
Frank Li
daa335dd66 Merge "Adding Network Tethering Metrics/atoms" into rvc-dev am: 53795ae7ae
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/11877918

Change-Id: If7cf9571ae7554ed3e757446fdbc8341bd8b2007
2020-06-18 05:04:23 +00:00
lifr
8abf3a7c23 Adding Network Tethering Metrics/atoms
Test: Run statsd_testdrive
Bug: 153942334
Change-Id: Ia0dc1dd45e006348c3856b483972a4ccd6048d05
2020-06-18 10:36:07 +08:00
Hyunyoung Song
9b806c2245 Merge "Add two more enums to LauncherState" into rvc-dev am: d53382b05d
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/11876680

Change-Id: I795a4db555825cea63b97764ecef68ca3a106d41
2020-06-17 16:13:15 +00:00
Hyunyoung Song
d53382b05d Merge "Add two more enums to LauncherState" into rvc-dev 2020-06-17 16:05:34 +00:00
Jooyung Han
6c8a51c9f6 Set min_sdk_version to be part of mainline modules
Modules contributing mainline modules (APK/APEX) should set
min_sdk_version as well as apex_available.

For now setting min_sdk_version doesn't change build outputs.
But build-time checks will be added soon.

Bug: 152655956
Test: m
Change-Id: I9b630aabff01eb1dd5dc4c0f14517e6d1a914126
2020-06-17 14:36:10 +09:00
Frank Li
fb5e5063f3 Merge "Adding NetworkStack Metrics/atoms" 2020-06-17 03:27:19 +00:00
Nikita Ioffe
2ea633314f Merge "Start OP_NO_ISOLATED_STORAGE on am instrument --no-isolated-storage" into rvc-dev am: 663727472a
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/11798518

Change-Id: I0c5fc35f9251c3ffd43b43d63b7bfbbddf8d5061
2020-06-16 20:31:04 +00:00
Nikita Ioffe
663727472a Merge "Start OP_NO_ISOLATED_STORAGE on am instrument --no-isolated-storage" into rvc-dev 2020-06-16 20:17:29 +00:00
Hyunyoung Song
244abe21b6 Add two more enums to LauncherState
Test: system image builds
Bug: 137777105

Change-Id: Ie383809b8d38dbaed8fd99e46a0cc712b1d202d7
2020-06-16 09:34:26 -07:00
lifr
130535ff19 Adding NetworkStack Metrics/atoms
Here are some new atoms we added.
1. NetworkIpProvisioningReported
2. NetworkDhcpRenewReported
3. NetworkValidationReported
4. NetworkStackQuirkReported

Test: Run statsd_testdrive
Bug: 151796056
Change-Id: I1268bdbee11a704705d466567e8ba09748b03bb6
Merged-In: I1268bdbee11a704705d466567e8ba09748b03bb6
(cherry picked from commit 1cc318d0503cc6b6b023025214a151209525ed58)
2020-06-16 07:58:54 +00:00
Michael Wachenschwanz
87d07e8891 Merge "Add BlobStore atoms" into rvc-dev am: 38da493ae4
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/11818786

Change-Id: Iccf6b1f4041ffb8a12f359167d8aa4e5a6b4f8ec
2020-06-13 09:35:05 +00:00
Michael Wachenschwanz
1a7f7ab4aa Add BlobStore atoms
Bug: 144155167
Test: atest android.cts.statsd.atom.UidAtomTests
Change-Id: I650dfdf6e2f7b6fff29ba6fdf5010a151fd503b5
2020-06-13 01:17:17 +00:00
Frank Li
f572adce1e Merge "Adding NetworkStack Metrics/atoms" into rvc-dev am: 64a3cb03e7
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/11629772

Change-Id: I4b789b7c68ede5dd6d73cb5b1c4030855d49940f
2020-06-12 04:58:01 +00:00
Frank Li
64a3cb03e7 Merge "Adding NetworkStack Metrics/atoms" into rvc-dev 2020-06-12 04:50:57 +00:00
Nikita Ioffe
ac095e5a1d Start OP_NO_ISOLATED_STORAGE on am instrument --no-isolated-storage
This provides a signal for MediaProvider to whitelist access for full
external storage access.

Here is an overview of how the flow looks like:

1. When app is started within instrumentation with --no-isolated-storage
flag, ActivityManagerService will grant OP_NO_ISOLATED_STORAGE to that
package.
2. MediaProvider will note the OP_NO_ISOLATED_STORAGE app op as fallback
in case app doesn't have MANAGE_EXTERNAL_STORAGE permissions.
3. When instrumentation finishes, ActivityManagerService will change
mode of OP_NO_ISOLATED_STORAGE app op to MODE_ERRORED.

Test: atest ExternalStorageHostTest
Bug: 149894531
Change-Id: I51cd87e5e887b887fd8ac7a1a7ffff208266ffa8
2020-06-11 19:51:54 +01:00
lifr
1cc318d050 Adding NetworkStack Metrics/atoms
Here are some new atoms we added.
1. NetworkIpProvisioningReported
2. NetworkDhcpRenewReported
3. NetworkValidationReported
4. NetworkStackQuirkReported

Test: Run statsd_testdrive
Bug: 151796056
Change-Id: I1268bdbee11a704705d466567e8ba09748b03bb6
2020-06-10 16:40:31 +08:00
TreeHugger Robot
bfef7f45e7 Merge "pulled atom for Do Not Disturb configuration" into rvc-dev am: 5599ca731f
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/11494623

Change-Id: Ib9e26c9c56e952719a071d35219d4f011fbcba80
2020-06-10 02:48:58 +00:00