summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author Jack Yu <jackyu@google.com> 2022-03-21 09:38:14 -0700
committer Jack Yu <jackyu@google.com> 2022-03-21 09:38:14 -0700
commit316939d210cde254231a4775c20e39863fbfc672 (patch)
treeddb308cfccf7469007c4d959dc3f6d27c08d604b
parent88000ab26eca2804c82fec7ff4108351f7ab5bf5 (diff)
Moved MVNO matching logic out of old data stack
Moved MVNO matching logic out of old data stack. There is no logic change here. Bug: 171809764 Test: Manual Change-Id: Ia7fc8042fe81a884bbab60c7a9bb6423f0401d65
-rw-r--r--telephony/java/android/telephony/TelephonyManager.java2
-rw-r--r--telephony/java/android/telephony/data/QualifiedNetworksService.java26
-rw-r--r--telephony/java/com/android/internal/telephony/ITelephony.aidl2
3 files changed, 22 insertions, 8 deletions
diff --git a/telephony/java/android/telephony/TelephonyManager.java b/telephony/java/android/telephony/TelephonyManager.java
index 3f430ab77df4..9d4caff111de 100644
--- a/telephony/java/android/telephony/TelephonyManager.java
+++ b/telephony/java/android/telephony/TelephonyManager.java
@@ -14924,7 +14924,7 @@ public class TelephonyManager {
}
ITelephony service = getITelephony();
if (service != null) {
- return service.isMvnoMatched(getSubId(), mvnoType, mvnoMatchData);
+ return service.isMvnoMatched(getSlotIndex(), mvnoType, mvnoMatchData);
}
} catch (RemoteException ex) {
Rlog.e(TAG, "Telephony#matchesCurrentSimOperator RemoteException" + ex);
diff --git a/telephony/java/android/telephony/data/QualifiedNetworksService.java b/telephony/java/android/telephony/data/QualifiedNetworksService.java
index 4e85d8926f11..a846088cec6c 100644
--- a/telephony/java/android/telephony/data/QualifiedNetworksService.java
+++ b/telephony/java/android/telephony/data/QualifiedNetworksService.java
@@ -129,17 +129,31 @@ public abstract class QualifiedNetworksService extends Service {
}
/**
- * Update the qualified networks list. Network availability provider must invoke this method
- * whenever the qualified networks changes. If this method is never invoked for certain
- * APN types, then frameworks will always use the default (i.e. cellular) data and network
- * service.
+ * Update the suggested qualified networks list. Network availability provider must invoke
+ * this method whenever the suggested qualified networks changes. If this method is never
+ * invoked for certain APN types, then frameworks uses its own logic to determine the
+ * transport to setup the data network.
+ *
+ * For example, QNS can suggest frameworks to setup IMS on IWLAN by specifying
+ * {@link ApnSetting#TYPE_IMS} with a list containing single element
+ * {@link AccessNetworkType#IWLAN}.
+ *
+ * Or if QNS consider multiple access networks are qualified for certain APN type, it can
+ * suggest frameworks by specifying the APN type with multiple elements in the list like
+ * {{@link AccessNetworkType#EUTRAN}, {@link AccessNetworkType#IWLAN}}. Frameworks will then
+ * first attempt to setup data on LTE network. If the device moves from LTE to UMTS, then
+ * frameworks can perform handover the data network to the second preferred access network
+ * if available.
+ *
+ * If the {@code qualifiedNetworkTypes} list is empty, it means QNS has no suggestion to the
+ * frameworks, and frameworks will decide the transport to setup the data network.
*
* @param apnTypes APN types of the qualified networks. This must be a bitmask combination
* of {@link ApnType}.
* @param qualifiedNetworkTypes List of network types which are qualified for data
* connection setup for {@link @apnType} in the preferred order. Each element in the list
- * is a {@link AccessNetworkType}. An empty list indicates no networks are qualified
- * for data setup.
+ * is a {@link AccessNetworkType}. Note that {@link AccessNetworkType#UNKNOWN} is not a
+ * valid input here.
*/
public final void updateQualifiedNetworkTypes(
@ApnType int apnTypes, @NonNull List<Integer> qualifiedNetworkTypes) {
diff --git a/telephony/java/com/android/internal/telephony/ITelephony.aidl b/telephony/java/com/android/internal/telephony/ITelephony.aidl
index a5e2c1f83939..9d8cb8aa46bc 100644
--- a/telephony/java/com/android/internal/telephony/ITelephony.aidl
+++ b/telephony/java/com/android/internal/telephony/ITelephony.aidl
@@ -2142,7 +2142,7 @@ interface ITelephony {
List<RadioAccessSpecifier> getSystemSelectionChannels(int subId);
- boolean isMvnoMatched(int subId, int mvnoType, String mvnoMatchData);
+ boolean isMvnoMatched(int slotIndex, int mvnoType, String mvnoMatchData);
/**
* Enqueue a pending sms Consumer, which will answer with the user specified selection for an