Commit Graph

5168 Commits

Author SHA1 Message Date
David Zeuthen
d1fdef6927 Merge "identity: Add multi-document presentation support." am: 91b96e3454 am: ae0d53c78d am: 62c776a7c2 am: 2bf36b756d
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1824674

Change-Id: I3ab418b52a3915ac324baa59f38fb936e2eee5b4
2022-01-14 22:14:15 +00:00
David Zeuthen
2bf36b756d Merge "identity: Add multi-document presentation support." am: 91b96e3454 am: ae0d53c78d am: 62c776a7c2
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1824674

Change-Id: Idb4d1ddd89a5ca58ccc852c67f098dad04cb1c5c
2022-01-14 21:56:18 +00:00
David Zeuthen
62c776a7c2 Merge "identity: Add multi-document presentation support." am: 91b96e3454 am: ae0d53c78d
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1824674

Change-Id: I8b5ade103c4275871e990369c36480013f47f129
2022-01-14 21:39:07 +00:00
David Zeuthen
91b96e3454 Merge "identity: Add multi-document presentation support." 2022-01-14 21:07:03 +00:00
Joe Bolinger
0cc4a29f4a Merge changes Ifb73b014,Idd1485f1
* changes:
  Check current user when the operations runs for fingerprint hidl.
  Revert "Revert "Fix enrollment cancelation race conditions.""
2022-01-14 19:21:03 +00:00
Kriti Dang
1774563ec0 Merge "Runtime resolution changes" 2022-01-14 08:28:12 +00:00
Joe Bolinger
446644041b Revert "Revert "Fix enrollment cancelation race conditions.""
This reverts commit f4dc031e6c.

Reason for revert: Reapplying with additional change to fix the issue that broke HIDL clients.

Change-Id: Idd1485f182cf841b96ced1dab4b8330ff3b57c2a
2022-01-13 09:54:55 -08:00
Arthur Ishiguro
9ee529d8e0 Merge "Make ContextHubClient.getId() return a 16-bit value" 2022-01-13 17:06:28 +00:00
Kriti Dang
ecf14412d3 Runtime resolution changes
Changed the names of existing display mode APIs.
Added similar APIs in Display class, so that
resolution and refresh rate settings can be pesisted for each display.
The APIs can now be used to set display mode (or only resolution or
refreshRate).

Bug: 206911689
Test: atest DefaultDisplayModeTest

Change-Id: I19655fc347d36e45b5664e2b6faa3d58b5d7004c
2022-01-13 13:47:59 +01:00
bsears
8ba50e5ce4 Merge "Revert "Fix enrollment cancelation race conditions."" 2022-01-13 06:38:54 +00:00
Daniel Chapin
f4dc031e6c Revert "Fix enrollment cancelation race conditions."
This reverts commit c7a7ee892a.

Reason for revert: Droidfood blocking bug: 213962104

Change-Id: I370cafcac7e70febbb77a05647a3fd5d0a158abd
2022-01-13 02:43:44 +00:00
Ashwini Oruganti
776b439703 Merge "Revert "Migrate unsafe parcel APIs in framework-minus-apex"" 2022-01-12 23:07:08 +00:00
Arthur Ishiguro
71c765985b Make ContextHubClient.getId() return a 16-bit value
Limit the return value range based on feedback to reflect the 16-bit
value returned from the framework.

Fixes: 214028356
Test: None
Change-Id: Idaecebd9219e38fd5e04122043274b8a524d8bae
2022-01-12 18:43:04 +00:00
Bernardo Rufino
331be9a643 Revert "Migrate unsafe parcel APIs in framework-minus-apex"
This reverts commit 90bb3709dc.

Reason for revert: b/214053959

Change-Id: Ic271bab1d3eaf677a5989dda9deb944ee2ad6850
2022-01-12 17:44:44 +00:00
Bernardo Rufino
c6ebb14b7d Merge "Migrate unsafer parcel APIs [2]" 2022-01-11 19:20:36 +00:00
David Zeuthen
6fc37331a6 identity: Add multi-document presentation support.
This new PresentationSession interface enables an application to do a
multi-document presentation, something which isn't possible with the
existing API. As a practical example of this consider presenting both
your Mobile Driving License and your Vaccination Certificate in a single
transaction.

Also update the documentation for IdentityCredential to clarify that
the same AuthKey is used for multiple getEntries() calls on the same
credential.

Also deprecate existing IdentityCredential.getEntries() method and
related methods and classes.

Bug: 197965513
Test: New CTS tests and new screen in CtsVerifier
Change-Id: I74534969143882552407917a82f44d43da12711c
2022-01-11 10:40:51 -05:00
Leon Scroggins
a8693ecd42 Merge "DisplayManager: Add an API to query for DISPLAY_DECORATON" 2022-01-07 17:11:47 +00:00
Leon Scroggins III
c66a2ac732 DisplayManager: Add an API to query for DISPLAY_DECORATON
Tunnel through SurfaceControl to determine whether the HWC has this
capability. This allows clients (i.e. SystemUI) to know whether they can
use Composition.DISPLAY_DECORATON. If so, they may want to render
differently (i.e. in A8). See Ib948c38ee189877eda675a6342cb70099f66122b
for an example.

Bug: 193170859
Test: manual
Test: TODO
Change-Id: I9904452b6408199bb1f86de9e21132e4d4444e1a
2022-01-07 09:41:01 -05:00
TreeHugger Robot
b1866650e5 Merge "Remove BLOCK_FLAG_SLIPPERY constant" 2022-01-07 03:44:42 +00:00
Joe Bolinger
ec41e351d3 Merge "Fix enrollment cancelation race conditions." 2022-01-06 23:51:49 +00:00
Rucha Katakwar
a94b166036 Merge "camera: allow GPU usage for isSurfaceForHwVideoEncoder" 2022-01-06 23:39:38 +00:00
Lee Shombert
9a686c07ba Merge "Prepare PropertyInvalidatedCache for SystemApi" 2022-01-06 23:14:05 +00:00
Bernardo Rufino
74ee11c3f4 Migrate unsafer parcel APIs [2]
Manually migrate the few cases of:
* readArray()
* readParcelableArray()

To the new parcel APIs that take the expected type as the last
parameter. This enhances security because it prevents unexpected types
*before* running unparcelling code. More details at go/safer-parcel.

Owners, please check that the type of the objects expected is always a
subtype of the type provided as the 3rd parameter. This is usually easy
to verify due to casts that happen shortly after.

These changes often allowed further transformations but I decided to
avoid them to keep this change small and targeted.

This was manual since it's tricky to get lint to infer the type in
those cases and it was only a few.

Bug: 195622897
Test: TH passes
Change-Id: I262ed7cd6d3bc15b32e9296e88a8a67fdb59e880
2022-01-06 18:35:31 +00:00
Siarhei Vishniakou
131bd82f10 Remove BLOCK_FLAG_SLIPPERY constant
We are no longer logging this information, so this constant / bug number
can be deleted.

Bug: 157929241
Test: none
Change-Id: I6238737fe101415a87b231208fd99a388deb82fc
2022-01-06 04:38:19 -08:00
Joe Bolinger
c7a7ee892a Fix enrollment cancelation race conditions.
This applies the same request/cancel mechanism as commit bdd477a5d1.

Refactor the scheduler into smaller components and add missing test coverage.

Fix: 210090299
Bug: 208303000
Test: atest UserAwareBiometricSchedulerTest BiometricSchedulerTest BiometricSchedulerOperationTest  SensorTest Face10Test
Test: manual (enroll and quickly tap "add another" and then "do it later")
Change-Id: I0c7e4006e6ac6e6c3dc115046fa80d9e60f4bd95
2022-01-06 00:33:24 +00:00
Treehugger Robot
88a15c822e Merge "Fix deadlock issue." am: 6619bac824 am: cadcd9c225 am: acc96efcfa am: efcdf5b5a4
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1918077

Change-Id: I3eb16c525fa951590ea0d90aa95127acd9185265
2022-01-04 18:37:25 +00:00
Treehugger Robot
efcdf5b5a4 Merge "Fix deadlock issue." am: 6619bac824 am: cadcd9c225 am: acc96efcfa
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1918077

Change-Id: Icb20857776295337f74496b85fa1dc9a36f8e537
2022-01-04 18:12:45 +00:00
Treehugger Robot
acc96efcfa Merge "Fix deadlock issue." am: 6619bac824 am: cadcd9c225
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1918077

Change-Id: I1a1c9b2d437ea87c4eeecbd9ac5f2c1357cfcd17
2022-01-04 17:49:56 +00:00
Treehugger Robot
6619bac824 Merge "Fix deadlock issue." 2022-01-04 17:08:52 +00:00
Lee Shombert
0cece3898b Prepare PropertyInvalidatedCache for SystemApi
Bug: 152453213
Tag: #refactor

This commit prepares PropertyInvalidatedCache to function as a system
api.  Specifically, the methods recompute() and bypass() which may be
overridden by clients are now public (instead of protected).  This
forces an update to all existing clients, to accommodate the change in
method visibility.

Two small changes have been made as cleanup:

 1. The awkwardly named debugCompareQueryResults() is now
    resultEquals(), which is more or less consistent with how other
    equality tests are named in Android.  This name change affects two
    clients.

 2. PackageManager has changed to use resultEquals() instead of
    maybeCheckConsistency().  This provides a simpler and more
    consistent use of the APIs.  maybeCheckConsistency() has been made
    private.

Test: atest PropertyInvalidatedCacheTests

Change-Id: I4110f8e887a4fd8c784141e8892557a9d1b80a94
2022-01-04 08:13:59 -08:00
jiayongqiang
d2280b8107 Fix deadlock issue.
It might cause deadlock sometimes:

The locking order of setEventsMask is:
    registerDisplayListener -> <DMG.mLock> -> setEventsMask -> <class lock>;

The Locking order of handleMessage is:
    Looper.loop -> Looper.loopOnce -> Handler.dispatchMessage -> handleMessage -> <class lock>;

Therefore, when the registerDisplayListener is called by client,
the DisplayListenerDelegate.handleMessage also called by DMS's callback,
at this time, if the method with DMG.mLock is called in handleMessage(),
it will lead to deadlock.

Test: (For example)
Thread A:
DisplayListenerDelegate.handleMessage() -> <class lock>
DisplayListener.onDisplayChanged() -> DMG.getCompatibleDisplay() ->
DMG.getDisplayInfo() -> <DMS.mLock>

Thead B:
DMG.registerDisplayListener() -> <DMS.mLock> -> DisplayListenerDelegate.setEventsMask() -> <class lock>

Signed-off-by: jiayongqiang <jiayongqiang@xiaomi.com>
Change-Id: Ie1a8728339c16fa8f4c4f5c758821c836fa1c96b
2022-01-04 18:29:45 +08:00
Michael Groover
a052fa6c8e Mark SystemSensorManager receiver as not exported
Bug: 161145287
Test: Build
Change-Id: If84dbc83fd13bf531e3d5c36bbaf3bc9c90da286
2021-12-30 01:09:07 +00:00
Lajos Molnar
959bb219da camera: allow GPU usage for isSurfaceForHwVideoEncoder
Modern video encoders rely on GPU for some of their preprocessing, so video
encoder buffers will be allocated with GPU usage set.

Bug: 193772557
Bug: 204504047
Change-Id: I84b60fdd3f9d511b39185c1a31799f2b1514e166
2021-12-23 09:41:19 -08:00
Arthur Ishiguro
d7d39a881b Improve ContextHubClient.java documentations
- Remove IllegalExceptions @throws for getId()
- Add <p> markers

Bug: 210923723
Test: None, doc only
Change-Id: Ie7804429b7f183754e7f8a85782e91f123c0f054
2021-12-22 01:11:46 +00:00
TreeHugger Robot
66eca70ab0 Merge "Change close guard logged messages" 2021-12-21 15:55:19 +00:00
Arthur Hung
2c84c29d3d Merge "Prevent false touch when folding device (2/2)" 2021-12-21 15:07:41 +00:00
Ioannis Ilkos
0bde67ab00 Change close guard logged messages
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
2021-12-21 11:46:10 +00:00
Arthur Hung
f885746db7 Prevent false touch when folding device (2/2)
This CL will add new api to cancel current touch when fold transition
started.

Bug: 203549969
Test: manual
Change-Id: Id03fbeb05014dcb9f99901c36db1a88cbe110880
2021-12-16 08:39:46 +00:00
Arthur Ishiguro
b04c63a1bc Fix typo on NanoAppState documentation
Bug: 194287786
Test: None
Change-Id: I13c8d06cdae4fd2693d9378fbbbdb05cdc38f218
2021-12-15 23:16:12 +00:00
Arthur Ishiguro
84c6d95084 Merge "Expose NanoAppRpcService from nanoapps" 2021-12-15 22:00:26 +00:00
Bernardo Rufino
3d10fb4b83 Merge "Migrate unsafe parcel APIs in framework-minus-apex" 2021-12-15 19:15:58 +00:00
Bernardo Rufino
90bb3709dc 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
Test: TH passes
Change-Id: I11a27b9bdab7959ee86e90aa1e1cbebd7aaf883c
2021-12-15 18:21:38 +00:00
Arthur Ishiguro
3fcc716bdc Expose NanoAppRpcService from nanoapps
Bug: 194287786
Test: Add fake RPC service and verify through logs
Change-Id: I563c6e97d300957179a380b25756ac11f66ab171
2021-12-15 02:19:42 +00:00
Rucha Katakwar
0b77c138ad Merge "Camera: Torch strength control API." 2021-12-14 17:33:33 +00:00
John Reck
20d7333d6d Merge "Reduce SurfaceControl feature gap to NDK API" 2021-12-13 20:00:50 +00:00
Rucha Katakwar
748da4343c Camera: Torch strength control API.
This change contains below new public APIs:
1. Change the torch strength level.
2. Get the torch brightness level.
3. Callback when torch strength level is changed.

Bug: 200174275

Test: atest -c cts/tests/camera on aosp_cf_x86_64_phone-userdebug
Change-Id: I8b2d3a7dd9114986d3171832744a3dd6db092a48
2021-12-10 21:17:14 -08:00
Christine Franks
c74e2e0ee7 Merge "Remote input interfaces, events, and injection" 2021-12-10 23:38:02 +00:00
TreeHugger Robot
b1379e7dfa Merge "Camera: Update JPEG size override condition for MPC13" into sc-v2-dev am: 1efdec0980 am: db5e01949e
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/16409018

Change-Id: I92bb6aa1441c452c30a7800cdb7e509d3a28c361
2021-12-10 21:39:58 +00:00
TreeHugger Robot
db5e01949e Merge "Camera: Update JPEG size override condition for MPC13" into sc-v2-dev am: 1efdec0980
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/16409018

Change-Id: I7e55ac5aa88aee72792fdb91cc78a90e49687c49
2021-12-10 21:15:22 +00:00
TreeHugger Robot
1efdec0980 Merge "Camera: Update JPEG size override condition for MPC13" into sc-v2-dev 2021-12-10 21:08:00 +00:00