Commit Graph

3314 Commits

Author SHA1 Message Date
Jayant Chowdhary
7f9a4c9e8c Merge changes from topic "system-camera-cts"
* changes:
  Allow com.android.shell to get RECORD_AUDIO permissions.
  CameraManager: Add @TestApi method getCameraIdListNoLazy().
2019-09-24 20:05:18 +00:00
Jayant Chowdhary
556815d71c CameraManager: Add @TestApi method getCameraIdListNoLazy().
Add getCameraIdListNoLazy() - a test method which necessarily makes a
call to cameraserver in order to get an updated list of camera ids. This
is needed since camera cts tests use SYSTEM_CAMERA permissions in a way
which are not permitted to happen in real world scenarios : processes
cannot gain and lose SYSTEM_CAMERA permissions for permission checking
purposes (through UiAutomation adopt(drop)ShellPermissionIdentity(). In
that case cameraserver doesn't send callback to the client app informing
it that system cameras aren't available.

Bug: 138130599

Test: camera CTS

Change-Id: Ic00951828ea289a1a04b1d655506ef6474336b91
Signed-off-by: Jayant Chowdhary <jchowdhary@google.com>
2019-09-18 12:44:33 -07:00
Nicholas Ambur
f2c31a51ee Revert "change KeyphraseEnrollmentInfo to store services"
This reverts commit 07ba2b7f83.

This change is being reverted because it needs to be paired with an AGSA
prebuilt APK update.

Test: Confirm prebuilt AGSA apk does not crash on enrollment
Bug: 141155032
Change-Id: Ie504f125966d38a11c65ae96f39e9a5aa7ce43ed
2019-09-18 08:36:27 -07:00
TreeHugger Robot
20ecb9aeda Merge "Camera: audio restriction API doc update" 2019-09-16 21:46:48 +00:00
Nicholas Ambur
4e76b76716 Merge "change KeyphraseEnrollmentInfo to store services" 2019-09-16 19:02:02 +00:00
Evan Severson
7fc19171e3 Merge "Usb launch preference denial able to be remembered" 2019-09-16 17:37:40 +00:00
Nicholas Ambur
07ba2b7f83 change KeyphraseEnrollmentInfo to store services
Current hotword enrollment is done through a transparent activity which
when triggered causes a breif interuption on the UI. Because there is no
actual UI component to this activity, it is being transitioned from an
activity to a service.

applications supporting MANAGE_VOICE_KEYPHRASES are moved from ativity
to service based to allow for enrollment which does not effect the UI

Bug: 139954183
Test: confirmed enrollment and unenrollment intents can start the
registered enrollment service.

Change-Id: I1e2d80e08efaf47a5c1c8760e2979143df436a93
2019-09-16 16:54:43 +00:00
Yin-Chia Yeh
54314f21f0 Merge "Camera: fix NPE in buffer error callback" into qt-qpr1-dev am: d0a1ab93d4
am: e0630bca2d

Change-Id: Id0b3d0ba82579fe835b184561a8580d77fce94ba
2019-09-14 01:14:03 -07:00
Yin-Chia Yeh
e0630bca2d Merge "Camera: fix NPE in buffer error callback" into qt-qpr1-dev
am: d0a1ab93d4

Change-Id: I6b2835b1073df0aeb69e28a1c3aa571caa32b149
2019-09-14 01:07:08 -07:00
Evan Severson
d9f045ebac Usb launch preference denial able to be remembered
When a device is connected the user might be prompted with
a dialog to launch an application. This change creates the
api that the system UI will use to give the user a
"deny [for this device+package] and remember" option.

Test: Manual:
      Edit usb_device_manager.xml and observe correct behavior
      Call new methods and observe correct changes in xml file
Bug: 136496922

Change-Id: I20e377d601ec11b8d42c79e4c726b9a4cb68c8b0
2019-09-14 03:46:30 +00:00
TreeHugger Robot
fcedf73656 Merge "Camera: Fix doc parameter description typo" 2019-09-14 01:08:31 +00:00
TreeHugger Robot
06f794842d Merge "Camera: Update doc for stale queued buffer in input surface" 2019-09-13 23:45:28 +00:00
Emilian Peev
ca57d30ad1 Camera: Fix doc parameter description typo
The 'CaptureRequest.Builder.setPhysicalCameraKey'
return value and parameter description contain
a typo that must be corrected.

Bug: 140915387
Test: make -j42 docs,
manual check of generated docs

Change-Id: I6f17df1917a7381c4119b9fcff3c5b8b18c5faa6
2019-09-13 15:58:43 -07:00
Yin-Chia Yeh
cd6c54ac92 Camera: audio restriction API doc update
Some more cleanup.

Test: make docs
Bug: 135676184
Change-Id: I133fb113f87a0cac6587214e6922d38f36607552
2019-09-13 13:40:45 -07:00
Madhava Srinivasan
32d22286e2 Merge "Honor HDMI_CONTROL_ENABLED setting in AudioService" am: 4efb0c510d am: a40f432ac6 am: 0e7175db88
am: 54a545f1e3

Change-Id: I84fac437a1adf97053e4bbfb7d45178b0487332f
2019-09-13 11:00:21 -07:00
Madhava Srinivasan
54a545f1e3 Merge "Honor HDMI_CONTROL_ENABLED setting in AudioService" am: 4efb0c510d am: a40f432ac6
am: 0e7175db88

Change-Id: I3f7c5ec073e82dd323e655bc886a6958a6db0f61
2019-09-13 10:51:01 -07:00
Madhava Srinivasan
0e7175db88 Merge "Honor HDMI_CONTROL_ENABLED setting in AudioService" am: 4efb0c510d
am: a40f432ac6

Change-Id: Ia4c92888f5ddc2e01a8b9025bdec0b00afb8c539
2019-09-13 10:38:05 -07:00
Madhava Srinivasan
a40f432ac6 Merge "Honor HDMI_CONTROL_ENABLED setting in AudioService"
am: 4efb0c510d

Change-Id: Ic60d7d5bf75288f9f6cdf02d414bf69dbfe74159
2019-09-13 10:24:22 -07:00
Madhava Srinivasan
154e0193ce Honor HDMI_CONTROL_ENABLED setting in AudioService
This change updates how AudioService is updated of changes to Hdmi Cec
status (enable/disable) and availablity.

Bug: 138956107
Bug: 138373017
Test: Android TV STB: make; flashall;Volume -/+; HDMI control enable/disable.
Change-Id: Iaf83a45206be076858e13d113ba772ed5c59ef60
Merged-In: Iaf83a45206be076858e13d113ba772ed5c59ef60
2019-09-12 22:14:59 +00:00
Shuzhen Wang
4b8363a8ba Camera: Update doc for stale queued buffer in input surface
In case a reprocessable capture session is re-created, any pending
queued buffers in the input surface will be flushed. This makes sure
newly created reprocessable capture session won't be stuck waiting for
stale buffers from previous session.

Test: Read docs
Bug: 138729150
Change-Id: Ia14221f31a6d4f6ebf35f630036ece66de1d0874
2019-09-10 16:52:06 -07:00
Xin Li
d57e959e71 Merge qt-r1-dev-plus-aosp-without-vendor (5817612) into stage-aosp-master
Bug: 135460123
Change-Id: I65906d82b14125c0893d5cde0cfebb73bf9e38ab
Merged-In: I1f2564837c33cd4c6c3db6aac3cbaf8c09707da9
2019-09-10 11:16:29 -07:00
Yin-Chia Yeh
6262db5aa5 Camera: update camera audio restriction API
Add dedicated get API per API review feedback.

Test: updated CTS tests
Bug: 140524714
Change-Id: I83ac09da76cc0868c7e993abd6a8c846912b6199
2019-09-09 15:37:04 -07:00
Yin-Chia Yeh
3b93a85b6a Camera: fix NPE in buffer error callback
Check if the error stream has been removed first.
Also move some code in submitCaptureRequest so that access to
mConfiguredOutputs is within scope of mInterfaceLock, which
matches all other places accessing mConfiguredOutputs in the file.

Test: Camera CTS
Bug: 140374093, 140527066
Change-Id: I84921eb3a555f67a006548865f34502ab978e33b
2019-09-09 14:59:59 -07:00
TreeHugger Robot
d8c549a0e9 Merge "Add ability to get soundtrigger props from dsp" 2019-09-04 23:59:05 +00:00
Long Ling
a1b4326b06 [DO NOT MERGE] Move device config high_refresh_rate_blacklist to display_manager
am: 5a570b3898

Change-Id: I4cc0818ab0f09efb027455a03506fff90ed46de3
2019-09-04 12:27:02 -07:00
Long Ling
1961cf1cdc Move device config key high_refresh_rate_blacklist to display_manager
high_refresh_rate_blacklist belongs to smooth display feature. Move the
key from namespace window_manager to display_manager.

Bug: 139138964
Test: atest WmTests:HighRefreshRateBlacklistTest
Test: Manual adb shell device_config/dumpsys window
Change-Id: I3ae8ecce80ef97c4683a1c18ad81dc78456e9d57
2019-09-03 17:02:11 -07:00
Long Ling
5a570b3898 [DO NOT MERGE] Move device config high_refresh_rate_blacklist to display_manager
high_refresh_rate_blacklist belongs to smooth display feature. Move the
key from namespace window_manager to display_manager.

Bug: 139138964
Test: atest WmTests:HighRefreshRateBlacklistTest
Test: Manual adb shell device_config/dumpsys window
Change-Id: I3ae8ecce80ef97c4683a1c18ad81dc78456e9d57
2019-09-03 16:24:42 -07:00
Long Ling
bb2782cc38 Merge "DMD: Support 90hz only in the refresh rate zone" into qt-r1-dev am: d44f2edc08 am: 1f4f57eab4
am: f024c2ed38

Change-Id: Icba3843e8633902320d9ca81a71e90280dd114f9
2019-09-03 14:58:52 -07:00
Long Ling
736b3b278c Merge "DMD: Support 90hz only in the refresh rate zone" into qt-r1-dev
am: d44f2edc08

Change-Id: Id684830b35b90017be0d5e9fb7c3fe348ffc200f
2019-09-03 14:41:16 -07:00
Long Ling
f024c2ed38 Merge "DMD: Support 90hz only in the refresh rate zone" into qt-r1-dev am: d44f2edc08
am: 1f4f57eab4

Change-Id: I7324013fadecc41a956a0b6f109b8aee9dd3a374
2019-09-03 14:41:12 -07:00
Evan Severson
4e493c4faf Merge "Implement persistent permissions for Usb devices" 2019-09-03 16:10:56 +00:00
TreeHugger Robot
09809a3d7b Merge "Camera: Improve doc for postRawSensitivityBoost" 2019-09-01 04:40:38 +00:00
Long Ling
1f4f57eab4 Merge "DMD: Support 90hz only in the refresh rate zone" into qt-r1-dev
am: d44f2edc08

Change-Id: Iaa8a5aca0e16a97a1cd1de529f35a8eeb971cf8d
2019-08-30 16:50:42 -07:00
Yin-Chia Yeh
3eb79d6357 Camera: camera service implementation of camera audio restriction API
Changed the binder call return value to the resulting
audio restriction mode.
Also added audio restriction API support for legacy shim
path.

Test: new CTS tests
Bug: 135676184
Change-Id: I412e8f53705f2401995ff828bfdc9a8598dc305a
2019-08-30 14:44:56 -07:00
Yin-Chia Yeh
51d8516b7a Camera: add camera audio restriction API
Test: new CTS tests
Bug: 135676184
Change-Id: I4f28d28972b9ced0fee0afe996ef1c4f68d0d2c9
2019-08-30 14:44:46 -07:00
Evan Severson
7b78bbd0fa Implement persistent permissions for Usb devices
Previously a package could only get automatically granted USB
permission for a given device if it was the default app to launch
when the device is connected. This means only one package can
be granted automatically and it must be started on connection.

This change introduces a new usb permission mechanism which is meant
to separate the auto launch from usb permission so that multiple
packages can have permission without prompting the user.
The temporary usb permissions still work.

Test: edit usb_permissions.xml on device to allow, reboot,
      connect usb headphones, deny launch dialog, open test app,
      assert usb permission already granted.
Test: Check complement behavior to previous test, assert permission
      not granted by default if not in usb_device_manager.xml or
      explicitly denied in usb_device_manager.xml.
Bug: 136496922
Change-Id: I005d7470f1e6642d683c953a914f65f16ff7e1bb
2019-08-30 12:45:44 -07:00
Long Ling
73936631d5 DMD: Support 90hz only in the refresh rate zone
Also allow DeviceConfig to change the zone behavior
to 60 Hz only.

Change BrightObserver priority to be the lowest so application
request won't be overriden by BrightnessObserver

Bug: 139487676
Change-Id: I959550350c1ea72f764984226350ebc6e7de591c
2019-08-30 10:19:47 -07:00
Nicholas Ambur
1aa4b4b779 Add ability to get soundtrigger props from dsp
exposes sound trigger module properties to privileged
system apps with MANAGE_SOUND_TRIGGER permission

Bug: 139071862
Test: GTS test confirmed API accessible and providing valid data
Change-Id: Iec7ba6fc59912f44341fbe8d7f99193b9ead52f0
2019-08-30 10:10:18 -07:00
Aurimas Liutikas
488d37b2d0 Merge "Add missing nullability annotations." into stage-aosp-master am: 85c0a5a2be am: ed5beec21b
am: de0ebb082e

Change-Id: I60c55b6706e8d43121e8b2c7a35efff38668f66b
2019-08-30 08:54:38 -07:00
Aurimas Liutikas
de0ebb082e Merge "Add missing nullability annotations." into stage-aosp-master am: 85c0a5a2be
am: ed5beec21b

Change-Id: I202951d51820be47b9195734601830553215bdd7
2019-08-30 08:43:01 -07:00
Aurimas Liutikas
ed5beec21b Merge "Add missing nullability annotations." into stage-aosp-master
am: 85c0a5a2be

Change-Id: Ic9ea2b9840fbb678bbb6ab77038415581feba918
2019-08-30 08:35:52 -07:00
Aurimas Liutikas
4d1699da48 Add missing nullability annotations.
To prepare for enabling MissingNullability Metalava check this CL
works on adding missing nullability issues that metalava flags if
we tell it to flag new things since API 29.

This is not a complete CL, mostly addresses public api and
toString/equals for @SystemApi

Exempt-From-Owner-Approval: Large scale nullability clean up
Bug: 124515653
Test: make -j checkapi
Change-Id: I109260842cfc25f06e40694997fcbb4afa02c867
2019-08-29 17:15:44 -07:00
Aurimas Liutikas
00be951a08 Add missing nullability annotations.
To prepare for enabling MissingNullability Metalava check this CL
works on adding missing nullability issues that metalava flags if
we tell it to flag new things since API 29.

This is not a complete CL, mostly addresses public api and
toString/equals for @SystemApi

Exempt-From-Owner-Approval: Large scale nullability clean up
Bug: 124515653
Test: make -j checkapi
Merged-In: I109260842cfc25f06e40694997fcbb4afa02c867
Change-Id: I109260842cfc25f06e40694997fcbb4afa02c867
2019-08-30 00:14:44 +00:00
TreeHugger Robot
37ec9aa590 Merge "Give the legacy camera looper thread a name." 2019-08-27 19:11:31 +00:00
Eino-Ville Talvala
52cfe444f7 Give the legacy camera looper thread a name.
Bug: 133298222
Test: Builds
Change-Id: I6b2050b834fb5975fa1f58c22dbe647a0d9aa94f
2019-08-26 16:42:46 -07:00
Long Ling
ba9b991d1e Merge "DeviceConfig: Add Name space and keys for Display Manager" 2019-08-26 21:59:22 +00:00
Long Ling
7227ff19aa DO NOT MERGE DeviceConfig: Add Name space and keys for Display Manager
am: dde6248065

Change-Id: Ic452fed2390fab0f69799a192ce86402b4c0cb7e
2019-08-23 06:24:30 -07:00
Long Ling
dde6248065 DO NOT MERGE DeviceConfig: Add Name space and keys for Display Manager
Bug: 139138964
Change-Id: I077380583f0daf650b17832a6cec4919b41ac155
2019-08-23 13:00:53 +00:00
Neil Fuller
173720587d Merge "Switch from android.text.format.Time" 2019-08-22 12:20:18 +00:00
Long Ling
999a704b02 DO NOT MERGE Move device config key high_refresh_rate_blacklist to display_manager
am: 6f13f12213

Change-Id: I299e0eecf9d52e12ecf71b1f1b566637f4479e02
2019-08-21 12:55:19 -07:00