If the FSM gets restart while waiting for one of
SPN EFs results (i.e. a SIM refresh occurs after issuing
read EF_CPHS_SPN), it will re-initialize only after
receiving and discarding the unfinished SPN EF result.
bug:5499225
Change-Id: I715fc2feabdd03435903f7dcb785c8f0154619bc
We shouldn't tell people we're not connected due to roaming if it's really because
of data-disabled.
Use the data-disabled setting to decide if we should inform people about
data-discon due to roaming. Note this doesn't effect other notifications about roaming.
Also fix the data-enable/disable code to take roaming into account and clear/set the
roaming notification as needed (if data is enabled while we can't get on due to roaming
we should put up the roaming notifcation.. if data is disabled while that notification is
up we should take it down).
bug:5805666
Change-Id: I5c925dfdca4abc27e0034b113508df5719f04fae
We used to only prefer it when connecting for default connection purposes,
but it makes sense to use the preference for all apn types it supports.
bug:6377793
Change-Id: I8b26b77fc0787121749cce9d32303ab24cc72c75
When APN is edited, if authType and username are both not
set, authType should be set to NONE before setup of
data call.
The code today checks mApn.user for NULL, but if
user has edited APN the mApn.user field will be set
to an empty string.
Change the check of mApn.user to also take care of
this case.
Change-Id: I0e49247d46e1ba93da6dd951bbb75acc63fac73f
This reverts commit fe37acae729529b8bf3a3140fa397bddce42b1e0
There are two bugs that are weekend release blockers:
b/6357558
b/6357880
6357558 is easily fixed with:
https://android-git.corp.google.com/g/#/c/182228/
But there are still questions. Bug 6357880 has
unknown causes at the moment but this change is the
most likely candidate. So for today's pre-weekend
build we are reverting this change.
Allow some messages to be ignored and allow the subclass to
add additional information. In particular, the information
can be used to decode the msg.what to a string.
Change-Id: I4f53becc6f0cb77399f99702084efef9d8785d67
Non-system apps now require user confirmation before sending an SMS
to a short code that may potentially cost the user money. The number
is tested against regex patterns for short codes for the country
matching the user's SIM card or network. The user is warned if the
phone number is potentially or definitely a premium SMS number.
The regex patterns are loaded from core/res/res/xml/sms_short_codes.xml.
If the user's country is not found, then phone numbers of 5 digits or less
(excluding known emergency phone numbers) are considered to be potential
SMS short codes.
Command to run test cases:
$ runtest -c com.android.internal.telephony.SmsUsageMonitorShortCodeTest frameworks-telephony
Bug: 5513975
Change-Id: Ic0b483153390e974c632302f3061300bc2a2274a
Add code that updates the time zone whenever the country code
or time zone changes. In bug 6269708 the device initially
reported the mcc as 001 and then a short time later it got
the correct code, 311. This could cause the time zone to be
reported as America/Dawson instead of America/Los_Angeles.
Bug: 6269708
Change-Id: Ibfb40ea1158d3b99c121ed9960a1f0b1a45980bd
Don't trigger RuimRecords onReady so that it doesn't overwrite
mccmnc property value set by CdmaPhone in NV case.
Bug: 6153667
Change-Id: I2f25f6a69deecd085f11dbe1dbf752c2fd51cecb
To boost accurary and enhance capability of cell location api,
two new APIs, TelephonyManager.getAllCellInfo() and
TelephonyManager.listen(LISTEN_CELL_INFO), are added. Two new
Class, CellInfo and CellIdentity, are created.
This API change returns all information of one cell locaiton
at the same time. It also provides additional LTE and timestamp information.
Change-Id: I4d0f813107e625ec4ac88c8d980ffd171aa5fc30
This will dump the state of the telephony stack using:
adb shell dumpsys activity service android.phone.TelephonyDebugService
The service is located in packages/app/Phone and TelephonyDebugService
instantiates DebugService and calls its dump method when asked
via the dumpsys command above.
Change-Id: I4d34c741544cafdadce2532de8b9c117a4d435a5
- Move the class.
- Remove some TODOs mentioning this action : the class should belong to
telephony layer instead of to the Phone package
- Add private strings used in the class
Bug: 6252254
Change-Id: I0d4ca2f8e4d775004d146fe6f9c60165a94366a9
mIccCard is now be multi-thread safe but other similar
variables such as mIccRecords will be cleaned up in
the future and are no worse than before.
Change-Id: Ic2fc31af2575c2dc0bb30e7348dd9e76ec61e763
Refactor SMS Cell Broadcast support to enable receiving CMAS warning
notifications over CDMA. The CellBroadcastReceiver app must also be
updated with the corresponding change. All cell broadcasts are now
delivered as a Parcelable SmsCbMessage object in the "message" extra
of the SMS_CB_RECEIVED_ACTION or SMS_EMERGENCY_CB_RECEIVED_ACTION,
instead of as a GSM/UMTS "pdu" byte array.
Existing functionality for ETWS and CMAS alerts over GSM/UMTS continues
to be supported using the new radio-technology independent SmsCbMessage
and related objects. Test cases are added to verify that valid and
invalid broadcast data is handled appropriately.
Unit testing discovered a bug in the BitwiseOutputStream utility class
used by the added test cases. When the BitwiseOutputStream object must be
expanded (in the private possExpand() method), the mEnd field is not
updated to the new array size. This causes a new array to be allocated
on every new write, and for all data beyond the original array allocation
to be replaced with zeroes. Fixed by adding a line to possExpand() to
update mEnd. Added a test case to BitwiseStreamsTest to verify the fix.
Besides the test cases, BitwiseOutputStream is only used by BearerData in
two places, both of which allocate a sufficient initial buffer. So the
bug in BitwiseOutputStream is not critical to fix for normal operation,
but should be fixed so that the test cases using it function correctly.
Bug: 5856308
Change-Id: I201ecbf11607fd200aaae3cbb32561efabf65672
Bearer Independent Protocol (BIP) connections as defined in
ETSI TS 102 223 "Smart Cards; Card Application Toolkit (CAT) (Release 11)"
need to be able to establish data connections even when not provisioned.
This can occur when trying to provision on via and EVDO network.
Bug: 6110632
Change-Id: I85722e0ba2e2606ffcf2516b8f00be6ff5271adf
[issue 5963659]
Result:
There is no APN information for Cheers
Expected Result:
Mobile internet APN name for Cheers should be displayed
Change-Id: Iab29cfbd06ab15559048ced23136abae1fcab8f3
This is not perfect and only works if the CC is known via
the GSM radio and is only accurate if there is one time zone
per country. This does nothing to resolve time zone problems
for wifi only devices.
So this is a partial fix for bug 2896745
Bug: 2896745
Change-Id: I78f013836c4e4870b8b1016a8312f5adbe0d31c9
Remove notions of SimCard and RuimCard since they don't make sense
in the world of Uicc cards where each card can have multiple
3gpp and 3gpp2 subscriptions.
This change prepares code for the introduction of Uicc cards.
Change-Id: Ibab13004604f829328b73c177669b89ef97d3f25
Refactor SMS Cell Broadcast support to enable receiving CMAS warning
notifications over CDMA. The CellBroadcastReceiver app must also be
updated with the corresponding change. All cell broadcasts are now
delivered as a Parcelable SmsCbMessage object in the "message" extra
of the SMS_CB_RECEIVED_ACTION or SMS_EMERGENCY_CB_RECEIVED_ACTION,
instead of as a GSM/UMTS "pdu" byte array.
Existing functionality for ETWS and CMAS alerts over GSM/UMTS continues
to be supported using the new radio-technology independent SmsCbMessage
and related objects. Test cases are added to verify that valid and
invalid broadcast data is handled appropriately.
Unit testing discovered a bug in the BitwiseOutputStream utility class
used by the added test cases. When the BitwiseOutputStream object must be
expanded (in the private possExpand() method), the mEnd field is not
updated to the new array size. This causes a new array to be allocated
on every new write, and for all data beyond the original array allocation
to be replaced with zeroes. Fixed by adding a line to possExpand() to
update mEnd. Added a test case to BitwiseStreamsTest to verify the fix.
Besides the test cases, BitwiseOutputStream is only used by BearerData in
two places, both of which allocate a sufficient initial buffer. So the
bug in BitwiseOutputStream is not critical to fix for normal operation,
but should be fixed so that the test cases using it function correctly.
Bug: 5856308
Change-Id: Ie3e6af747976ce9b8a3e71e76fec71709cf86545
The racing condition happens between dial() returns and
the first GET_CURRENT_CALLS query gets handled.
If GET_CURRENT_CALLS gets handled before dial() finishs, the pendingMO can be set
to null in handlePollCalls() so that dial() will return null. This null connection causes
error in PhoneUtils.placeCall().
The Synchronized dial() and handlePollCalls() Methods will make sure the
dial() returns before the first GET_CURRENT_CALLS gets handled.
bug:6028290
Change-Id: I41b024760acb7dd13b342866180dffe3fdbe1c03
We have two sets of constants for network type. One used by the RIL can't
be changed without big pains with OEM/Radio vendors. The other has been published
as part of the framework and can't be easily changed either.
Separate the two so it's clear where one should be used versus the other.
bug:5717664
Change-Id: Ibf21f9165662e75557c7254fc9ad9a4870ba4af9
Backported from master, including a bug fix and a cdma enhancement.
Even if other people are sharing the connection (ie, carrier wants
default and tethered traffic on the same APN) stop using a carrier-
described APN when the tethering stops.
bug:5972599
Change-Id: I25e4831855e6b62c0c3ab3a6f4d4846aaee6ac50
Since CDMA doesn't use APN settings there was no place to say what a cdma
device's DUN connection would support, so by default normal device
originating traffic would be blocked on a tethering single-connection device.
With this change you can (via overlay) say that it supports everything
so mms and on-device browsing/email will still work even when on a dun connection.
The reason to allow both: some carriers will charge per byte for dun access
and so they don't want lots of non-tethering traffic used (costs the user alot)
but other carriers just use a dun connection to limit access to tethering, but
once there give unlimited data, so it makes sense to support everything there.
bug:5972599
Change-Id: I78fd7f3ac63c51a0560b659ed5ec219b10a93f8d
The LTE signal strength level is the smaller one
between lte rsrp level and lte snr level if both
rsrp and snr are valid.
The lte snr mapping are
Four bars: SNR >= 45
Three bars: 10 <= SNR < 45
Two bars: -30 <= SNR < 10
One bars: SNR < -30
No bars: No Service
The invalid value of lte snr is changed to INVALID_SNR
from -1, since -1 is a valid value of lte snr.
bug:5640958
Change-Id: If26aaba0c7fcc0fee3db488b5adfa02922f06715