diff options
author | Wink Saville <wink@google.com> | 2014-12-19 17:58:50 +0000 |
---|---|---|
committer | Android (Google) Code Review <android-gerrit@google.com> | 2014-12-19 17:58:52 +0000 |
commit | 63c79ce4bfef7e8de7939be3de8a539938d9fc4e (patch) | |
tree | ecfc31d86debbe54812327282f2dd7a91c1c711b /telephony/java | |
parent | 8d24fe235a6e8f44e32a56a05ab36ed5b35385df (diff) | |
parent | 482b4246c25164f8a55c473acec1d2ca9a9e08d2 (diff) | |
download | frameworks_base-63c79ce4bfef7e8de7939be3de8a539938d9fc4e.zip frameworks_base-63c79ce4bfef7e8de7939be3de8a539938d9fc4e.tar.gz frameworks_base-63c79ce4bfef7e8de7939be3de8a539938d9fc4e.tar.bz2 |
Merge "Update mapping between RAF and Network Type." into lmp-mr1-dev
Diffstat (limited to 'telephony/java')
-rw-r--r-- | telephony/java/android/telephony/RadioAccessFamily.java | 29 |
1 files changed, 26 insertions, 3 deletions
diff --git a/telephony/java/android/telephony/RadioAccessFamily.java b/telephony/java/android/telephony/RadioAccessFamily.java index 734fc68..0820bfa 100644 --- a/telephony/java/android/telephony/RadioAccessFamily.java +++ b/telephony/java/android/telephony/RadioAccessFamily.java @@ -136,13 +136,36 @@ public class RadioAccessFamily implements Parcelable { }; public static int getRafFromNetworkType(int type) { - // TODO map from RILConstants.NETWORK_TYPE_* to RAF_* switch (type) { case RILConstants.NETWORK_MODE_WCDMA_PREF: - case RILConstants.NETWORK_MODE_GSM_UMTS: - return RAF_UMTS | RAF_GSM; + return RAF_GSM | RAF_UMTS | RAF_HSUPA | RAF_HSDPA | RAF_HSPA | RAF_HSPAP; case RILConstants.NETWORK_MODE_GSM_ONLY: return RAF_GSM; + case RILConstants.NETWORK_MODE_WCDMA_ONLY: + return RAF_UMTS | RAF_HSUPA | RAF_HSDPA | RAF_HSPA | RAF_HSPAP; + case RILConstants.NETWORK_MODE_GSM_UMTS: + return RAF_GSM | RAF_UMTS | RAF_HSUPA | RAF_HSDPA | RAF_HSPA | RAF_HSPAP; + case RILConstants.NETWORK_MODE_CDMA: + return RAF_EVDO_0 | RAF_EVDO_A | RAF_EVDO_B | RAF_IS95A | RAF_IS95B | RAF_1xRTT; + case RILConstants.NETWORK_MODE_LTE_CDMA_EVDO: + return RAF_EVDO_0 | RAF_EVDO_A | RAF_EVDO_B | RAF_IS95A | RAF_IS95B | RAF_1xRTT + | RAF_EHRPD; + case RILConstants.NETWORK_MODE_LTE_GSM_WCDMA: + return RAF_GSM | RAF_UMTS | RAF_LTE | RAF_HSUPA | RAF_HSDPA | RAF_HSPA | RAF_HSPAP; + case RILConstants.NETWORK_MODE_LTE_CDMA_EVDO_GSM_WCDMA: + return RAF_GSM | RAF_UMTS | RAF_LTE | RAF_EVDO_0 | RAF_EVDO_A | RAF_EVDO_B + | RAF_IS95A | RAF_IS95B | RAF_1xRTT | RAF_EHRPD | RAF_HSUPA | RAF_HSDPA + | RAF_HSPA | RAF_HSPAP; + case RILConstants.NETWORK_MODE_LTE_ONLY: + return RAF_LTE; + case RILConstants.NETWORK_MODE_LTE_WCDMA: + return RAF_LTE | RAF_UMTS | RAF_HSUPA | RAF_HSDPA | RAF_HSPA | RAF_HSPAP; + case RILConstants.NETWORK_MODE_CDMA_NO_EVDO: + return RAF_UNKNOWN; + case RILConstants.NETWORK_MODE_EVDO_NO_CDMA: + return RAF_UNKNOWN; + case RILConstants.NETWORK_MODE_GLOBAL: + return RAF_UNKNOWN; default: return RAF_UNKNOWN; } |