Commit Graph

8256 Commits

Author SHA1 Message Date
Daniel Bright
81f2bbd435 Add CarrierConfig key to customize apn priority
clean cherry pick
Test: atest on com.android.internal.telephony.dataconnection
Test: Make phone call
Test: Send text message
Test: Hit websites on chrome
Test: Override pririties using carrier config using broadcast
Bug: 152324921
Merged-In: I259071334c135709fc98c989a9b7c8c35f449578
Merged-In: Ib2139a93768999c2a867e40fea8d86c0ce730130

Change-Id: Iaa0ef7d9e29e074c37abd9481c2cdd3e5ecc7cae
2020-05-05 16:11:04 -07:00
Brad Ebinger
8bf7a8487c Merge "Fix wrong log" 2020-05-04 19:08:01 +00:00
Nathan Harold
19e83aca9d Merge changes from topic "pick-sst-location-iwlan"
* changes:
  Update GlobalCellId during Un-parceling
  Make CellIdentity#getPlmn() Publicly Accessible
2020-05-04 16:11:28 +00:00
Taesu Lee
50e1ecc4ab Fix wrong log
Test: none

Signed-off-by: Taesu Lee <taesu82.lee@samsung.com>
Change-Id: I3c80c20e36cbe32d5941547bda095cded42d78c7
2020-05-04 12:25:05 +09:00
Nathan Harold
9ced05a8b0 Update GlobalCellId during Un-parceling
The Global Cell-ID is constructed from other
fields in each CellIdentity.

Currently, it is not stored during parceling.
Thus, after a CellId is parceled and unparceled
this value is being lost.

Do a quick fix to update the global Cell ID during
unparceling. A longer-term fix is to resolve the
layering violations that create the situation where
the global Cell ID is defined in the base class
but manipulated in the derived classes.

Fixes a broken unit test.

Bug: 154955167
Test: atest ServiceStateTrackerTest#testRatRatchet
Merged-In: I5c58322ebcec8886405e25e09754c7f154187efe
Change-Id: I5c58322ebcec8886405e25e09754c7f154187efe
(cherry picked from commit 3f7dfb8239)
2020-04-30 16:26:47 -07:00
Brad Ebinger
12df9e3d69 Merge "Using RegistrationManager was causing unintended public APIs" 2020-04-29 17:07:04 +00:00
Sarah Chin
86ef2bf419 Add carrier config for roaming meteredness
Test: atest DcTrackerTest, DataConnectionTest
Bug: 152541872
Change-Id: I07e9fd2cf42de8c6f924cda5e16aa6820baef4cd
Merged-In: I07e9fd2cf42de8c6f924cda5e16aa6820baef4cd
2020-04-28 12:29:25 -07:00
Sarah Chin
df6e608fca Merge "Add carrier configs for NR SA unmetered" 2020-04-28 19:23:47 +00:00
Xiangyu/Malcolm Chen
88fed59cc7 Merge "Add a @hide API to indicate 5G and DSDS conflict." 2020-04-28 18:14:04 +00:00
Hall Liu
61a728aebf Merge "Unhide and update documentation for DisconnectCause" 2020-04-28 17:57:53 +00:00
SongFerngWang
8893662fd5 For NR (non-standalone), use LTE signal strength as primary rule
There are two signal strengths, NR and LTE signal strength,
during NR (non-standalone). A lot of carriers' requirement define
UE show LTE signal strength on status bar during
NR (non-standalone).
Add a carrier config whether to use LTE signal strength as
primary during NR (non-standalone)

Bug: 152864241
Test: make pass.
Change-Id: Ib13d73719dace2d80aee5669181f4f934316ffd1
Merged-In: Ib13d73719dace2d80aee5669181f4f934316ffd1
(cherry picked from commit 68c58a57b0)
2020-04-28 05:36:15 +00:00
Rambo Wang
105fe9349a NR is lower priority than all other signal strengths
aosp/891956 introduced signal strengths support for NR. In the
method SignalStrength.getPrimary, NR is the lowest priority.
This is against the policy which is in the comment, saying
"prioritizing newer faster RATs".

Bug: 148634820
Test: atest com.android.internal.telephony.SignalStrengthTest
Change-Id: Ia9055c9e8cd8d09cdd3f101750c9f9cea983a9f8
Merged-In: Ia9055c9e8cd8d09cdd3f101750c9f9cea983a9f8
(cherry picked from commit 8e56e11eab)
2020-04-28 05:34:37 +00:00
Malcolm Chen
edaa0b780f Add a @hide API to indicate 5G and DSDS conflict.
Bug: 152786064
Test: build and manual
Change-Id: I79a8fda5b70a31acc365ebcbb03b73b20d2443fd
Merged-In: I79a8fda5b70a31acc365ebcbb03b73b20d2443fd
2020-04-27 18:27:16 -07:00
Brad Ebinger
0cb1eda634 Using RegistrationManager was causing unintended public APIs
Remove the dependency on this interface until it is intended
to be public.

Fixes: 153908410
Fixes: 155097858
Test: atest CtsTelephonyTestCases
Merged-In: Iad82b7d06738468861bd49164fbb4b4dafb8c014
Change-Id: Iad82b7d06738468861bd49164fbb4b4dafb8c014
2020-04-27 18:05:17 -07:00
Hall Liu
6884145ba3 Unhide and update documentation for DisconnectCause
Unhide several constants and update the documentation for
android.telephony.DisconnectCause to reflect where it's being used.

Fixes: 154826441
Test: build
Change-Id: Ib3177367519a704bb469bc494f686c96fb516b85
2020-04-27 17:57:17 -07:00
Nathan Harold
e69e5b0c9c Make CellIdentity#getPlmn() Publicly Accessible
Add support for telephony to access getPlmn().

Bug: 148111627
Test: compilation (trivial)
Merged-In: I5a79e5339a7e4e1351582f199559801069df0c76
Change-Id: I5a79e5339a7e4e1351582f199559801069df0c76
(cherry picked from commit 741d281c60)
2020-04-24 10:25:40 -07:00
Tyler Gunn
7cea5cddcb Merge "IMS: Explicit Call transfer APIS." 2020-04-24 16:29:51 +00:00
Sarah Chin
ede5991c1b Add carrier configs for NR SA unmetered
Test: atest DcTrackerTest
Bug: 153117651
Change-Id: I1543a7943d8bcd536ece5cb673b419e740086111
Merged-In: I1543a7943d8bcd536ece5cb673b419e740086111
2020-04-24 01:41:36 -07:00
Hall Liu
233ee8126c Merge "Expose android.telephony.DisconnectCause" 2020-04-22 23:44:02 +00:00
Tyler Gunn
bc3d4c82b0 Merge "Add carrier config to support local disconnect of empty IMS conference." 2020-04-22 21:11:20 +00:00
Tyler Gunn
bd7e9c42d7 Merge "Add carrier config to indicate if cep is supported on peer." 2020-04-22 19:55:47 +00:00
Tyler Gunn
ba1878f55a Merge "Fix potential issue where sub info change listener is not registered." 2020-04-22 19:43:55 +00:00
Tyler Gunn
cc0dcc6ad6 Add carrier config to support local disconnect of empty IMS conference.
Adding carrier config key to support ability to locally disconnect an
empty IMS conference.  The network normally does this, but there             are some
carriers which rely on the device to do it.

Test: Add unit test to verify local disconnect when participant count is
zero.
Test: Use conference event package test cmd/intents to inject test CEP to
simulate a conference dropped to 0 participants.  Verify IMS conference is
disconnected.
Bug: 151707520
Fixes: 154245549
Merged-In: If6fb25b669a74e7e586736c04101a42ab6adcffe
Change-Id: Id7238bc668e6d6d2d7a04a8696263b260d6b6fd8
2020-04-22 11:26:25 -07:00
Tyler Gunn
559ac652d0 Add carrier config to indicate if cep is supported on peer.
Adding new carrier config option to indicate if conference event package
data is supported on the conference peer.  We already have an option for
the conference host.  This new option is used to indicate when the peer
can or cannot support the CEP data.  When not supported, even if the
network provides CEP data, it is ignored by the device.

Test: Manual testing using test intents.
Test: Added unit tests for these cases.
Bug: 150860282
Fixes: 154245604
Merged-In: I47b5e49acf08e085ea23e21a5f6b2d5a5d00bc09
Change-Id: Ib8d8f171699f21f45b0ce2eec2dbe75d7466b76a
2020-04-22 10:51:42 -07:00
Tyler Gunn
76ab5fb247 Fix potential issue where sub info change listener is not registered.
SubscriptionManager#addOnSubscriptionsChangedListener can fail to
register a listener if the TELEPHONY_REGISTRY system service is not up.
Currently this is just silently ignored.

Adding a callback method on the listener to notify the registrant that the
listener failed to be registered, and adding exponential backoff code in
TelecomAccountRegistry to retry registration.

Test: Manual; edited code in Subscriptionmanager to fail the first attempts
to add a listener for TelecomAccountRegistry.  Verified the backoff took
place and registration still occurred for the listener.
Test: Tried to write a mockito test but gave up because this code has
far too many intertwined dependencies and is not inherently testable
Bug: 152217039
Fixes: 153376310

Change-Id: Icf3133cdeca526979cb621f29659b880127b680a
Merged-In: Ib032072dcfd2d3d5e700e380af08b7b3142ebb8e
2020-04-22 15:42:35 +00:00
Sonalika Paul
10d67ed1b8 IMS: Explicit Call transfer APIS.
Test: Manual
Bug: 62170207
Change-Id: I136ffb1d5b4df9de9be0406d6d5ebd33ef7a97ac
2020-04-22 15:50:24 +05:30
Hall Liu
04ca56ddc6 Expose android.telephony.DisconnectCause
Expose these constants since they're referred to by a public carrier
config key.

Fixes: 145663507
Test: compile
Change-Id: I276761170b3cf5d740f7dbe945834934082a1428
Merged-In: I276761170b3cf5d740f7dbe945834934082a1428
2020-04-22 00:35:38 +00:00
Jack Yu
506655294e Merge "Renamed DisplayInfo to TelephonyDisplayInfo" 2020-04-20 21:16:17 +00:00
Sarah Chin
1f0a4d7261 Merge "Add rebroadcast extra to CARRIER_CONFIG_CHANGED" 2020-04-20 18:27:35 +00:00
Jack Yu
ecfb37b868 Renamed DisplayInfo to TelephonyDisplayInfo
To reduce ambiguity with android.view.DisplayInfo.

Test: Telephony sanity tests + unit tests
Bug: 151101989
Merged-In: Ic507b6bf082ca5510ff6d1dcde501f5be9ef074f
Change-Id: Ic507b6bf082ca5510ff6d1dcde501f5be9ef074f
(cherry picked from commit ac3ca33567)
2020-04-20 09:22:33 -07:00
Mingming Cai
81a5d6ac65 Make MNC length hidden public
Make CellIdentity.MNC_MIN_LENGTH and CellIdentity.MNC_MAX_LENGTH
hidden public to support IccRecords changes.

Bug: 152518548
Test: make
Change-Id: Ic253a6bbbf07e4ce62a7ea25ca67dff54e2c67c8
Merged-In: Ic253a6bbbf07e4ce62a7ea25ca67dff54e2c67c8
(cherry picked from commit 3f9e9edb8e)
2020-04-17 17:14:51 -07:00
Jack Yu
0b8a2182ca Merge "Set legacy MTU field for backward compatibility" 2020-04-17 01:14:48 +00:00
Jordan Liu
e9cd9bd1fc Merge "Implement #equals in Geometries subclasses" 2020-04-16 22:13:17 +00:00
Jordan Liu
def1360b0b Implement #equals in Geometries subclasses
Bug: 148482334
Test: atest CbGeoUtilsTest
Change-Id: Ifc9aeaf378ac3221fc25690ed6ce33108cf2f56f
Merged-In: Ifc9aeaf378ac3221fc25690ed6ce33108cf2f56f
2020-04-16 14:04:11 -07:00
Jack Yu
1992920e74 Set legacy MTU field for backward compatibility
For IWLAN, MTU is not negotiated as part of the RA. The interface
MTU is still necessary here to ensure full backward compatibility.
To workaround this, we set legacy mtu field with the larger value
of mtu v4 and mtu v6.

Fix: 153470573
Test: FrameworkTelephonyTests
Merged-In: I0671618817a295cc4e9c75df17501de338dbe155
Change-Id: I0671618817a295cc4e9c75df17501de338dbe155
(cherry picked from commit 8d41fd3a92)
2020-04-15 20:17:39 -07:00
Sarah Chin
3ff26a3bed Update Bands API
Test: build
Bug: 151842542
Change-Id: Ib033758d469b9b485eb7cce6c026b5a649e6a6fa
Merged-In: Ib033758d469b9b485eb7cce6c026b5a649e6a6fa
2020-04-14 18:07:55 -07:00
Amit Mahajan
c0f6f60d8e Merge changes If4e8e87c,Ie8e48422,Iab4974f9
* changes:
  Exposing TelephonyManager.isIccLockEnabled as a system API.
  Un-expose LISTEN_ALWAYS_REPORTED_SIGNAL_STRENGTH for R.
  Un-expose ACTION_SERVICE_PROVIDERS_UPDATED.
2020-04-15 00:08:01 +00:00
Treehugger Robot
f892c9a6a5 Merge "Add unit test for ClosedSubscriberGroupInfo" 2020-04-14 23:13:47 +00:00
Amit Mahajan
f360f2cf05 Exposing TelephonyManager.isIccLockEnabled as a system API.
This was recently removed as part of un-exposing telephony
mainline related APIs (b/146983487), but being added back in R as GMSCore
already uses it (b/151742706).

Test: TH
Bug: 151742706
Bug: 146983487
Merged-in: If4e8e87c7dfbb261ee3abfec2a4774980c24d0c2
Change-Id: If4e8e87c7dfbb261ee3abfec2a4774980c24d0c2
(cherry picked from commit 1c6679a3ad)
2020-04-14 14:41:56 -07:00
Amit Mahajan
6b2eddec32 Un-expose ACTION_SERVICE_PROVIDERS_UPDATED.
Will be exposed/reworked on in S.

Test: basic sanity
Bug: 147921202
Merged-in: Iab4974f9cd7cecde1ef6eba35c320101a288b481
Change-Id: Iab4974f9cd7cecde1ef6eba35c320101a288b481
(cherry picked from commit 13a8d14fcd)
2020-04-14 14:28:01 -07:00
Robert Greenwalt
1ace38473c Move getMsisdn and getLine1Number to READ_PHONE_NUMBERS
This is done to get dangerous stuff off the READ_PHONE_STATE permission.
Also keeping READ_PHONE_STATE for apps targeting old SDK versions.
Refactored getPhoneNumber to allow READ_PHONE_STATE pre-R

Bug: 136160623
Test: atest SubInfoControllerTest, TelephonyPermissionsTest
Change-Id: I5c0adcbe432ffcbb22ac8959792ee60da7039f15
Merged-In: I5c0adcbe432ffcbb22ac8959792ee60da7039f15
2020-04-14 11:41:53 -07:00
Sarah Chin
2b59d5396e Add rebroadcast extra to CARRIER_CONFIG_CHANGED
Test: manual verify broadcast sent with/without extra
Bug: 152149072
Change-Id: Ib5d9c6f645f1b9b8deb9f896ecd67c68cb29dc17
Merged-In: Ib5d9c6f645f1b9b8deb9f896ecd67c68cb29dc17
2020-04-14 10:39:27 -07:00
Calvin Pan
f2da40ad07 Merge changes from topic "DEFAULT_PREFERRED_NETWORK_MODE"
* changes:
  Make DEFAULT_PREFERRED_NETWORK_MODE @hide for now
  Add new system API constant DEFAULT_PREFERRED_NETWORK_MODE
  Remove usage of Telephonymanager getDefault() hidden API
  SettingsProvider: use sysprop as API for telephony
2020-04-14 02:13:14 +00:00
Rambo Wang
8b1006614d Add unit test for ClosedSubscriberGroupInfo
Compare homeNodebName based on values instead of references.

Bug: 151976726
Test: atest ClosedSubscriberGroupInfoTest
Merged-In: I15557e673c8b6842a6fc28b6ea814323652a00b8
Change-Id: I15557e673c8b6842a6fc28b6ea814323652a00b8
(cherry picked from commit e0c4e40512)
2020-04-13 12:58:11 -07:00
Hall Liu
cc8b84c221 Merge changes from topic "phonestatelistener-limit-rvc-dev"
* changes:
  Add gating, logging for PhoneStateListener's limit
  Institute limit on PhoneStateListener
2020-04-11 00:36:13 +00:00
Jayachandran C
a6a4858079 Make DEFAULT_PREFERRED_NETWORK_MODE @hide for now
This API also needs to expose the possible values which would need more
work hence we will drop this for now and re-work for next release

This CL also fixes a bug to use correct RIL constant

Bug: 148514283
Bug: 148484234
Test: Verified that the eSIM works on DSDS
      atest packages/services/Telephony/tests/
      atest frameworks/opt/telephony/tests/telephonytests/

Change-Id: Ifd7b17cc2445c9cbe4c6ba688838a1b07eb13599
Merged-In: Ifd7b17cc2445c9cbe4c6ba688838a1b07eb13599
2020-04-10 07:07:35 +00:00
Jayachandran C
9160670b18 Add new system API constant DEFAULT_PREFERRED_NETWORK_MODE
Bug: 140768340
Test: Following tests have been done
atest packages/services/Telephony/tests/
atest frameworks/opt/telephony/tests/telephonytests/
Manual sanity to check basic telephony

Change-Id: Ia114e4546d88e294ed37b6632a1eae6a06fbf7bc
Merged-In: Ia114e4546d88e294ed37b6632a1eae6a06fbf7bc
2020-04-10 07:07:16 +00:00
Tyler Gunn
9a3201583a Hide car barring with password API.
Not needed in R.

Test: Build APIs
Bug: 148184879
Change-Id: I036980c2e565bf4f84e51b028d0b6938b7afff97
2020-04-08 15:42:39 -07:00
Cody Kesting
7badb011b3 Merge "Make UiccAccessRule certificate utils accessible." 2020-04-08 16:19:38 +00:00
Xiangyu/Malcolm Chen
2641543774 Merge "multiSimAllowed should be consistent with max active modem property." 2020-04-08 00:50:17 +00:00