Commit Graph

15650 Commits

Author SHA1 Message Date
Josh Gao
e18b895a74 Merge changes I8b85d8ee,I789f41f1 am: ddaf564365 am: 4359428db3 am: b4d05a90e9
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1566718

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I3dd17a5aae56597a1eb233dd4743b4deb21ef5d9
2021-02-05 21:45:26 +00:00
Josh Gao
b4d05a90e9 Merge changes I8b85d8ee,I789f41f1 am: ddaf564365 am: 4359428db3
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1566718

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I22b7d2e823d131944d5b02996b8e3e92d2bbc2fa
2021-02-05 21:13:20 +00:00
Jeff Sharkey
e10881e482 Merge "Add People widgets to those owned by System UI Notifications team" am: 460b1255a9 am: c088d267a1 am: d6e31fbd8b
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1577069

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: Icfad672ab84feb4396d3ab93a3bc29abc9189dda
2021-02-05 20:23:25 +00:00
Josh Gao
ddaf564365 Merge changes I8b85d8ee,I789f41f1
* changes:
  Parse proto tombstones.
  Extract tombstone tracking to a separate service.
2021-02-05 20:11:10 +00:00
Jeff Sharkey
d6e31fbd8b Merge "Add People widgets to those owned by System UI Notifications team" am: 460b1255a9 am: c088d267a1
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1577069

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: Iddda0182bbb83b493073a0582d8da539e96acb62
2021-02-05 19:27:33 +00:00
TreeHugger Robot
1890877201 Merge "Simplifying disabled widget view genration" into sc-dev 2021-02-05 19:19:17 +00:00
Jeff DeCew
d5e38f04bb Add People widgets to those owned by System UI Notifications team
Change-Id: I15afb8f80a3d067af522707748a5b07c015af138
2021-02-05 14:09:02 +00:00
Dmitri Plotnikov
1ffcf97a14 Merge "Change the API for getting PowerProfile-only BatteryUsageStats" into sc-dev 2021-02-04 22:55:11 +00:00
Kohsuke Yatoh
a397f0281c Merge "Support multi font update internally." into sc-dev 2021-02-04 22:23:33 +00:00
Todd Kennedy
032c92d481 use consistent method to generate constant value
Change-Id: I32b611661918628c5b8d125ff738069cd2940cb9
Merged-In: I32b611661918628c5b8d125ff738069cd2940cb9
(cherry picked from commit 01f8e8df13)
2021-02-04 20:47:25 +00:00
Evgenii Stepanov
804a79e7b0 Merge "Implement memtagMode and nativeHeapZeroInit manifest attrs." into sc-dev 2021-02-04 19:55:49 +00:00
Kohsuke Yatoh
f57788aaa5 Support multi font update internally.
This CL make UpdatableFontDir support multi font update in transaction.
The public / shell API is TBD.

Bug: 179103383
Test: atest CtsGraphicsTestCases:FontManagerTest
Test: atest FrameworksServicesTests:PersistentSystemFontConfigTest
Test: atest FrameworksServicesTests:UpdatableFontDirTest
Test: atest UpdatableSystemFontTest
Change-Id: If9474a8ab81fe194b2d76080a4b066131fcd9e44
2021-02-04 11:32:28 -08:00
TreeHugger Robot
4c7e9d1a90 Merge "Reduce LocationManager memory usage" into sc-dev 2021-02-04 19:13:26 +00:00
Jing Ji
1d84f539e5 Merge "Add an additional lock in the ActivityManagerService" into sc-dev 2021-02-04 18:32:08 +00:00
Winson
3c7113a401 Remove legacy IntentFilterVerificationManager
Completely deletes all the code for v1 of domain verification,
delegating everything to the new DomainVerificationService.

Exempt-From-Owner-Approval: Already approved by owners on main branch

Bug: 171251883

Test: none, removal of effectively dead code

Change-Id: Ib222ccd46019c1c28b402c0f68466077b62871c1
2021-02-04 10:27:00 -08:00
Winson
2641e601cc Add domain verification API classes
Includes the request class sent to the verification agent and the 2
data classes returned by the to-be-added DomainVerificationManager.

Exempt-From-Owner-Approval: Already approved by owners on main branch

Bug: 163565712
CTS-Coverage-Bug: 179382047

Test: atest DomainVerificationCoreApiTest

Change-Id: If9f1b987f0d06c930f6c44b58af101b83947acb9
2021-02-04 10:26:57 -08:00
Winson
1e8c37a0dc Refactor legacy domain verification code
Moves everything to com.android.server.pm.intent.verify.legacy, in
preparation for replacement with new classes.

No functional changes were made, although the code may be slightly
slower since lambdas are now passed around to do locking.

Eventually the entire legacy package will be deleted. Any attempts at
backwards compatbility will involve a brand new wrapper of the v1 APIs
which delegate into the v2 methods.

Exempt-From-Owner-Approval: Already approved by owners on main branch

Bug: 163565078

Test: atest IntentFilterVerificationTest
Test: manual, verify with `dumpsys package d` that an app auto verifies

Change-Id: Id7d428b939cab6dd887567abcc7ba0e8f3fb7638
2021-02-04 10:26:57 -08:00
TreeHugger Robot
9093da8884 Merge "Avoid detecting WebView as TYPE_RECYCLING" into sc-dev 2021-02-04 12:40:12 +00:00
Adam Bookatz
6344e2dbe8 Merge "MeasuredEnergyStats supports custom energy buckets" into sc-dev 2021-02-04 08:38:15 +00:00
Galia Peycheva
bf21f495df Merge "Make window blur behind public API" into sc-dev 2021-02-04 08:31:45 +00:00
Jing Ji
cfeb2866a4 Add an additional lock in the ActivityManagerService
This CL breaks down the ProcessRecord by the characteristic of
the fields in it. It's a preparation for future CLs, to let
the various components in the ActivityManagerService to access
its own correlated data class only.

Also introduces an additional semi-global lock in the
ActivityManagerService as an effort to reduce the lock contentions.
Some of the data fields now requires either the legacy global lock
or this new lock to read from it, and both of the lock to write to it.

Bug: 162450085
Test: atest CtsAppTestCases
Test: atest FrameworksMockingServicesTests
Test: atest FrameworksServicesTests
Change-Id: I2718dfb8cd5c1852e81280ed11676c567f76d0a2
2021-02-03 20:53:40 -08:00
Adam Bookatz
696dd2af2d MeasuredEnergyStats supports custom energy buckets
MeasuredEnergyStats now supports a variable number of
'buckets', including both the standard buckets (fixed number)
and additional custom buckets (variable number) whose meaning
is unknown to BatteryStats (but is enumerated as an 'ordinal').
This will be used to store per-uid energy data from custom
power components.

Test: atest MeasuredEnergyStatsTest
Test: atest com.android.internal.os.BatteryStatsTests
Bug: 179107328
Bug: 174186358
Change-Id: I0022ac6940daca5f1e7d0e502eed01effa71f796
2021-02-04 02:26:31 +00:00
Benjamin Schwartz
d42057fc61 Merge "BatteryStats: Pull subsystem stats from Power Stats Service" into sc-dev 2021-02-04 01:39:09 +00:00
Bill Yi
46b48bcc66 Merge RQ1A.210205.004 to aosp-master - DO NOT MERGE
Merged-In: Icbc3c9f8e1ac8064e2e006587b4d4870d74cee2d
Merged-In: I2cb57c40fd5679dbd710396f3c69deafbac9d1c3
Change-Id: Ibfd6d85bda975aaa274be9e98e197de048d178ac
2021-02-03 17:01:38 -08:00
Adam Bookatz
52534776ec Merge "Measured screen energy into BatteryStatsHelper" into sc-dev 2021-02-04 00:33:10 +00:00
Sunny Goyal
4671a2d556 Simplifying disabled widget view genration
Removing creating and holding icon bitmaps in systemServer and
directly loading resources in the Host process

Bug: 178616010
Test: Verified View on device
Change-Id: I4abf616985d68ac48f55856bb90fa598a4cebe1c
2021-02-03 22:53:12 +00:00
Josh Gao
9a8b4358d3 Extract tombstone tracking to a separate service.
In preparation for making tombstones available to apps, extract the
tombstone tracking code from BootReceiver to its own service.

Bug: http://b/159164105
Test: manual
Change-Id: I789f41f12a8be312b6e966226646c4ec4becc1aa
2021-02-03 14:08:12 -08:00
Benjamin Schwartz
3bdc838570 BatteryStats: Pull subsystem stats from Power Stats Service
Also remove redundant PlatformIdle stats section from history details

Bug: 173132005
Bug: 178315485
Test: Ran device to drain battery then checked dumpsys batterystats
Test: Verified that Historian could correctly parse the bugreport
Change-Id: I65c1824695dd026231f83664b00f72912dee2164
2021-02-03 12:49:14 -08:00
Dmitri Plotnikov
42b6bb0575 Change the API for getting PowerProfile-only BatteryUsageStats
Bug: 175644968
Test: mp :BatteryStatsViewer && adb shell am start -n com.android.frameworks.core.batterystatsviewer/.BatteryStatsViewerActivity
Change-Id: I66ce64321805423d2545df4691a4df8508f40440
2021-02-03 20:27:47 +00:00
Mark Renouf
d84643adcc Avoid detecting WebView as TYPE_RECYCLING
Currently ScrollCaptureIntrnal only checks for >1 child views
but not >0 child views. Because of this, WebView is considered
a RecyclerView, but this will not work without any Views to
track.

This change classifies these as "OPAQUE" so they can be handled
specially. Until support for these is implemented they will be
skipped as targets.

Bug: 179253269
Test: Open Chrome to a scrollable page, take screenshot
Change-Id: I0b00598031879d2fa7c1295440b3de1e0e453031
2021-02-03 20:00:56 +00:00
Dmitri Plotnikov
df5ebd7eab Merge "Calculate total power for a BatteryConsumer by adding up PowerComponents" into sc-dev 2021-02-03 19:06:15 +00:00
Adam Bookatz
c7f41b68a5 Measured screen energy into BatteryStatsHelper
Use measured screen energy usage (where available)
in battery reporting in BatteryStatsHelper, including
total and per-app screen energy usage.

Regardless of the data source (measured screen power usage vs.
estimating from screen time), the blame on apps is 'smeared',
meaning that it is apportioned (after-the-fact) based on each
app's foreground usage. That does not change here.

Also fixes a mistake in Uid.getScreenOnEnergy().

Future followups to do
1. Make getMeasuredOrEstimatedPower more universal (as more
   PowerCalculators follow suit)
2. Support for BatteryUsageStats
3. Deal with voltage properly
4. Toggle whether to report the measured energy on/off.

Test: atest BatteryStatsHelperTest
Bug: 174818228
Change-Id: I0eaa4bc594cb31b4a26b5488b08114cbf80e3884
Merged-In: I0eaa4bc594cb31b4a26b5488b08114cbf80e3884
(cherry picked from commit 30594e82d5)
2021-02-03 18:46:49 +00:00
Marcin Oczeretko
81ed6656ba Merge "Use PerfettoTrigger to trigger traces from LatencyTracker" into sc-dev 2021-02-03 18:07:04 +00:00
TreeHugger Robot
8dcab0dee6 Merge "Do not propogate test api access flags to Zygote." into sc-dev 2021-02-03 18:01:30 +00:00
Soonil Nagarkar
204b133883 Reduce LocationManager memory usage
Move GNSS listener overhead into statics so it's shared per process, and
do not instantiate by default.

Previously GNSS requests were multiplexed by LocationManager instance,
this is now removed. This could mean additional binder overhead, but
it's pretty unlikely that this feature was in active use anywhere, as in
any large application that has multiple gnss requests, they are usually
coming from different contexts (and thus LocationManager instances) and
would not have seen the benefit of multiplexing anyways.

Bug: 179261871
Test: atest CtsLocationFineTestCases
Change-Id: I8b7a41c13dfe219c326b1e519483d89d2b721ce5
2021-02-03 17:08:16 +00:00
Miranda Kephart
e4081d74ad [DO NOT MERGE] Close screenshot process on user switched am: 05f7aef1b0
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/13070635

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I0de430aa000f81f00da2e64799d17810d506a737
2021-02-03 17:00:54 +00:00
Jeff Sharkey
eb4fdbc3b7 Merge "Add core notifications team as owners of internal notification widgets." am: 752040bead am: 6b3ed78bf6 am: b7cd95098f
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1571164

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I0c79eefd95bb24714c79145fdc907cbd6f4672e8
2021-02-03 16:33:36 +00:00
Galia Peycheva
8e30771f55 Make window blur behind public API
This CL makes the blur behind functionality a public API. As part of
this change, we change its previous name (windowBackgroundBlurRadius) to
windowBlurBehindRadius. This avoids a name clash with the Window
background blur, which only blurs the area of the window. Blur behind
blurs everything behind the window (similar behaviour to the dim).

This CL exposes WM.LP.blurBehindRadius and, in addition, undeprecates an
old flag - FLAG_BLUR_BEHIND. FLAG_BLUR_BEHIND enables the blur behind
and blurBehindRadius specifies how dense the blur will be.

In addition, we expose two xml attributes on the Window -
windowBlurBehindEnable and windowBlurBehindRadius. The usage is similar
to the dim api.

Bug: 167166562
Bug: 177524486
Test: m && test app
Change-Id: If2fcde644c5bcca112495ca99ee66bae909877db
Merged-In: If2fcde644c5bcca112495ca99ee66bae909877db
2021-02-03 16:25:49 +00:00
Jeff Sharkey
b7cd95098f Merge "Add core notifications team as owners of internal notification widgets." am: 752040bead am: 6b3ed78bf6
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1571164

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I7133f6b8f758f6a37973691aea5e1ea2386a848b
2021-02-03 15:54:28 +00:00
Jeff Sharkey
6b3ed78bf6 Merge "Add core notifications team as owners of internal notification widgets." am: 752040bead
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1571164

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I4ced104b3622d406e0eefe64aa311ab5970ccc02
2021-02-03 15:30:13 +00:00
Matt Pietal
0448729358 Merge "Lock Pattern View - Visual update" into sc-dev 2021-02-03 13:08:12 +00:00
Artur Satayev
eb05e6c8fa Do not propogate test api access flags to Zygote.
The flow has been replaced by @ChangeId ALLOW_TEST_API_ACCESS, making
old approach obsolete.

Bug: 147113465
Test: atest CameraEvictionTest#testBasicCamera2ActivityEviction
Merged-In: I0bf109fa78212d6d71ba85d25f80e27e8e7cd900
(cherry picked from commit a27cd30535)
Change-Id: I0e58b6924744590afaadec6a6230aa9d552b2f6f
Exempt-From-Owner-Approval: cp
2021-02-03 12:29:45 +00:00
Galia Peycheva
e6ae6e325a Merge changes from topic "revert-13350963-blur_system_api-AFRJFBKNBA-sc-dev" into sc-dev
* changes:
  Revert "Add permission for blur SystemApi"
  Revert "Make window background blurs SystemApi"
  Revert "Make BackgroundBlurDrawable a SystemApi"
2021-02-03 05:49:41 +00:00
Ahaan Ugale
b7fd9a7814 Merge "VIMS: Clarify NonNullability of PackageMonitor#onPackageModified." into sc-dev 2021-02-03 02:57:18 +00:00
Evgenii Stepanov
6415a1505a 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
2021-02-02 17:38:08 -08:00
Jeff DeCew
c879d183a8 Add core notifications team as owners of internal notification widgets.
Change-Id: Ie1a8e61f8c250340083940af866552e0d15851dd
2021-02-03 01:07:21 +00:00
Galia Peycheva
3804d61f2a Revert "Make window background blurs SystemApi"
Revert "Add permission check for blurs in SurfaceFlinger"

Revert "Remove public usages of FLAG_BLUR_BEHIND"

Revert "Add pid and uid to SF::setClientStateLocked"

Revert "Add USE_BACKGROUND_BLUR to cts expected permissions"

Revert submission 13350963-blur_system_api

Reason for revert: This topic made blurs a system api. API council voted against that and we will instead aim to make it public for S. None of these changes are relevant in that case.

Reverted Changes:
I3683db296:Remove public usages of FLAG_BLUR_BEHIND
I23b21b603:Add USE_BACKGROUND_BLUR to cts expected permission...
Id21f03793:Add pid and uid to SF::setClientStateLocked
If5d8344a5:Add permission for blur SystemApi
I70d1e1715:Add permission check for blurs in SurfaceFlinger
Icf98c3607:Make window background blurs SystemApi
I0b881ec6e:Make BackgroundBlurDrawable a SystemApi

Bug: 177523043
Test: m
Change-Id: I0f7bcf34db2986d8d5e08b115a611e8e07db5917
Merged-In: I0f7bcf34db2986d8d5e08b115a611e8e07db5917
2021-02-02 23:08:29 +01:00
Galia Peycheva
f83b52cc13 Revert "Make BackgroundBlurDrawable a SystemApi"
Revert "Add permission check for blurs in SurfaceFlinger"

Revert "Remove public usages of FLAG_BLUR_BEHIND"

Revert "Add pid and uid to SF::setClientStateLocked"

Revert "Add USE_BACKGROUND_BLUR to cts expected permissions"

Revert submission 13350963-blur_system_api

Reason for revert: This topic made blurs a system api. API council voted against that and we will instead aim to make it public for S. None of these changes are relevant in that case.

Reverted Changes:
I3683db296:Remove public usages of FLAG_BLUR_BEHIND
I23b21b603:Add USE_BACKGROUND_BLUR to cts expected permission...
Id21f03793:Add pid and uid to SF::setClientStateLocked
If5d8344a5:Add permission for blur SystemApi
I70d1e1715:Add permission check for blurs in SurfaceFlinger
Icf98c3607:Make window background blurs SystemApi
I0b881ec6e:Make BackgroundBlurDrawable a SystemApi

Bug: 177523043
Test: m
Change-Id: Iee4b89b06508c7dc3b7266452bb0b987f8670fac
Merged-In: Iee4b89b06508c7dc3b7266452bb0b987f8670fac
2021-02-02 23:02:05 +01:00
Ben Lin
6292565f13 Merge changes If42d4470,Ia0b701b7 into sc-dev
* changes:
  PiP: Add tap-to-unstash function.
  PiP: Allow stashing via dropping on the edge.
2021-02-02 19:27:55 +00:00
Bill Yi
e02a98aab6 Merge RQ1A.210205.004 to stage-aosp-master - DO NOT MERGE
Merged-In: Ie9567c088e4fff075cce5b6f44bd73199377c91b
Change-Id: I3a2480f2cb8331a70141dad9af61ac3fd7f39991
2021-02-02 09:54:38 -08:00