Commit Graph

16121 Commits

Author SHA1 Message Date
Automerger Merge Worker
b615fa46c9 Merge "Use new UnsupportedAppUsage annotation." am: 70129fc863 am: fe3063fb71
Change-Id: Iea82f97f0ba766ce3f435630175aea48ca47f12f
2020-01-09 16:15:31 +00:00
Artur Satayev
d9b11b058c 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: I8789f8499d4dca08580672e9e45ed9a7026dd686
Merged-In: I8789f8499d4dca08580672e9e45ed9a7026dd686
2020-01-09 13:56:05 +00:00
Automerger Merge Worker
e219088375 Merge "Add setDisabledForSimNetworkLock to StatusBarManager" am: f428f58080 am: 33d3e85975
Change-Id: Id3ea80c30e149588a6d97f02df978f258dda3495
2020-01-08 21:13:09 +00:00
Hall Liu
f428f58080 Merge "Add setDisabledForSimNetworkLock to StatusBarManager" 2020-01-08 20:54:48 +00:00
Automerger Merge Worker
ef100e45fe Merge "Change NetworkTimeUpdateServiceImpl behavior" am: 48247d9223 am: f11a45b756
Change-Id: Ie3b6457ba196f7aa00ffb6e2fa77e5acbb926374
2020-01-07 10:30:35 +00:00
Neil Fuller
48247d9223 Merge "Change NetworkTimeUpdateServiceImpl behavior" 2020-01-07 10:07:08 +00:00
Automerger Merge Worker
cccf7a2b84 Merge "Clean up SmsApplication and expose getDefaultSmsPackage" am: 2ada7fbac2 am: b128b793c7
Change-Id: Icee2c41d635883c6b9ede6bf6ec3bbfda22cdc1f
2020-01-07 01:01:54 +00:00
Hall Liu
2ada7fbac2 Merge "Clean up SmsApplication and expose getDefaultSmsPackage" 2020-01-07 00:36:51 +00:00
Hall Liu
9ded659a50 Add setDisabledForSimNetworkLock to StatusBarManager
Add a new @SystemApi disable utility method to allow telephony's
mainline module to disable the status bar when the device is SIM-locked

Bug: 146834818
Bug: 138956541
Test: atest StatusBarManagerTest
Change-Id: Id3757fc560c5b70bed553f19b050524a024b4c78
2020-01-06 15:47:45 -08:00
Automerger Merge Worker
ec776dfda9 Merge "Add new permissions" am: 62ace8c46a am: c0f9b27214
Change-Id: I2114c613729f0d84d773b7e8b58402cda302a8c8
2020-01-06 21:20:53 +00:00
Neil Fuller
62ace8c46a Merge "Add new permissions" 2020-01-06 19:38:25 +00:00
Automerger Merge Worker
fe03e4c510 docs: Fix typo in IMPORTANCE_SERVICE description am: 08a4e470b8 am: edcfda720b am: fc94ebae09
Change-Id: I24a825364458eafd6d101d47a1cd467d7401cc42
2020-01-06 18:41:36 +00:00
Automerger Merge Worker
fc94ebae09 docs: Fix typo in IMPORTANCE_SERVICE description am: 08a4e470b8 am: edcfda720b
Change-Id: Id0683ebab467f7baaac1650b15dd8e98f8057306
2020-01-06 18:24:58 +00:00
Automerger Merge Worker
edcfda720b docs: Fix typo in IMPORTANCE_SERVICE description am: 08a4e470b8
Change-Id: I32360f63be584c4223c6aae692beb48c0bdf4802
2020-01-06 18:13:01 +00:00
Kevin Hufnagle
08a4e470b8 docs: Fix typo in IMPORTANCE_SERVICE description
Test: make ds-docs -j32

Bug: 140783404

Change-Id: Ife86109eebefe9c87f7c9ed4a0587676e3392d90
Exempt-From-Owner-Approval: Docs-only change
2020-01-03 20:05:31 +00:00
Automerger Merge Worker
bbce9e0c5a Merge "Use ro.product.vndk.version for unbundled product apks" am: cbfcd44f68 am: e0e165f06e
Change-Id: I6507b31c3a1b36830a231064e560d978b9427f5c
2020-01-03 07:36:52 +00:00
Justin Yun
1ef374f98b Use ro.product.vndk.version for unbundled product apks
Instead of using "ro.product.apps.unbundled", use
"ro.product.vndk.version" to determine if product apks are unbundled.
"ro.product.vndk.version" will be defined by
PRODUCT_PRODUCT_VNDK_VERSION. If it is defined, all product apks must
be unbundled.

Bug: 144534640
Bug: 127738095
Bug: 128557860
Test: boot and check logs if product apps are loaded successfully
Change-Id: I6d0f7c20e131dfe12203c63a14e6254a8223893b
2020-01-02 06:30:02 +00:00
Hall Liu
35c243caa4 Clean up SmsApplication and expose getDefaultSmsPackage
- Clean up usages of hidden AppOpsManager APIs in SmsApplication
- Add unit tests for SmsApplication
- Expose RoleManager#getDefaultSmsPackage for use in SmsApplication.

Bug: 146834818
Test: atest SmsApplicationTest
Change-Id: I4ab49d7f6274389e7de7cd7223cab3c433936044
2019-12-31 14:41:02 -08:00
Automerger Merge Worker
08074c62b0 Merge "[Tether13] Move TetheringManager into framework" am: 2410d67357 am: 25cc1f47c5
Change-Id: I9ec25eb984e3b534ddcc9313836a319b21526998
2019-12-20 14:00:29 +00:00
Neil Fuller
4ab8a199de Change NetworkTimeUpdateServiceImpl behavior
This change moves some logic associated with time detection out of the
NetworkTimeUpdateServiceImpl and moves it to the TimeDetectorStrategy
called by the TimeDetectorService.

The TimeDetectorStategy implementation now decides when to use an
NTP-derived time instead. The logic implemented here is effectively the
same as it was: NITZ takes priority over NTP until the latest NITZ
signal becomes "too old".

The motivating reasons for the change:
1) The "what signal is used when several are available?" logic should be
in one place: the TimeDetectoryStrategy not scattered around the
platform. Centralizing will enable different strategies and time sources
to be introduced over time.

2) It will allow removal of the ACTION_NETWORK_SET_TIME intent in a
follow-up commit; this intent was used to coordinate the NTP vs NITZ
logic should no longer be required.

The "bonus" effect of this change is that NetworkTimeUpdateServiceImpl
becomes more general: It can now be the authority for the NTP time on a
device independently of how the system clock should be set. e.g. it
could be used in future to back the
AlarmManager.currentNetworkTimeMillis() API call.  Anything that needs a
"what is the best time according to NTP?" answer could use this service.

Note: The NetworkTimeUpdateServiceImpl still observes the AUTO_TIME
setting and will perform an NTP lookup "on demand" (if required) when
the user enables the setting. This should be a temporary state and
likely to be removed in future; knowledge of AUTO_TIME shouldn't be
required for the NTP info to be correct and if
NetworkTimeUpdateServiceImpl is doing the right thing.

Bug: 140712361
Test: atest com.android.server.timedetector
Test: atest android.app.timedetector
Change-Id: I4b2936a42c552c4dd4cb55010306bb81bca0c712
2019-12-19 19:21:47 +00:00
markchien
6d06f6d51a [Tether13] Move TetheringManager into framework
Move tethering out of ConnectivityService. All client would
use TetheringManager to talk with TetheringService directly.

Bug: 144320246
Test: -build, flash, boot
      -atest TetheringTests

Change-Id: Ib051bea724a256f9c4572b566e46ae7b9c4abe6e
Merged-In: Ib051bea724a256f9c4572b566e46ae7b9c4abe6e
2019-12-19 20:53:06 +08:00
Neil Fuller
09e8b7d841 Add new permissions
This adds new permissions required when setting the time /zone in
response to telephony signals and when setting the time / zone manually
along the lines of "principle of least privilege".

The intent is to later restrict the number of distinct processes that
can manipulate the device system clock / time zone property directly so
that all time changes go through the time / time zone detector services,
which can enforce policy, log the reasons for changes, and so on.

Bug: 140712361
Test: atest com.android.server.timedetector
Change-Id: Iabd3a5f449ad2ef2b6581475ef2535a4a8a88ef9
2019-12-19 11:11:48 +00:00
Automerger Merge Worker
fb829df378 Merge "[RCS] Add IMS service into system service registry" am: 6a1d13f58e am: a962a65575
Change-Id: I61549d3d4da7ffdf5f2d497e52cd7a2fdd0f2c05
2019-12-17 00:10:51 +00:00
James Lin
6a1d13f58e Merge "[RCS] Add IMS service into system service registry" 2019-12-16 23:28:44 +00:00
Automerger Merge Worker
053c87de7d Merge "Expose the onCarrierPrivilegedAppsChanged as SystemApi" am: 58ea8819f5 am: c825f758e5
Change-Id: I5758fa60f50c72fcf7b51e564e39cf5f9c821d23
2019-12-16 19:02:24 +00:00
Treehugger Robot
58ea8819f5 Merge "Expose the onCarrierPrivilegedAppsChanged as SystemApi" 2019-12-16 18:40:50 +00:00
Automerger Merge Worker
560eac460c Merge "remove API RoleManager.getFinancialSms" am: c0fa362e1b am: 679980cbca
Change-Id: I6f5db398a52a01b3fcc5b7a672d39f92dcd93479
2019-12-14 08:19:38 +00:00
Chen Xu
435d1c1a53 remove API RoleManager.getFinancialSms
getFinancialSms is not functional and not used today, thus
remove it to avoid future confusion

Bug: 138745655
Bug: 140908357
Test: atest android.telephony.cts.SmsManagerTest
Change-Id: Ib57d0fc189b6c894227894ee02b592f7ee46f22f
(cherry picked from commit d6b2673181)
Merged-in: Ib57d0fc189b6c894227894ee02b592f7ee46f22f
2019-12-13 20:48:41 -08:00
yinxu
4631f7231f Expose the onCarrierPrivilegedAppsChanged as SystemApi
(cherry picked from commit 0016eefe11)

Bug: 145944877
Test: N/A
Merged-in: I0fd32f38587ae46d1d170bc8353d23bbc9928cd0
Change-Id: I0fd32f38587ae46d1d170bc8353d23bbc9928cd0
2019-12-13 11:01:43 -08:00
James.cf Lin
304a66a3f0 [RCS] Add IMS service into system service registry
Bug: 139260826
Test: Manual
Change-Id: Ie8625706bb9b18c3a9d1a55d17d3c1c045eb104e
2019-12-13 07:41:02 +08:00
Automerger Merge Worker
161d1764c8 Merge "Handle multiple phoneIds in time detection" am: 51c61e8bdb am: 1602545f28
Change-Id: I75551184a50e7bfe9cebd9b649bfd71acf5ac0f7
2019-12-12 12:27:01 +00:00
Neil Fuller
312da9b9fc Handle multiple phoneIds in time detection
Android has dual sim devices, which means multiple "phone" time
signals. NITZ is generally trusted and considered "good enough" in the
absence of better signals, but it is provided by carriers and it's not
unusual for the signals to be incorrect by minutes. We don't want the
device system clock just flicking to the latest signal received.

The changes to the SimpleTimeDetectorStrategy try to balance recency and
provide some consistency / determinism. See comments in the code for
details. The time zone detection works in a similar way, particularly
with respect to choosing the lowest phoneId in the event of a tie.

There will be a follow-up change to remove the word "Simple" from
SimpleTimeDetectorStrategy as it no longer applies.

Test: atest services/tests/servicestests/src/com/android/server/timedetector/SimpleTimeDetectorStrategyTest.java
Test: atest android.app.timedetector
Bug: 140712361
Change-Id: I228aff8709eabfcec910af22f7ab08fee32d566a
2019-12-10 19:15:38 +00:00
Automerger Merge Worker
e08205b609 Merge "track and report packages with undecorated remoteviews" into qt-qpr1-dev am: 1eb5828022
Change-Id: I24e5eeecdac3a9d72d73fb5bca9cdc7ec202f94c
2019-12-10 18:59:17 +00:00
Chris Wren
bc487b5759 track and report packages with undecorated remoteviews
print query results with:
  adb shell dumpsys notification --remote-view-stats

test the pulled atom with:
  make statsd_testdrive
  ./out/host/linux-x86/bin/statsd_testdrive 10066

Bug: 144855217
Test: atest frameworks/base/services/tests/uiservicestests/src/com/android/server/notification
Change-Id: I6dcc9871f78298a8b213a051223c7316f8feefc5
Merged-In: I773378fc7cfb47a9f9c7495404ddafa63f39cfaf
2019-12-09 15:48:14 -05:00
Neil Fuller
c186f60e8c Merge "TimeDetector improvements" am: 6e3020490d
am: c72f796176

Change-Id: I76a5726953cd6dc7998e298c9d41e86a3b4f7c00
2019-12-06 04:08:26 -08:00
Neil Fuller
6e3020490d Merge "TimeDetector improvements" 2019-12-06 11:53:14 +00:00
Neil Fuller
ee036c7535 Merge "Add suggestManualTimeZoneSuggestion to the client" am: 63d5f12489
am: 2447fe6f69

Change-Id: I2ecb6991ee2fce6b4d79164f4fd7dd568042db4f
2019-12-05 06:09:31 -08:00
Neil Fuller
106f18a666 Add suggestManualTimeZoneSuggestion to the client
Add TimeZoneDetector.suggestManualTimeZone() to set the time zone
"manually" and switch the device policy manager code over to using
it.

Add RequiredPermission annotations to TimeZoneDetector while there.

Bug: 140712361
Test: treehugger only
Test: atest services/tests/servicestests/src/com/android/server/devicepolicy/DevicePolicyManagerTest.java
Change-Id: Id247fddfdd793732dd88294ee215eda37cd0be4c
2019-12-05 12:12:14 +00:00
Charles Munger
26bfde20d5 Merge "Deprecate IntentService" am: 17d1d950ec
am: bcdb5c84d3

Change-Id: I74aa58b9d94618b32069460cdbfe7f006c0e2d72
2019-12-04 14:29:38 -08:00
Charles Munger
17d1d950ec Merge "Deprecate IntentService" 2019-12-04 22:17:28 +00:00
Neil Fuller
57aaf1d427 Merge "Add a manual path for setting time zone" am: 7fcab2dba8
am: 076cd7aa3a

Change-Id: I03abce9eca7c3fa031a4a0b103cb0063ea4bb85b
2019-12-04 07:42:57 -08:00
Treehugger Robot
2b65793cd6 Merge "Merge Android10 QPR1 into AOSP master" 2019-12-03 23:15:02 +00:00
Neil Fuller
076cd7aa3a Merge "Add a manual path for setting time zone"
am: 7fcab2dba8

Change-Id: I4a77a647a01fb5b274a5bf819b1e22d4ec7d8219
2019-12-03 12:28:24 -08:00
Neil Fuller
0db51fc310 TimeDetector improvements
TimeDetector improvements for production code and tests. Many of these
are based on feedback given for TimeZoneDetector and to improve
consistency across the two.

1) Add a builder for PhoneTimeSuggestion, making it immutable (except
for debug info that doesn't affect behavior).
2) Improve debug logging.
3) Improve comments / annotations.

Test: atest android.app.timedetector
Test: atest com.android.server.timedetector
Bug: 140712361
Change-Id: Ibd0d357c536d512ffe4995c4e6560e483a260ae5
2019-12-03 20:22:05 +00:00
Neil Fuller
f807b4c364 Merge "Add a new time zone detection service" am: 7d8a624085
am: 256f4df4b6

Change-Id: Ie1b28c5cea14a23beac2e70eb7878f7f09461d6c
2019-12-03 08:42:57 -08:00
Neil Fuller
2c6d510e45 Add a manual path for setting time zone
Add a mechanism for suggesting the "manual" time zone setting to the
TimeZoneDetectorStrategy, e.g. for the settings app to use. This
involves various changes / renames to TimeZoneDetectorStrategy to
introduce a distinction between 3 things:
1) General detection code, applicable for anything that changes device
time zone.
2) Phone detection code, applicable for setting the device time zone
from phone signals.
3) Automatic detection code, applicable for setting the device time zone
automatically (of which telephony signals is currently the only example,
but could be joined by new things in future).

Adds tests for the new ManualTimeZoneSuggestion and makes improvements
to the existing tests for PhoneTimeZoneSuggestionTest.

Test: atest android.app.timezonedetector
Test: atest com.android.server.timezonedetector
Bug: 140712361
Change-Id: I9c3a18e47b157cccabda74855e5c91b45fa93b92
2019-12-03 16:38:03 +00:00
Neil Fuller
256f4df4b6 Merge "Add a new time zone detection service"
am: 7d8a624085

Change-Id: Ic30cd636b4863a507dda0bdb05e982ee411d936f
2019-12-03 08:30:50 -08:00
Neil Fuller
7d8a624085 Merge "Add a new time zone detection service" 2019-12-03 08:40:07 +00:00
Peter Wang
ed6d7e8b6e Merge "[Telephony Mainline] Exposed sendOrderedBroadcast" am: 471b839d02
am: 80a5a3db13

Change-Id: I0726f8853b46571976ae6f634e6a05265105bb3f
2019-12-02 13:54:51 -08:00
Peter Wang
80a5a3db13 Merge "[Telephony Mainline] Exposed sendOrderedBroadcast"
am: 471b839d02

Change-Id: Icd0230b880346a4ec573ccaa8d1adbade336f87a
2019-12-02 13:47:11 -08:00