Commit Graph

3439 Commits

Author SHA1 Message Date
Ivailo Karamanolev
1a6fad470a Merge changes from topics "add-lights-manager", "lights-aidl-hal"
* changes:
  Add LightsManager implementation to LightsService
  Add Lights AIDL HAL support to LightsService
  Rename Light to LogicalLight to avoid namespace conflicts when adding AIDL HAL lights support.
2020-01-23 16:05:07 +00:00
TreeHugger Robot
2a8fae9828 Merge changes from topic "voiceinteraction-model-enrollment"
* changes:
  async enrollment support AlwaysOnHotwordDetector
  add KeyphraseModelManager
2020-01-23 02:46:50 +00:00
Nicholas Ambur
f771e6c9f6 async enrollment support AlwaysOnHotwordDetector
Added ability for AlwaysOnHotwordDetector to support async enrollment
performed outside of support detected through KeyphraseEnrollmentInfo.

Bug: 147159435
Test: tested enrollment and availability is updated when enrolling
outside of KeyphraseEnrollmentInfo

Change-Id: Ia5d71e90c062ac100d4c6df760acf0d41920853e
2020-01-22 16:40:18 -08:00
Nicholas Ambur
ef84fc4843 add KeyphraseModelManager
Exposes a set of @SystemApi's allowing the active VoiceInteractionService
to enroll voice models.

Bug: 147159435
Test: manual tested enrollment and unenrollment via bundled
hotwordenrollment application and test app.

Change-Id: I94ef3550df236486401a0a6f9de9d874b9bf9b46
2020-01-22 16:40:13 -08:00
Ivailo Karamanolev
090d02ca84 Add LightsManager implementation to LightsService
Includes backend code to support LightsManager binder calls and route
them to the HALs.

Bug: 144979010
Bug: 144978691
Bug: 142715294
Fix: 142230898
Test: atest LightsManagerTest
Test: atest LightsServiceTest
Change-Id: I2db7f2caa432cd1e2389ea5ca6544200ada18675
Exempt-From-Owner-Approval: Reviewed in OOO OWNERS's stead.
2020-01-22 23:49:02 +01:00
Howard Yen
ba5a535640 Merge changes from topic "usb_gadget_reset"
* changes:
  Add svc usb resetUsbGadget method
  Support USB Gadget V1.1 HAL
2020-01-22 20:56:44 +00:00
TreeHugger Robot
5561857cc7 Merge "Revert "Adds a new ACCESS_CONTEXT_HUB permission"" 2020-01-22 07:59:31 +00:00
Jaewan Kim
21de9eebb5 Revert "Adds a new ACCESS_CONTEXT_HUB permission"
This reverts commit 4042897855.

Bug: 135951924
Reason for revert:
   Breaks PermissionPolicyTest.platformPermissionPolicyIsUnaltered
   in CtsPermission2TestCases

Change-Id: Ie48fca6a0c54e281aae0db6cd9652b49cebbaa5c
2020-01-22 06:23:44 +00:00
TreeHugger Robot
c455927ff4 Merge changes from topic "OfflineReproc-impl"
* changes:
  Camera: Add API for surface offline mode queries
  Camera: Add initial offline camera session implementation
2020-01-22 04:01:01 +00:00
Arthur Ishiguro
e5b3e8e8f0 Merge "Adds a new ACCESS_CONTEXT_HUB permission" 2020-01-22 02:23:44 +00:00
Arthur Ishiguro
4042897855 Adds a new ACCESS_CONTEXT_HUB permission
Since not all Context Hub applications are location-related, the
use of the LOCATION_HARDWARE permission to control access to the Context Hub
System APIs can be misleading. Create a new permission to access it, and
adds the logic to enforce the permission.

Also clarifies usage of PendingIntent ContextHubClient.

Bug: 135951924
Test: Compile and flash
Change-Id: I5f22db7e57ef4a6c3718acb38c4f313d6a04839f
2020-01-21 14:39:51 -08:00
TreeHugger Robot
06e6d824f1 Merge "Add methods to retrieve the native CameraMetadata pointer." 2020-01-21 22:02:48 +00:00
Emilian Peev
731009ed15 Camera: Add API for surface offline mode queries
Camera clients of devices that support offline processing
capability must be able to check for offline support of
individual surfaces registered within a give capture session.

Bug: 135142453
Test: Camera CTS
Change-Id: Ia5b6ec31a3540925b92761c9ac1f2407214cbcf7
2020-01-21 12:59:56 -08:00
Jiawen Chen
5419ea37da Add methods to retrieve the native CameraMetadata pointer.
Test: atest android.hardware.camera2.cts.CameraManagerTest#testCameraCharacteristicsNdkFromSdk android.hardware.camera2.cts.CaptureResultTest#testCameraCaptureResultAllKeys
Bug: 80513080

Change-Id: I296db8425b562e09843159dfab3afa0960b4854f
2020-01-21 14:26:32 -05:00
Automerger Merge Worker
310f576b7f Merge "Add Framework APIs for Identity Credential." am: 2fb5112a35 am: 70485380f7 am: 6079e88fae
Change-Id: Iec2c6c1ec28b5697b8d2b444081a3240bea2af9e
2020-01-21 15:12:56 +00:00
David Zeuthen
70485380f7 Merge "Add Framework APIs for Identity Credential."
am: 2fb5112a35

Change-Id: Ifb511b43fd180980badef43b7ea3009e3a9ba00b
2020-01-21 06:45:12 -08:00
David Zeuthen
045b6de975 Add Framework APIs for Identity Credential.
The Identity Credential APIs provides an interface to a secure store
for user identity documents.  These APIs are deliberately fairly
general and abstract.  To the extent possible, specification of the
message formats and semantics of communication with credential
verification devices and Issuing Authorities (IAs) is out of scope for
these APIs.

The Identity Credential APIs rely on user authentication to protect
data elements in credentials which is implemented through
auth-tokens. This CL contains changes to CryptoObject to allow this.

Bug: 111446262
Test: CtsIdentityTestCases
Change-Id: I48f21a561b762d86c9ca8d229962782572412f47
2020-01-20 15:56:57 -05:00
Emilian Peev
301abd4940 Camera: Add initial offline camera session implementation
Offline camera sessions allow clients to migrate still
ongoing capture requests to offline processing mode.
When offline mode is enabled, the initial active capture
session along with the open camera device can be closed
and further re-used while offline processing is still
ongoing.
Split and re-use parts of camera device implementation
along with its current state for offline mode.

Bug: 135142453
Test: Camera CTS
Change-Id: I5eb4055e2af4265ece0fb7271bdf5f4cf2d5aaf3
2020-01-20 10:32:20 -08:00
Galia Peycheva
a85b3d56a3 Merge "Add a TestApi to DM to get the last requested MPP" 2020-01-20 08:05:39 +00:00
Galia Peycheva
35f900a4d0 Add a TestApi to DM to get the last requested MPP
This CL exposes DisplayManager.getRequestedMinimalPostProcessing
for testing purposes. The call is propagated to
LogicalDisplay.getRequestedMinimalPostProcessingLocked().

Bug: 139369866

Test: m, flash, atest
CtsWindowManagerDeviceTestCases:MinimalPostProcessingTests

Change-Id: I7736d6e7a5c97d663111d10efa66d6d38a7e70bd
2020-01-17 20:23:01 +01:00
Howard Yen
db8f11654b Support USB Gadget V1.1 HAL
USB Gadget V1.1 HAL supports USB port reset interface.

Bug: 138702846
Test: build pass, function works
Change-Id: Ia4b3b85bb0ce74307599832f849d3e23c2546187
2020-01-17 22:23:12 +08:00
Andrii Kulian
2b3b20c388 Merge changes from topic "app_config_compat"
* changes:
  Update resource config for default display
  Override process config to match activity config
  Set parent for WindowProcessController
2020-01-17 04:56:41 +00:00
TreeHugger Robot
ba3882446c Merge "Camera: Add new UNDEFINED pose reference enum" 2020-01-16 21:49:19 +00:00
Ytai Ben-Tsvi
2e8f78b322 Improve exception handling in SoundTrigger
This unified the exception handling of SoundTrigger and
SoundTriggerModule and adds support for some ServiceSepcificExceptions
that may occur.

Change-Id: I018c7b249058758f0f3b5af34ee06a2396ecb6a7
Bug: 147435580
2020-01-15 13:10:33 -08:00
Andrii Kulian
946e8df660 Update resource config for default display
When a launched application doesn't occupy the entire screen space,
there is a mismatch between the configuration of the process and the
configuration of activities. This leads to compatibility issues with
apps that don't expect this, read display metrics from Application
resources and try to apply them in activities.

The platform may apply a compatibility mode, in which the process
configuration will match the config of the top running activity. This
means that the process configuration may change and runtime and
result in display adjustments that are different from the default
values. This CL propagates resource configuration updates even for
default display to make sure that the config changes are reflected
for non-activity contexts.

Test: CtsWindowManagerDeviceTestCases:AppConfigurationTests
Change-Id: I91cadc83a82a3be8c8dee810bbd1aa97cbe4e97f
2020-01-15 12:22:46 -08:00
TreeHugger Robot
d5dc1844bb Merge "fix parceling issue with KeyphraseSoundModel" 2020-01-15 05:36:57 +00:00
TreeHugger Robot
e2b62e4f12 Merge changes I8cfea8ab,I349611e3
* changes:
  Recover from HAL death in sound trigger
  Lint cleanup
2020-01-15 03:49:48 +00:00
Nicholas Ambur
43970b5124 fix parceling issue with KeyphraseSoundModel
Bug: 147646806
Test: Tested enrollment and unenrollment via bundled hotword enrollment
application.

Change-Id: I0a78d831e0949d4cf1ed97a1cd6cdaea70d8399a
2020-01-14 18:54:26 -08:00
Curtis Belmonte
e0e5852108 Merge "Add auth type to BiometricPrompt.AuthenticationResult" 2020-01-15 00:44:26 +00:00
Ytai Ben-Tsvi
c2327e78fd Recover from HAL death in sound trigger
Added some recovery code for the case of a dead driver.
Due to the sound trigger HAL process being tied to the audio server
via init.rc, this would also offer recovery from audio server death
as a by-product.

Bug: 146852437
Change-Id: I8cfea8ab108d482592c8094e8093066973f43288
2020-01-14 15:22:18 -08:00
Shuzhen Wang
2071f2e977 Camera: Add new UNDEFINED pose reference enum
The newly added UNDEFINED pose reference is used for a camera device
that cannot accurately measure its pose rotation and translation.
One such example is a camera on a foldable phone.

Bug: 119325027
Test: Camera CTS, and test_multi_camera_alignment
Change-Id: I0da7638e2bce31886f9dbf33dd2f74800d8768f7
2020-01-14 14:15:52 -08:00
Curtis Belmonte
6601bc3403 Add auth type to BiometricPrompt.AuthenticationResult
Now that BiometricPrompt supports primary auth via device credential,
we want the high-level type of authentication used to be available to a
developer via the AuthenticationResult in onAuthenticationSucceeded.
Rather than include information about the strength of the biometric
sensor by reusing the existing Authenticators.Types constants, this
commit adds new integer constants that provide similar information but
at a lower level of granularity (device credential vs. biometric).

Test: atest com.android.server.biometrics
Test: atest com.android.systemui.biometrics
Test: Manually inspect new AuthenticationResult object on Pixel 3/4

Bug: 80525177
Bug: 141025588

Change-Id: Ic09ffdff995afe374f11721e6e777632de9ae867
2020-01-14 12:33:19 -08:00
Nicholas Ambur
9e3ec9af07 Merge "add version entry to soundtrigger model database" 2020-01-14 00:47:20 +00:00
TreeHugger Robot
bea889368f Merge "Camera: Improve timestamping docs" 2020-01-14 00:33:23 +00:00
Nicholas Ambur
d3ec82fbc4 add version entry to soundtrigger model database
Bug:147159435
Test: manual hotword trigger with upgraded database
&& dumpsys voiceinteraction

Change-Id: I45497c1159fe879e1de119a18aac8f7ecc2b0686
2020-01-13 12:23:56 -08:00
Eino-Ville Talvala
4607917f5f Merge "Camera: Deprecate various older createCaptureSession variants" 2020-01-13 19:28:22 +00:00
Eino-Ville Talvala
e57616ff52 Camera: Deprecate various older createCaptureSession variants
Move all the documentation to the most flexible option, and deprecate
the older variants.

Test: m offline-sdk-docs, full build
Bug: 130304741
Change-Id: I9775e474657b87157ae49c22b2156f6cabe2088b
2020-01-10 19:26:44 -08:00
Nicholas Ambur
7092a56116 add audioCapabilities to SoundTrigger properties
Bug: 146363190
Test: atest SoundTriggerMiddlewareImplTest
&& GTS assist test suite

Change-Id: Ib8a3b809fa6738152d31499b5072a2e9d39ab0a0
2020-01-10 16:00:58 -08:00
Nicholas Ambur
bcc216f212 Merge "add supportedModelArch to SoundTrigger properties" 2020-01-10 17:09:00 +00:00
Nicholas Ambur
b2a5c29796 Merge "add parameter control to AlwaysOnHotwordDetector" 2020-01-10 17:08:00 +00:00
Nicholas Ambur
f94db1c822 add parameter control to AlwaysOnHotwordDetector
Per-model control to AlwaysOnHotwordDetector interface.
Models are selected by keyphrase and locale associated with the
AlwaysOnHotwordDetector instance.

Bug: 141929369
Test: tested manually with test app
Change-Id: Iffeb0954059fa030d8a4fefb934a3e665323be37
2020-01-09 18:18:47 -08:00
Eino-Ville Talvala
1ce3c167c5 Camera: Improve timestamping docs
Specifically, publicly commit to UNKNOWN being CLOCK_MONOTONIC, though
with loose accuracy guarantees.

Also document how to handle REALTIME timestamps for A/V sync purposes.

Test: Builds, docs-only change

Change-Id: I24b5a69bf95508fe1462ca363843c4bfccf14889
2020-01-09 15:11:31 -08:00
Arthur Hung
c9f383bbed Support dynamic input mapping
In addition to static input mapping with IDC or config files that
was added in Q, there is a need to be able to change the mapping
at runtime.

This's different from focus being present to handle lifecycle/app
switching/etc, the rest of the system will need to be adapted to
work with no focus

- Provide an API that could add/update the associations.
- Provide an API that could remove the runtime associations.

Bug: 136080860
Test: manual
Change-Id: Ib80eea9a9c4b4326b0d48a9f496fa550dab2230e
2020-01-09 18:01:22 +08:00
Automerger Merge Worker
6da6e4f73f Merge "USB: [Tethering mainline] Expose @hide APIs to @SystemApi" am: d997a3571b am: 62a34ebc11 am: 658a0373a2
Change-Id: Ibc6e61e774c21e2e5c9bc1e7cb0e7fb46ae972fd
2020-01-09 04:39:32 +00:00
Automerger Merge Worker
658a0373a2 Merge "USB: [Tethering mainline] Expose @hide APIs to @SystemApi" am: d997a3571b am: 62a34ebc11
Change-Id: I9578c3d1b30c1c747b88a146a691f3280f448039
2020-01-09 04:33:30 +00:00
James Wei
7d66bd9b54 USB: [Tethering mainline] Expose @hide APIs to @SystemApi
Bug: 142372304
Test: Manual test: Enable USB tethering
Test: atest UsbTests
Test: atest UsbManagerTests
Change-Id: Ib284b0a72b06ff45b4d3b55a8d48c20f51284a20
2020-01-09 10:21:34 +08:00
Nicholas Ambur
38027cd860 add supportedModelArch to SoundTrigger properties
Bug: 142414689
Test: atest SoundTriggerMiddlewareImplTest
&& GTS assist test suite

Change-Id: I201a8ab919b0a27fa1ed2fd7804c78edccefc647
2020-01-08 14:49:49 -08:00
Automerger Merge Worker
59d58f5cae Merge "Use new UnsupportedAppUsage annotation." am: 9395887931 am: 8081ee1b35
Change-Id: I330594303664e66571a460fdb1a5ab6cb8e5e273
2020-01-08 17:14:42 +00:00
Artur Satayev
33f9217695 Use new UnsupportedAppUsage annotation.
Existing annotations in libcore/ and frameworks/ will deleted after the migration. This also means that any java library that compiles @UnsupportedAppUsage requires a direct dependency on "unsupportedappusage" java_library.

Bug: 145132366
Test: m && diff unsupportedappusage_index.csv
Change-Id: I0c336de56bc4a041dc97ff9b7927f62f0b44b457
Merged-In: I0c336de56bc4a041dc97ff9b7927f62f0b44b457
2020-01-08 14:04:40 +00:00
Ytai Ben-tsvi
d63953379b Merge "Doc fix" 2020-01-07 22:17:44 +00:00