Commit Graph

11575 Commits

Author SHA1 Message Date
Benedict Wong
1cdff0cb4f Merge "Revert "Revert "Listen for individual subscription mobile data toggles""" am: ab7f5b533d am: 1ff62d0578
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1949076

Change-Id: I3df0695929bfcdd60225aacb1b31871eb8cf3b4b
2022-01-20 05:35:44 +00:00
Junyu Lai
385a5e8cc0 Merge changes I16418791,I210f5ddc am: b52609172e am: 86811b5fba
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1948617

Change-Id: Ib2a5252323f702e7d0d9847558e5b4da16703f29
2022-01-20 05:35:00 +00:00
Benedict Wong
ab7f5b533d Merge "Revert "Revert "Listen for individual subscription mobile data toggles""" 2022-01-19 16:51:09 +00:00
Junyu Lai
b52609172e Merge changes I16418791,I210f5ddc
* changes:
  [MS37.1] Expose APIs which is used by NPMS
  [MS55] Remove INetworkStats dependency from DataIdleTest
2022-01-19 07:08:15 +00:00
Junyu Lai
90cd83a0d2 [MS55] Remove INetworkStats dependency from DataIdleTest
Replace binder call with NetworkStatsManager Apis.

Test: atest DataIdleTest
Bug: 204830222
Change-Id: I210f5ddc4c14c88253ce442292a1734091621ad8
2022-01-19 07:01:49 +00:00
Benedict Wong
83bdc37516 Merge changes I61c84693,I929428f7 am: e6b79e2923 am: d00c6818dd
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1925501

Change-Id: I5e2ee0259f73c43f93049dbd8ab369a708d31112
2022-01-14 17:42:44 +00:00
Benedict Wong
e0606dfb49 Revert "Revert "Listen for individual subscription mobile data toggles""
This reverts commit f598641d7f.

Reason for revert: Build breakage could not possibly have been th caused by the initial CL. Cause was a String index overflow "Caused by: com.android.tools.r8.internal.du: String-index overflow."

Tested with local build of aosp-master/full-eng, completes successfully.
Change-Id: I207372c9513b450cf246874ba1d1e98dbd147f27
2022-01-14 02:20:59 +00:00
Giuliano Procida
d3cdf982ef Merge "Revert "Listen for individual subscription mobile data toggles"" am: 2453899e69 am: e2cf4c3a92
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1948456

Change-Id: I0a72a9930bbb4ad0f1a3d6f239c51e6ed32b365a
2022-01-13 14:12:51 +00:00
Joseph Jang
f598641d7f Revert "Listen for individual subscription mobile data toggles"
This reverts commit 66896667a6.

Reason for revert: <Suspect cause the build break report by b/214340258>

Change-Id: If8ddbfe8a0a8d445c4971572cf3301ebbb816347
2022-01-13 10:40:45 +00:00
Benedict Wong
ed6378433f Merge "Listen for individual subscription mobile data toggles" am: 92890dc5d6 am: c5d9e8120c
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1947700

Change-Id: Ic7892d965cf08677e8e55f8e9512fa1ba7fa713e
2022-01-13 07:32:40 +00:00
Benedict Wong
ee22e0d57d Add minimum required bandwidth to network templates
This change adds a minimum required bandwidth to the VCN network
templates, ensuring that a minimum bar of throughput can be required of
underlying networks.

Bug: 211008106
Test: atest FrameworksVcnTests
Change-Id: I929428f75e5e543966a03061d13f300dd8b0956f
2022-01-13 05:35:50 +00:00
Benedict Wong
66896667a6 Listen for individual subscription mobile data toggles
This change ensures that the VCN listens for changes on a
per-subscription basis. In the DSDS case, the
Settings.Global.MOBILE_DATA toggles is insufficient, as the toggles for
individual subscriptions are changed instead of the global toggle.

Without this patch, the VCN may ignore changes in the user toggles, and
continue providing data service even after user data is disabled.
Similarly, it may fail to bring up a VCN when user data is re-enabled.

Bug: 214247774
Test: atest FrameworksVcnTests
Change-Id: I1e84c25f48eab90dca163eda809fc11d5d21bc31
2022-01-13 01:58:01 +00:00
Benedict Wong
1cf64f23de Merge changes Ib7d51cf1,I92bd2831 am: 179826efdc am: 934206376c
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1909600

Change-Id: Ia6b0f0a98764917afe1e5e341262ca223109402d
2022-01-12 06:04:49 +00:00
Benedict Wong
179826efdc Merge changes Ib7d51cf1,I92bd2831
* changes:
  Expose APIs to configure underlying network priority
  Update setter/getters to configure underlying network priority
2022-01-12 05:21:03 +00:00
Benedict Wong
6f69b1908b Merge changes Ia5022310,Ia4529d08 am: bdbdbe19f8 am: 6dfbce3760
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1939996

Change-Id: Icf59e763c8161dca30796495f4597327ddc0f980
2022-01-08 02:20:48 +00:00
Benedict Wong
bdbdbe19f8 Merge changes Ia5022310,Ia4529d08
* changes:
  Remove VCN Carrier Privilege grace period
  Update TelephonySubscriptionTracker to use CarrierPrivilegesListener
2022-01-08 01:43:17 +00:00
Yan Yan
4b5fa75804 Merge "Rename VcnUnderlyingNetworkPrioirty to VcnUnderlyingNetworkTemplate" am: 60ad179dff am: 6ca0ac41d5
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1923190

Change-Id: I58517a6774a1544fe0e4bea60cbd88681297a83a
2022-01-07 23:21:35 +00:00
Benedict Wong
fb4a590dbc Remove VCN Carrier Privilege grace period
This change removes the grace period after the VCN is notified that a
provisioning app is no longer carrier privileged. This is due to the
switch to use CarrierPrivilegesTracker, which inherently has the
identical grace period.

This both simplifies the code, as well as removes some edge cases. As
such, tests for the delay before VCN tears down are no longer necessary.

Bug: 183554244
Test: atest FrameworksVcnTests
Change-Id: Ia50223108e45eeaedc860adf5e29a6ea459d956f
2022-01-07 22:11:26 +00:00
Benedict Wong
31d56f8298 Update TelephonySubscriptionTracker to use CarrierPrivilegesListener
This change adds use for CarrierPrivilegesListener to use the callbacks
as triggers to re-check carrier privileges. For simplicity, the carrier
privileges returned by the callback are not used, as it requires an
additional layer of caching. Instead, a query is performed, which
should hit a cache in the CarrierPrivilegesTracker, thus not be
performance-sensitive.

Bug: 183554244
Test: atest FrameworksVcnTests
Change-Id: Ia4529d087ee7f0deca7101c6849183ba7267c067
2022-01-07 22:11:22 +00:00
Yan Yan
451df7d904 Expose APIs to configure underlying network priority
This commit expose VcnUnderlyingNetworkTemplate classes
and methods to configure those objects in VcnGatewayConnectionConfig.

Those APIs allow callers to configure the underlying network priority
for VCN gateway when VCN is doing route selection. Callers can
construct VcnUnderlyingNeworkTemplate with network requirements and
then set VcnUnderlyingNeworkTemplate list from most preffered to least
preffered in VcnGatewayConnectionConfig.

Bug: 205343355
CTS-Coverage-Bug: 209498272
Test: atest FrameworksVcnTests, CtsVcnTestCases
Test: make update-api
Change-Id: Ib7d51cf1ce562a1acbcb767ec569d7e11c861a1d
2022-01-06 14:51:54 -08:00
Yan Yan
1161a591e7 Update setter/getters to configure underlying network priority
- Update setters for configuring meteredness, roaming and
  opportunistic to take an int instead of a boolean
- Update NetworkPriorityClassifier and tests accordingly

Bug: 206044122
Test: atest FrameworksVcnTests, CtsVcnTestCases
Change-Id: I92bd2831cc42d634d73b842c42d18fa93a4ed46c
2022-01-06 10:52:39 -08:00
Yan Yan
a9eec89e4b Rename VcnUnderlyingNetworkPrioirty to VcnUnderlyingNetworkTemplate
Rename the classes' names as well as the test files.

Bug: 206044122
Test: atest FrameworksVcnTests, CtsVcnTestCases
Change-Id: I19d13acf0e46921a7254a39dff2af332c36ab2b2
2022-01-06 10:52:26 -08:00
Alan Stokes
1f0e7adc23 Merge "Simplify ApexInfo classpath info" am: 3281d1b876 am: 045526da15
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1931078

Change-Id: I4ac42b0e9f5e7aeb3498c93af78663313e57506a
2022-01-05 09:22:48 +00:00
Alan Stokes
cd0705ed49 Simplify ApexInfo classpath info
Stop differentiating between the different ways an APEX can contribute
to derive_classpath - it makes no difference for the use cases, and it
doesn't scale if new environment variables are added.

Bug: 210472252
Test: atest ComposTestCase
Change-Id: I9256a6b5cc3689a8d61d51e8eb8d8c3f475172aa
2022-01-04 09:19:00 +00:00
Treehugger Robot
17506ed19f Merge "Support parsing VcnGatewayConnectionConfig without UnderlyingNetworkPriorities" am: 1a0f225c83 am: b3a9bce506
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1915377

Change-Id: I5db17a735ba43fe3e75eb244dc9c78ec42b91a19
2021-12-09 02:31:36 +00:00
Treehugger Robot
b3a9bce506 Merge "Support parsing VcnGatewayConnectionConfig without UnderlyingNetworkPriorities" am: 1a0f225c83
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1915377

Change-Id: I45c09a92c06df520711b935f3fdf9b096125953a
2021-12-09 02:15:28 +00:00
Treehugger Robot
1a0f225c83 Merge "Support parsing VcnGatewayConnectionConfig without UnderlyingNetworkPriorities" 2021-12-09 01:56:52 +00:00
Yan Yan
eaba1a12dc Merge "Update #hashCode & #equals with mUnderlyingNetworkPriorities" am: 9df3f48cb0 am: dcd0583719
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1914192

Change-Id: Ie62ecddeaff0a0b2e5448df4a50777a43ffdeed9
2021-12-08 23:20:08 +00:00
Yan Yan
dcd0583719 Merge "Update #hashCode & #equals with mUnderlyingNetworkPriorities" am: 9df3f48cb0
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1914192

Change-Id: I03475260c5dfa8f3e6f947f8939c0e75ca4459a6
2021-12-08 22:54:18 +00:00
Yan Yan
eae9b5d0c4 Support parsing VcnGatewayConnectionConfig without UnderlyingNetworkPriorities
This commit fixes the NullPointerException issue in converting a
PersistableBundle without UnderlyingNetworkPriorities to a
VcnGatewayConnectionConfig, by adding a null check and building
the VcnGatewayConnectionConfig with the default
UnderlyingNetworkPriority list.

Bug: 209142575
Test: atest FrameworksVcnTests (new tests), CtsVcnTestCases
Change-Id: I888d2994c86ba250c3fc9ee1851dccb5e6ef3e77
2021-12-08 12:23:28 -08:00
Yan Yan
9df3f48cb0 Merge "Update #hashCode & #equals with mUnderlyingNetworkPriorities" 2021-12-08 20:15:08 +00:00
Yan Yan
d3a7de1333 Update #hashCode & #equals with mUnderlyingNetworkPriorities
Update VcnGatewayConnectionConfig to consider
mUnderlyingNetworkPriorities in #hashCode and #equals methods

Rename #setAllowedPlmnIds and #getAllowedPlmnIds
to #setAllowedOperatorPlmnIds and #getAllowedOperatorPlmnIds

Bug: 206044122
Test: atest FrameworksVcnTests(new tests), CtsVcnTestCases
Change-Id: Id16d88024bbb7ef275da0304f2dde1413a18de10
2021-12-07 19:18:05 -08:00
Yan Yan
6d347ca8f6 Merge "Calculate priority based on caller configurations" am: 36a25527b4 am: 1f79b0cb09
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1906130

Change-Id: I31b1e5c63735ad7e29aad0491920b75f8a3cab0e
2021-12-07 18:52:22 +00:00
Yan Yan
1f79b0cb09 Merge "Calculate priority based on caller configurations" am: 36a25527b4
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1906130

Change-Id: I3817a344247104eb4056e949d09a123662fb6b65
2021-12-07 18:29:48 +00:00
Yan Yan
36a25527b4 Merge "Calculate priority based on caller configurations" 2021-12-07 18:10:47 +00:00
Yan Yan
738ed7b7b2 Calculate priority based on caller configurations
Update NetworkPriorityClassifier to calculate priority
according to the VcnUnderlyingNetworkPriority list
configured in VcnGatewayConnectionConfig

Bug: 206044122
Test: atest FrameworksVcnTests(new)
Test: atest CtsVcnTestCses
Change-Id: I55afa916af44db655a568aae2488877f2c177d59
2021-12-06 18:52:23 -08:00
Benedict Wong
2094058190 Merge "Immediately tear down VCN network when entering Airplane Mode" am: 4bfa0ebc53 am: 65fb393b79
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1908637

Change-Id: Ib76348295605ddb5db016c3e87863d6341d43177
2021-12-03 22:20:41 +00:00
Benedict Wong
65fb393b79 Merge "Immediately tear down VCN network when entering Airplane Mode" am: 4bfa0ebc53
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1908637

Change-Id: If3c9f4531c4ccdde8ad82786824a4b18c676be21
2021-12-03 21:47:22 +00:00
Benedict Wong
4bfa0ebc53 Merge "Immediately tear down VCN network when entering Airplane Mode" 2021-12-03 21:26:06 +00:00
Benedict Wong
c0e108a497 Immediately tear down VCN network when entering Airplane Mode
This change immediately tears down the VCN network if all underlying
networks are lost, and the device is in airplane mode. This ensures
consistency where other components may not understand the lingering
behavior of the VCN network

Bug: 207014742
Test: atest FrameworksVcnTests
Change-Id: Ib05f0c4255e847eed7d8623b35c5a7dfedd920d6
2021-12-03 01:48:21 +00:00
Yan Yan
88d3ad7f03 Merge changes I5cd2982f,Ia7f44c5f am: 8d6d8dcc4f am: 0ec026914a
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1902413

Change-Id: Iecc6f5557814fd635416a74e716e26571237e2f9
2021-12-02 20:35:14 +00:00
Yan Yan
0ec026914a Merge changes I5cd2982f,Ia7f44c5f am: 8d6d8dcc4f
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1902413

Change-Id: I3875c5edeeea2c996d643e9b4f0b027baa718c94
2021-12-02 20:20:19 +00:00
Yan Yan
8d6d8dcc4f Merge changes I5cd2982f,Ia7f44c5f
* changes:
  Support configuring VcnUnderlyingNetworkPriority in VcnGatwayConnectionConfig
  Create VcnCellUnderlyingNetworkPriority
2021-12-02 19:17:33 +00:00
Yan Yan
a3c6f3bb50 Merge "Create VcnUnderlyingNetworkPriority and the subclass for Wifi" am: cc09b29e59 am: 5d69a99ee6
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1901036

Change-Id: I9e78ef89a76449c3d5fc05f4a208683052ea572b
2021-12-02 03:50:22 +00:00
Yan Yan
5d69a99ee6 Merge "Create VcnUnderlyingNetworkPriority and the subclass for Wifi" am: cc09b29e59
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1901036

Change-Id: I0dca455cf6f2485faa84e926b6f8a318d5bd0f60
2021-12-02 03:26:30 +00:00
Yan Yan
fee736f47c Support configuring VcnUnderlyingNetworkPriority in VcnGatwayConnectionConfig
Bug: 206044122
Test: atest FrameworksVcnTests(new tests)
Test: atest CtsVcnTestCases
Change-Id: I5cd2982fcbfe5ce4ee36edb91f1f9f9b55d28d9a
2021-12-01 10:34:02 -08:00
Yan Yan
0376684dea Create VcnCellUnderlyingNetworkPriority
Create VcnCellUnderlyingNetworkPriority to allow VCN callers
to configure network prioritization.

Bug: 206044122
Test: atest FrameworksVcnTests(new tests)
Test: atest CtsVcnTestCases
Change-Id: Ia7f44c5f956ff75c39e20d9761f1bd5c987644ee
2021-12-01 10:33:49 -08:00
Yan Yan
cc09b29e59 Merge "Create VcnUnderlyingNetworkPriority and the subclass for Wifi" 2021-12-01 18:23:23 +00:00
Yan Yan
629cb6935e Create VcnUnderlyingNetworkPriority and the subclass for Wifi
Create VcnUnderlyingNetworkPriority and VcnWifiUnderlyingNetworkPriority
to allow VCN callers to configure network prioritization.

Bug: 206044122
Test: atest FrameworksVcnTests(new tests)
Test: atest CtsVcnTestCases
Change-Id: I540f826176c7085780be93e42fdbc3ff0ad537d7
2021-11-30 16:55:55 -08:00
Yan Yan
f86fbfb8ba Merge "Split out NetworkPriorityClassifier and UnderlyingNetworkRecord" am: 42bf9da702 am: 1baad423a7
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1901030

Change-Id: Iee6b801ecb6cc42c1bc2dff0de9b2e976624d823
2021-11-25 01:12:26 +00:00