Commit Graph

8158 Commits

Author SHA1 Message Date
Dieter Hsu
4e593f7fd5 Merge "Enable bug report tests in pre/postsubmit" 2020-06-25 15:13:42 +00:00
Vladimir Marko
3924cd27f1 Merge "Use @CriticalNative for writes in Parcel." 2020-06-25 08:17:58 +00:00
Vladimir Marko
bfac2652b0 Use @CriticalNative for writes in Parcel.
Make Parcel.nativeWrite{Int,Long,Float,Double}() return an
error code instead of throwing exceptions on error. This
allows markiong them as @CriticalNative but we must pass on
any errors from Java back to native for throwing exceptions.

This is a follow-up to commit
    b148b6c3c8

ParcelPerfTest results on blueline-userdebug with little
cores at fixed frequency 1420800, big cores off and the
vendor.thermal-engine stopped:
                    before after
timeWriteInt_mean:  168    68
timeWriteLong_mean: 164    67
(No benchmarks for writeFloat and writeDouble.)

Test: blueline-userdebug boots.
Change-Id: Iea4ef2a933a7e8115459ab1bc4d6235282b1ceb8
2020-06-24 19:15:38 +01:00
TreeHugger Robot
cedb11cc84 Merge "Add additional info to device ID docs in TelephonyManager and Build" into rvc-dev am: 3fa2d86fd0 am: e71ed27853 am: 4cad6acf29 am: 5a0c835564
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/11980365

Change-Id: I7a2952c907c8ac8081413b7eeafcd6d466597897
2020-06-24 17:01:22 +00:00
TreeHugger Robot
e71ed27853 Merge "Add additional info to device ID docs in TelephonyManager and Build" into rvc-dev am: 3fa2d86fd0
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/11980365

Change-Id: I70c91479f8f8557f1e0abbd125c6a4e24c262bd8
2020-06-24 16:29:17 +00:00
TreeHugger Robot
3fa2d86fd0 Merge "Add additional info to device ID docs in TelephonyManager and Build" into rvc-dev 2020-06-24 16:15:32 +00:00
Dieter Hsu
848113e595 Enable bug report tests in pre/postsubmit
Bug: 155604488
Test: atest --test-mapping --dry-run \
          services/core/java/com/android/server/os:presubmit
Test: atest --test-mapping --dry-run core/java/android/os:presubmit
Change-Id: I054d05d4fa8ff02f1c404d0883c382a2d5911f88
2020-06-24 12:20:32 +08:00
Michael Groover
e0de018109 Add additional info to device ID docs in TelephonyManager and Build
Android 10 introduced additional restrictions to access persistent
device identifiers. This commit updates the javadocs for
TelephonyManager and Build to provide additional details regarding
the requirements and how to check if these requirements are met.

Fixes: 158471988
Test: m docs -j
Change-Id: I02932a22ecc5b761aa1a92d59d09d31863c34235
2020-06-23 19:52:51 -07:00
Jing Ji
643bab1a3e Merge "Fix memory leak in StrictMode violation throttling" into rvc-dev am: 471ef84e33 am: 7298b685dd am: d889dd91b9 am: 31d2ea9252
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/11902484

Change-Id: Iecb676fa467c612b025dda9cdcc8343e00072413
2020-06-23 01:04:31 +00:00
Jing Ji
31d2ea9252 Merge "Fix memory leak in StrictMode violation throttling" into rvc-dev am: 471ef84e33 am: 7298b685dd am: d889dd91b9
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/11902484

Change-Id: I28f46978da7fd7d30fd5a4b57defcde29c38cb62
2020-06-23 00:42:13 +00:00
Jing Ji
341fd0c6c7 Merge "Fix memory leak in StrictMode violation throttling" into rvc-dev am: 471ef84e33
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/11902484

Change-Id: I88b40ce6b018492e4e329e06c9718aa55dd76ca7
2020-06-23 00:17:00 +00:00
Jing Ji
471ef84e33 Merge "Fix memory leak in StrictMode violation throttling" into rvc-dev 2020-06-23 00:04:49 +00:00
TreeHugger Robot
5d1c4c4b38 Merge "Revert non-API changes to not throw UserOperationException any more" into rvc-dev am: 960e49335a am: 35d7e8ba30 am: cd966a42d3 am: 62caef01d4
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/11859726

Change-Id: I77f454eee55d84217f3b5ec96f0ea90ee0970b52
2020-06-22 22:03:19 +00:00
TreeHugger Robot
cd966a42d3 Merge "Revert non-API changes to not throw UserOperationException any more" into rvc-dev am: 960e49335a am: 35d7e8ba30
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/11859726

Change-Id: I377aee77ec9e8f70473c5c8ae9caf4106b7711b7
2020-06-22 21:24:31 +00:00
Jing Ji
6985fb39f0 Fix memory leak in StrictMode violation throttling
* Add hashCode() to the base Violation class for dup detections
* Discard obsoleted violation fingerprints if possible

Bug: 159128771
Bug: 159626227
Test: run cts -m CtsOsTestCases -t android.os.cts.StrictModeTest
Test: Manual - Loop generation of StrictMode violations
Test: Manual - Check heap dump
Change-Id: I19a0922fe010fad97b6b819e73acb7db08f84930
2020-06-22 14:22:32 -07:00
TreeHugger Robot
0880adf50a Merge "Revert non-API changes to not throw UserOperationException any more" into rvc-dev am: 960e49335a
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/11859726

Change-Id: I75960fdfde95eb786b612aa911853d6cd2501b54
2020-06-22 21:13:11 +00:00
TreeHugger Robot
960e49335a Merge "Revert non-API changes to not throw UserOperationException any more" into rvc-dev 2020-06-22 21:05:23 +00:00
Robin Lee
7ac6636159 Revert non-API changes to not throw UserOperationException any more
Bug: 158697055
Test: atest android.admin.cts.DevicePolicyManagerTest.
Test: atest android.server.pm.UserManagerTest
Change-Id: I07785d053befab6be9e3076e058cac67ff8f702e
2020-06-19 20:45:44 +00:00
Hunter Knepshield
537f835e2b Merge changes from topic "bugreport-stub" into rvc-dev am: 9568960297 am: a7dad0b5cc am: 8a01758622 am: bc8fec3027
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/11856802

Change-Id: Ie2dc8d2094be3f42eb13e561bda9aa4ef24332cc
2020-06-18 18:07:44 +00:00
Hunter Knepshield
8a01758622 Merge changes from topic "bugreport-stub" into rvc-dev am: 9568960297 am: a7dad0b5cc
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/11856802

Change-Id: I38f827361f1f234e49c086953d0c0d7426e0d70f
2020-06-18 17:18:19 +00:00
Hunter Knepshield
5b622bb7bf Merge changes from topic "bugreport-stub" into rvc-dev am: 9568960297
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/11856802

Change-Id: I29f29e33157cec7f99d2966acc2a57940ff346d3
2020-06-18 17:03:41 +00:00
Hunter Knepshield
9568960297 Merge changes from topic "bugreport-stub" into rvc-dev
* changes:
  Reevaluate some carrier-associated apps' status on SDK changes.
  Add new "addedInSdk" attribute to carrier-associated apps.
2020-06-18 17:01:01 +00:00
Luke Huang
7c117370e3 Merge "Disable sockets and DNS if process lacks INTERNET permission." into rvc-dev am: 7144459282 am: dae5d3f223 am: d996337c91 am: 4e4f6a89c3
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/11881939

Change-Id: I945b061484a7a2da22043103b7102e16fceff930
2020-06-18 04:24:37 +00:00
Luke Huang
dae5d3f223 Merge "Disable sockets and DNS if process lacks INTERNET permission." into rvc-dev am: 7144459282
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/11881939

Change-Id: I7c285a848ac947e0acf1acc8bc32f3ece3456412
2020-06-18 03:23:46 +00:00
Luke Huang
7144459282 Merge "Disable sockets and DNS if process lacks INTERNET permission." into rvc-dev 2020-06-18 03:03:06 +00:00
Luke Huang
6f214e8ebe Disable sockets and DNS if process lacks INTERNET permission.
This is a Client-only solution.
  - Add to NetdClient a per-process std::atomic_boolean
    similar to netIdForProcess and netIdForResolv.
  - The boolean says whether the process should be
    allowed Internet connectivity.
  - Add an @hide method to NetUtils.java to set the boolean;
    call it from the initialization code of the new
    process just after forking from zygote.
  - Make netdClientSocket and dnsOpenProxy check the
    boolean. If the boolean is false, return EPERM from
    socket calls.

Bug: 150028556
Test: atest NetworkUtilsTest
Test: atest CtsAppSecurityHostTestCases:UseProcessTest
Change-Id: If002280fbad493dfc2db3d9d505c0257d49a9056
Exempt-From-Owner-Approval: OWNERS already approved identical patchset 5
2020-06-18 03:02:06 +00:00
TreeHugger Robot
feeb4ab192 Merge "Clarify doc for users, clarifying profiles" into rvc-dev am: d41aca1009
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/11889023

Change-Id: I748a8b1af01b8e96c8a3e522655e77aa81683e4f
2020-06-18 02:28:08 +00:00
TreeHugger Robot
764ee5c5a2 Merge "Clarify doc for users, clarifying profiles" 2020-06-18 01:39:34 +00:00
Adam Bookatz
36bacceee5 Clarify doc for users, clarifying profiles
Test: N/A
Bug: 159173436
Change-Id: I3c105559801a72ef1d91d9db2d42a816e27e24f6
Merged-In: I3c105559801a72ef1d91d9db2d42a816e27e24f6
2020-06-18 00:08:51 +00:00
Adam Bookatz
ffffe91132 Clarify doc for users, clarifying profiles
Test: N/A
Bug: 159173436
Change-Id: I3c105559801a72ef1d91d9db2d42a816e27e24f6
2020-06-17 17:07:11 -07:00
Hunter Knepshield
1172ffa7c2 Add new "addedInSdk" attribute to carrier-associated apps.
Previously, the sysconfig wasn't capable of understanding
carrier-associated apps that were added after a device's initial launch
(i.e. via OTA) because the logic in CarrierAppUtils explicitly avoids
disabling such apps a second time.

Most of this change is just plumbing everything through. For now, it's
all @hide due to R API deadlines. It will be made public in S.

Bug: 154872019
Test: manual, QA, atest FrameworksTelephonyTests:CarrierAppUtilsTest
Change-Id: I530a4f73146b09879547ca2e0c26428957fef37a
2020-06-16 16:48:38 -07:00
Nikita Ioffe
3a5a83e4b8 Merge "Respect MANAGE_EXTERNAL_STORAGE in checks for READ/WRITE_EXTERNAL_STORAGE" into rvc-dev am: 27d6605c52 am: 06a12085ab am: bf11408260 am: f522b98926
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/11797136

Change-Id: I1fd893db7c475a7e03c03618bd23f55f20df8fa1
2020-06-16 11:08:58 +00:00
Nikita Ioffe
bf11408260 Merge "Respect MANAGE_EXTERNAL_STORAGE in checks for READ/WRITE_EXTERNAL_STORAGE" into rvc-dev am: 27d6605c52 am: 06a12085ab
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/11797136

Change-Id: I58536f75ebb7fa4ed177303837803a48df5d41b0
2020-06-16 10:38:27 +00:00
Nikita Ioffe
4a911583b3 Merge "Respect MANAGE_EXTERNAL_STORAGE in checks for READ/WRITE_EXTERNAL_STORAGE" into rvc-dev am: 27d6605c52
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/11797136

Change-Id: I1446f282205ed5da4256ca9995e3d97020525f50
2020-06-16 10:20:37 +00:00
Nikita Ioffe
27d6605c52 Merge "Respect MANAGE_EXTERNAL_STORAGE in checks for READ/WRITE_EXTERNAL_STORAGE" into rvc-dev 2020-06-16 10:02:49 +00:00
TreeHugger Robot
9b55f5ffd1 Merge "Don't provide read logs for shell-initiated installations." into rvc-dev am: e0ba6d9dff am: 95a411a87d
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/11778056

Change-Id: Ib82b69429655ab0245b08aeab615766e41296e7c
2020-06-15 16:59:31 +00:00
TreeHugger Robot
84f65247cb Merge "Don't provide read logs for shell-initiated installations." into rvc-dev am: e0ba6d9dff
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/11778056

Change-Id: I866bc89927ae11a0da7069d33e3e06d5c1f1b51f
2020-06-15 16:42:24 +00:00
Nikita Ioffe
fc3a740282 Respect MANAGE_EXTERNAL_STORAGE in checks for READ/WRITE_EXTERNAL_STORAGE
Test: test app mentioned in the bug
Bug: 158316513
Change-Id: I254479d6616d2e09349fcd9c569c5092dbdefaca
2020-06-15 13:01:06 +01:00
Alex Buynytskyy
3697d9e45d Don't provide read logs for shell-initiated installations.
Only if the application is profileable.

Bug: 158238023
Fixes: 158238023
Test: atest PackageManagerShellCommandTest PackageManagerShellCommandIncrementalTest IncrementalServiceTest PackageParserTest
Change-Id: I8575830ec3f29850297fdbfbaa157072d6350a28
2020-06-12 14:39:18 -07:00
Alex Buynytskyy
0403545508 Don't provide read logs for shell-initiated installations.
Only if the application is profileable.

Bug: 158238023
Fixes: 158238023
Test: atest PackageManagerShellCommandTest PackageManagerShellCommandIncrementalTest IncrementalServiceTest PackageParserTest
Change-Id: I8575830ec3f29850297fdbfbaa157072d6350a28
Merged-In: I8575830ec3f29850297fdbfbaa157072d6350a28
2020-06-12 13:30:45 -07:00
Adam Bookatz
d44dd441dc Merge "Default isUserSwitcherEnabled showEvenIfNotActionable" into rvc-dev am: a677e1c6f9 am: 58352e4e66 am: 0efeed6c12 am: 64d9cdf715
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/11829304

Change-Id: I0a6333cb3869128cf099e7f38785b5db77e8344c
2020-06-12 01:39:39 +00:00
Adam Bookatz
0efeed6c12 Merge "Default isUserSwitcherEnabled showEvenIfNotActionable" into rvc-dev am: a677e1c6f9 am: 58352e4e66
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/11829304

Change-Id: Ie641939bcdafe6d829b9a64bc0064d8b4058cb9d
2020-06-12 01:11:44 +00:00
Adam Bookatz
dae6bc2c9f Merge "Default isUserSwitcherEnabled showEvenIfNotActionable" into rvc-dev am: a677e1c6f9
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/11829304

Change-Id: Ib25f90dbda73f5eeb05823d7672c33637a5e1e35
2020-06-12 01:00:47 +00:00
Adam Bookatz
a677e1c6f9 Merge "Default isUserSwitcherEnabled showEvenIfNotActionable" into rvc-dev 2020-06-12 00:47:47 +00:00
TreeHugger Robot
d0a4d6d8ad Merge "Add details to VibrationEffect waveform documentation" into rvc-dev am: 19dd14d76a am: 76b6eb1e9f am: 131cf3f49c am: 300c251919
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/11837599

Change-Id: I46aecd3c9fcd66a9fdd68ec03326233183875ac5
2020-06-11 18:43:48 +00:00
TreeHugger Robot
300c251919 Merge "Add details to VibrationEffect waveform documentation" into rvc-dev am: 19dd14d76a am: 76b6eb1e9f am: 131cf3f49c
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/11837599

Change-Id: I3fbd70ec889885226ea9d294769ab2295ce238f5
2020-06-11 18:11:41 +00:00
TreeHugger Robot
bdac8459fb Merge "Add details to VibrationEffect waveform documentation" into rvc-dev am: 19dd14d76a
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/11837599

Change-Id: Ic47e871ca849268ffaf8e8b759f2ceb9b93d6e48
2020-06-11 17:55:27 +00:00
Lais Andrade
ef5d8751e6 Add details to VibrationEffect waveform documentation
Explain the time unit of timings argument and copy explanation of
amplitude values to the summary segments of the javadocs.

Fix: 140846849
Test: N/A
Change-Id: Ia6fd6cb5d0e16076a54f24f7c3d2f3d4ca78d5bd
2020-06-11 16:39:36 +00:00
Adam Bookatz
600210d7cb Default isUserSwitcherEnabled showEvenIfNotActionable
In ag/11573771, the default value for isUserSwitcherEnabled() was
put as false, but it was supposed to be true (as it had been
in patch 1 of that cl).

Bug: 157881376
Test: manual
Change-Id: I456e7eb9527dad8da5d5f99ecbfc8bcf40b7bdcc
2020-06-11 00:22:37 +00:00
TreeHugger Robot
ce2bc09b53 Merge "Apply app data isolation on isolated or app zygote processes" into rvc-dev am: 8434b9fc88 am: 5b1227fc8a am: 42e6e5b254 am: 0bb3147261
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/11689593

Change-Id: Idc6907bcc168ab7e3682d23b1e628a823fd6f026
2020-06-08 11:48:58 +00:00