Commit Graph

1593 Commits

Author SHA1 Message Date
Neil Fuller
770f5ab2db Add a new permission in AOSP
This adds a new permission in AOSP, so it can be referenced by the Shell
command, which presubmit suggests has to be maintained in AOSP.

Bug: 159891384
Test: build only
Exempt-From-Owner-Approval: jsharkey@ approved but it appears to have reset...?
Change-Id: Ic7d403e20731e9d6bd82d5b2e2758cc61989cc59
2020-09-30 08:39:25 +00:00
Collin Fijalkovich
7ffd615b4c Merge "Allow privapp Traceur access to STATUS_BAR and DUMP" 2020-09-24 21:08:09 +00:00
Collin Fijalkovich
36d59fba49 Allow privapp Traceur access to STATUS_BAR and DUMP
Modifies the privapp allowlist to allow Traceur to grant Traceur the
STATUS_BAR permission, which is needed for quick settings tile functionality, and dump which is needed for the BUGREPORT_STARTED intent.

Bug: 166768816
Test: Built user and userdebug, exercised regular and long trace
functionality

Change-Id: I180527a9a1a30ef6a214b628f37affc69f9ae2f0
2020-09-24 17:45:53 +00:00
Ulyana Trafimovich
f08e8871d4 Merge "Drop dependency of android.test.mock -> android.test.base." 2020-09-23 14:54:16 +00:00
Ulya Trafimovich
c578ab0ada Drop dependency of android.test.mock -> android.test.base.
There should be no such dependency.

Test: lunch aosp_cf_x86_phone-userdebug && m
Bug: 169137403
Bug: 132357300
Change-Id: Iaa7414be66581c01c6acbf367dc165cd8af78615
2020-09-23 11:08:01 +01:00
paulhu
2cbae66fcb Add CONNECTIVITY_USE_RESTRICTED_NETWORKS permission to DownloadProvider
- DownloadManager will use the requestor app's default network to
open a connection. When the VPN app lists the DownloadProvider as
a disallowed application, this will fail with EPERM.
- This is because in R, the DownloadProvider lost its privileges
due to the removal of the CONNECTIVITY_INTERNAL permission. It's
removed without considering the corner case where the
DownloadProvider is excluded from using the VPN. It's the only
case where this makes a difference.
- Adding CONNECTIVITY_USE_RESTRICTED_NETWORKS will give
DownloadProvider the ability to use the VPN again in this case,
fixing the issue.

Bug: 165774987
Test: Build, flash rom and boot to home. Manully test that
      DownloadProvider can download file via VPN.
Change-Id: If8fa785568ace1f15f53daec67c06e1207d5dc9c
Merged-In: If8fa785568ace1f15f53daec67c06e1207d5dc9c
2020-09-18 08:24:12 +00:00
Xin Li
628590d7ec Merge Android R (rvc-dev-plus-aosp-without-vendor@6692709)
Bug: 166295507
Merged-In: I3d92a6de21a938f6b352ec26dc23420c0fe02b27
Change-Id: Ifdb80563ef042738778ebb8a7581a97c4e3d96e2
2020-08-31 21:21:38 -07:00
Treehugger Robot
4ec7604b48 Merge "Add KEYCODE_PROG_{BLUE,RED,GREEN,YELLOW} mappings to LKC equivalents" 2020-08-07 16:54:11 +00:00
Aman Gupta
7395b0a265 Add KEYCODE_PROG_{BLUE,RED,GREEN,YELLOW} mappings to LKC equivalents
My goal is to allow colored keys on HDMI-CEC and Bluetooth remotes to be used by an Android TV app.

The USB HID spec [1] and CEC spec [2] both define distinct codes for these keys.

The kernel converts both the HID [4] and CEC [5] codes to standard LKC codes [6]:

  #define KEY_RED		0x18e
  #define KEY_GREEN		0x18f
  #define KEY_YELLOW	0x190
  #define KEY_BLUE		0x191

Android also defines KEYCODE_PROG_ constants for these keys in KeyEvent.java [3]. This commit maps these LKC codes starting at 0x18e (i.e 398) to the existing KeyEvent equivalents.

[1] https://www.usb.org/sites/default/files/color_buttons_0.pdf
[2] https://github.com/floe/CEC/raw/master/extras/CEC_Specs.pdf
[3] https://github.com/aosp-mirror/platform_frameworks_base/blob/master/core/java/android/view/KeyEvent.java#L539-L550
[4] https://github.com/torvalds/linux/blob/master/drivers/hid/hid-input.c#L897-L900
[5] https://github.com/torvalds/linux/blob/master/drivers/media/rc/keymaps/rc-cec.c#L142-L145
[6] https://github.com/torvalds/linux/blob/master/include/uapi/linux/input-event-codes.h#L470-L473

Signed-off-by: Aman Gupta <aman@tmm1.net>
Change-Id: I26c63732c8533390de91460acec312fd27ad8866
2020-08-06 08:03:19 -07:00
Siarhei Vishniakou
21e6488ae7 Merge "Add KEYCODE_MEDIA_AUDIO_TRACK mapping to USB HID Usage consumer page (0x0c/0x173) "Alternate Audio Increment"" 2020-08-03 21:29:08 +00:00
Treehugger Robot
dab3aaa5c6 Merge "Add support for Razer Kishi game controller." 2020-08-01 12:29:58 +00:00
Chris Ye
d91a29ac36 Add support for Razer Kishi game controller.
Add Razer Raiju Kishi controller keyboard layout mapping.

Bug: 140958486
Test: Connect Razer Kishi controller and play game with it.
Change-Id: I6f94e212fe10f777f04ad9815468e2148d4252f5
Merged-In: I6f94e212fe10f777f04ad9815468e2148d4252f5
2020-08-01 04:38:14 +00:00
Chris Ye
b07e2f8093 Add support for Scuf Vantage game controller.
Add Scuf Vantage controller keyboard layout mapping.

Bug: 155223457
Test: ControllerTest App, Connect Scuf Vantage controller and play game with it.
Change-Id: I21d23dcbeb4ef24d212d4e386f6dbf8b1b89d9f6
Merged-In: I21d23dcbeb4ef24d212d4e386f6dbf8b1b89d9f6
2020-08-01 04:35:51 +00:00
Aman Gupta
e30b82490c Add KEYCODE_MEDIA_AUDIO_TRACK mapping to USB HID Usage consumer page (0x0c/0x173) "Alternate Audio Increment"
cc 20555cb645

Change-Id: I7ff8b71abd99e6024e874a0aac42e875720186f9
Signed-off-by: Aman Gupta <aman@tmm1.net>
2020-07-21 12:12:40 -07:00
Aman Gupta
7b48e40231 Add KEYCODE_WINDOW mapping to USB HID Usage consumer page (0x0c/0x67) "Picture-in-Picture Toggle"
cc https://www.usb.org/sites/default/files/ce_devices_0.pdf

Change-Id: Iac94535823fa0a97e1a926d28d6f7376c11b8bf0
Signed-off-by: Aman Gupta <aman@tmm1.net>
2020-07-21 12:12:40 -07:00
Aman Gupta
6c984953ea Add KEYCODE_CAPTIONS mapping to LKC KEY_SUBTITLE
From https://github.com/torvalds/linux/blob/master/include/uapi/linux/input-event-codes.h,
KEY_SUBTITLE is near the TV codes. Note that 0x172 == 370.

  #define KEY_CHANNEL		0x16b
  #define KEY_FAVORITES		0x16c
  #define KEY_EPG			0x16d
  #define KEY_PVR			0x16e	/* Media Select Home */
  #define KEY_MHP			0x16f
  #define KEY_LANGUAGE		0x170
  #define KEY_TITLE		0x171
  #define KEY_SUBTITLE		0x172
  #define KEY_ANGLE		0x173
  #define KEY_FULL_SCREEN		0x174	/* AC View Toggle */
  #define KEY_ZOOM		KEY_FULL_SCREEN

You can also see on https://www.kernel.org/doc/html/v4.9/media/uapi/rc/rc-tables.html it is listed in the "Movie play control" section:

  KEY_SUBTITLE	Allow changing the subtitle

Change-Id: I7690269cddd00b787a939f87ba651db38f1160ac
Signed-off-by: Aman Gupta <aman@tmm1.net>
2020-07-21 12:09:52 -07:00
Aman Gupta
48a06806f1 Add KEYCODE_LAST_CHANNEL mapping to LKC KEY_LAST
Change-Id: Idcf987c6e5541e29cac1b8a89263580bfcdc9636
Signed-off-by: Aman Gupta <aman@tmm1.net>
2020-07-16 18:27:02 -07:00
Rajeev Kumar
4df25df8ed Add privapp permissions permission for
com.android.cellbroadcastreceiver package.

Bug: 159544147
Fixes: 159544147
Test: Built a system image with this change and flashed
a device with it and the device booted successfully.

Change-Id: I7fd5080aa740fcfcebeb4f934d0a3fc39d847cc9
Merged-In: I7fd5080aa740fcfcebeb4f934d0a3fc39d847cc9
2020-07-02 00:40:05 +00:00
TreeHugger Robot
454aeee949 Merge "Deliver hideInsets when target is removed" into rvc-dev am: bb6c1e09ad
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/12011265

Change-Id: Ic690589869754fbef778d9c3405989abbcc7f57a
2020-07-01 17:00:07 +00:00
Taran Singh
4545703367 Deliver hideInsets when target is removed
hideInsets(IME) may not be delivered to the control target if
the window requesting hide is no longer available in WindowManager's
window map. However, it is still nicer to deliver it to the default
display's control target rather than not delivering it at all.
Fix: 159623277
Test: Manually using steps in bug.

Change-Id: I22cdf20627da2183d30af444f6dd9d0375d417c1
2020-06-30 10:02:10 -07:00
TreeHugger Robot
276b14ee1a Merge "Wait for remote animation to stop freezing display" into rvc-dev am: 0207dba4b6
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/12034123

Change-Id: I6dbf73fff1409640bd2c9390cffbdc00292496b8
2020-06-30 03:32:35 +00:00
TreeHugger Robot
0207dba4b6 Merge "Wait for remote animation to stop freezing display" into rvc-dev 2020-06-30 03:29:46 +00:00
Joshua Duong
b47d1e6100 Merge changes from topic "adbwifi-cts" into rvc-dev am: 5ab3aa0c7b
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/12000446

Change-Id: I27c6493f075ace2e9c12f9b7f359f42ccbb1406f
2020-06-30 00:57:37 +00:00
Joshua Duong
5ab3aa0c7b Merge changes from topic "adbwifi-cts" into rvc-dev
* changes:
  Add shell commands for AdbService.
  Add shell permissions for CTS test (AdbManagerTest).
2020-06-30 00:55:36 +00:00
Riddle Hsu
96ed092b10 Wait for remote animation to stop freezing display
If display is rotated 180 degree, the display might not have
configuration change. And if there is remote rotation and it hasn't
done, the rotation of display is still the old one. Once there is
a path calls stop-freezing-display, the rotation animation will be
executed directly with 0 degree delta. And if the activity needs to
relaunch, there will be obvious flickering.

Fixes: 160107205
Test: atest DisplayContentTests#testRemoteRotation
Change-Id: I66a02b67f7066abafd65c2c282144222701feaae
2020-06-30 01:28:35 +08:00
Rajeev Kumar
0687271685 Merge "Add privapp permissions permission for com.android.cellbroadcastreceiver package." into rvc-dev am: 0c059b97dd
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/12011267

Change-Id: I27bd61f10559eb4d49232636118fc705cbc8fcd5
2020-06-26 21:33:36 +00:00
Rajeev Kumar
8fe5465ada Add privapp permissions permission for
com.android.cellbroadcastreceiver package.

Bug: 159544147
Fixes: 159544147
Test: Built a system image with this change and flashed
a device with it and the device booted successfully.

Change-Id: I7fd5080aa740fcfcebeb4f934d0a3fc39d847cc9
2020-06-26 19:26:31 +00:00
Joshua Duong
f2e03b393f Add shell permissions for CTS test (AdbManagerTest).
Bug: 159936209

Test: atest CtsAdbManagerTests
Change-Id: I896b53df582cceb7d1b0d6694d00064b0fb57b94
2020-06-25 15:03:19 -07:00
Shafik Nassar
854c557ca4 Merge "Allow MediaProvider to request REGISTER_STATS_PULL_ATOM" into rvc-dev am: f59cdcf6dc
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/11880479

Change-Id: I802a9b91db2ad2cf74852c1af1b582a81bca91db
2020-06-18 12:41:38 +00:00
Shafik Nassar
f59cdcf6dc Merge "Allow MediaProvider to request REGISTER_STATS_PULL_ATOM" into rvc-dev 2020-06-18 12:25:55 +00:00
Hao Chen
056b64be1a Move car companion device support app perms to framework
Test: build and flash the trout PDK, boot to the UI
Bug: 158483244
Change-Id: Ic8cd135cde2d616e5a8d36b71de56acba4dab261
2020-06-17 21:12:30 +00:00
Enrico Granata
a2a7b8909b Merge "Move car companion device support app perms to framework" into rvc-dev am: 561b09994b
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/11853982

Change-Id: I991a2c31bb9060108ac2e3f6d44569c8e480f508
2020-06-17 20:02:57 +00:00
shafik
44f3ca5679 Allow MediaProvider to request REGISTER_STATS_PULL_ATOM
MediaProvider needs the permission to register a StatsPullCallback in
statsd to pull the external storage metrics.

Test: build
Bug: 149669087
Change-Id: I4f7e09c2e514e2290d1cd5ac765bb115e7ade9ef
2020-06-17 11:34:01 +01:00
Hao Chen
8de2ca3e5c Move car companion device support app perms to framework
Test: build and flash the trout PDK, boot to the UI
Bug: 158483244
Change-Id: Ic8cd135cde2d616e5a8d36b71de56acba4dab261
2020-06-16 21:30:12 +00:00
Yo Chiang
5218a1f9e5 Merge "DO NOT MERGE Temporarily rename the package name of BugReportApp" 2020-06-16 11:30:46 +00:00
Andrew Walbran
ae0e270ff7 Merge "Add keylayout for SnakeByte iDroid:con" am: 99ce8c4945 am: f8b50f034a
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1331927

Change-Id: I0b3ef96e98ff8ee11d3b807c98f24c2dff8e8ac2
2020-06-15 12:45:33 +00:00
Andrew Walbran
99ce8c4945 Merge "Add keylayout for SnakeByte iDroid:con" 2020-06-15 12:04:43 +00:00
Andrew Walbran
ba81efe04a Add keylayout for SnakeByte iDroid:con
This is a Bluetooth game controller which supports Android, but the
thumbstick buttons had the wrong keycodes.

Test: manual test with Gamepad Tester app
Change-Id: Id7d8ccbf282e25fd076903cbf9f3d66d30941c3e
2020-06-14 10:16:28 +01:00
Yo Chiang
2812c3b042 DO NOT MERGE Temporarily rename the package name of BugReportApp
There is some de-sync happening between AOSP and internal.
BugReportApp has been moved to AOSP as a platform APP, however the
package name is renamed to com.android.car.bugreport only in internal.
AOSP BugReportApp still have the old package name
com.google.android.car.bugreport.

A recent change I5e541138c35cdf67d18ce5475221baeb3e7faef4 moved the
privapp whitelist to AOSP, too. However that is the whitelist for
com.android.car.bugreport, not com.google.android.car.bugreport.

Since the only difference is the package name, I'll just point AOSP
BugReportApp to use the internal BugReportApp's whitelist, which is
privapp_whitelist_com.android.car.bugreport (without .google).
And change the package name in
privapp_whitelist_com.android.car.bugreport to
com.google.android.car.bugreport.

Use DO NOT MERGE as there are only temporary fixes and these
workarounds should all go away when next platform release lands.

Bug: 158151004
Test: TH presubmit
Change-Id: I35b90e4ff2428a8a685c51a7c49b371bcbb240e8
2020-06-13 07:16:04 +00:00
Yan Zhu
78a201ba95 Merge "Install auto-generrate overlay packages even when not included in whitelist" into rvc-dev am: b6ac0061fa
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/11529815

Change-Id: I86ae7d8b23708ee443d33f5ee17717c04cab931c
2020-06-10 04:38:17 +00:00
Yan Zhu
b6ac0061fa Merge "Install auto-generrate overlay packages even when not included in whitelist" into rvc-dev 2020-06-10 04:23:30 +00:00
Zhomart Mukhamejanov
678cc7d33d Move car bugreport app perms to framework.
Change-Id: I5e541138c35cdf67d18ce5475221baeb3e7faef4
Test: emulator
Bug: 158151004
2020-06-09 13:34:02 -07:00
TreeHugger Robot
ba6d043909 Merge "Move car bugreport app perms to framework." into rvc-dev am: 94bedc9aec
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/11784244

Change-Id: I45cb0ff585ef2ea8f23868dfa226432bfda7ee84
2020-06-09 01:21:53 +00:00
Yan Zhu
31b01e4bc5 Install auto-generrate overlay packages even when not included in whitelist
Detect auto-generated overlay packages according to the suffix
(.auto_generated_rro_vendor_ OR .auto_generated_rro_product_)

Bug: 156668533
Bug: 140120696
Test: logcat: set DEBUG=true
adb logcat UserManagerService | grep overlay
atest
FrameworksServicesTests:com.android.server.pm.UserSystemPackageInstallerTest
-c

Change-Id: I1835eb923bf2421b2e171be0ac0fa400b6fd38f7
2020-06-08 16:34:34 -07:00
Zhomart Mukhamejanov
9fd6408edd Move car bugreport app perms to framework.
Change-Id: I5e541138c35cdf67d18ce5475221baeb3e7faef4
Test: emulator
Bug: 158151004
2020-06-07 18:04:19 -07:00
Xin Li
d7785982ac Merge "Merge QQ3A.200605.002 into master" 2020-06-06 01:41:11 +00:00
TreeHugger Robot
ee5837a47b Merge "Adding incremental related peremissions to Shell" into rvc-dev am: d1f5bf1f93
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/11722415

Change-Id: Id297f0a5f071ab2fe92366a5386097d84bd0a8c9
2020-06-04 22:36:19 +00:00
Dimuthu Gamage
8589197fb5 Adding incremental related peremissions to Shell
This is expected to be used with adoptShellPermission in the Incremental
CTS tests.

Test: atest android.content.pm.cts.PackageManagerShellCommandTest
(There will be future tests relying on this)

Bug: 158024822
Change-Id: I46674498783c5323668ff775c76ff31a304aeadb
2020-06-04 17:04:44 +00:00
Sung Min Lee
2b3c00b99f Add CAPTURE_AUDIO_OUTPUT permission required for GTS test
GtsDialerAudioTestCases require this privileged permission for testing in GTS.

Bug: 157243201
Test: run gts -m GtsDialerAudioTestCases
Change-Id: I32516e5dcf966b05cfb8ab4956a0cdb183298f2a
Merged-In: I32516e5dcf966b05cfb8ab4956a0cdb183298f2a
2020-06-03 22:09:35 -07:00
Sung Min Lee
3c0fe83b63 Merge "Add CAPTURE_AUDIO_OUTPUT permission required for GTS test" into rvc-dev am: 5bafce8420
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/11712625

Change-Id: I59aa0b8b5327685cd6658a6a0a382f61c1d3ea7a
2020-06-04 01:22:17 +00:00