summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author Sooraj Sasindran <sasindran@google.com> 2019-11-06 22:06:33 -0800
committer android-build-merger <android-build-merger@google.com> 2019-11-06 22:06:33 -0800
commitaf00f21c263ca3f83a58dc2efb231dfbe2854bcc (patch)
tree4de9e7e806a77dcd6102ed3a541ff2d70af5847b
parent35a357814caf764c8a168a93768f93791498ec5d (diff)
parenta115070c19503e46d1fade707d5718212a7d0d4b (diff)
Merge "Carrier config to switch data if primary is OOS" into qt-qpr1-dev
am: a115070c19 Change-Id: Ia92f65726f695efc13790a4160459cf6bbbae536
-rw-r--r--telephony/java/android/telephony/CarrierConfigManager.java25
1 files changed, 25 insertions, 0 deletions
diff --git a/telephony/java/android/telephony/CarrierConfigManager.java b/telephony/java/android/telephony/CarrierConfigManager.java
index bd3a2fbdce15..90a61f9aa207 100644
--- a/telephony/java/android/telephony/CarrierConfigManager.java
+++ b/telephony/java/android/telephony/CarrierConfigManager.java
@@ -2842,6 +2842,28 @@ public class CarrierConfigManager {
"ping_test_before_data_switch_bool";
/**
+ * Controls whether to switch data to primary from opportunistic subscription
+ * if primary is out of service. This control only affects system or 1st party app
+ * initiated data switch, but will not override data switch initiated by privileged carrier apps
+ * This carrier config is used to disable this feature.
+ * @hide
+ */
+ public static final String KEY_SWITCH_DATA_TO_PRIMARY_IF_PRIMARY_IS_OOS_BOOL =
+ "switch_data_to_primary_if_primary_is_oos_bool";
+
+ /**
+ * Controls back off time in milli seconds for switching back to
+ * opportunistic subscription. This time will be added to
+ * {@link CarrierConfigManager#KEY_OPPORTUNISTIC_NETWORK_DATA_SWITCH_HYSTERESIS_TIME_LONG} to
+ * determine hysteresis time if there is frequent switching
+ * (determined by system app or 1st party app) between primary and opportunistic
+ * subscription.
+ * @hide
+ */
+ public static final String KEY_OPPORTUNISTIC_NETWORK_BACKOFF_TIME_LONG =
+ "opportunistic_network_backoff_time_long";
+
+ /**
* Indicates zero or more emergency number prefix(es), because some carrier requires
* if users dial an emergency number address with a specific prefix, the combination of the
* prefix and the address is also a valid emergency number to dial. For example, an emergency
@@ -3648,6 +3670,9 @@ public class CarrierConfigManager {
/* Default value is 3 seconds. */
sDefaults.putLong(KEY_OPPORTUNISTIC_NETWORK_DATA_SWITCH_EXIT_HYSTERESIS_TIME_LONG, 3000);
sDefaults.putBoolean(KEY_PING_TEST_BEFORE_DATA_SWITCH_BOOL, true);
+ sDefaults.putBoolean(KEY_SWITCH_DATA_TO_PRIMARY_IF_PRIMARY_IS_OOS_BOOL, true);
+ /* Default value is 10 seconds. */
+ sDefaults.putLong(KEY_OPPORTUNISTIC_NETWORK_BACKOFF_TIME_LONG, 10000);
sDefaults.putAll(Gps.getDefaults());
sDefaults.putAll(Wifi.getDefaults());
sDefaults.putIntArray(KEY_CDMA_ENHANCED_ROAMING_INDICATOR_FOR_HOME_NETWORK_INT_ARRAY,