Commit Graph

442 Commits

Author SHA1 Message Date
Mark Chien
044a749f37 Test tethering log dump am: c96fbe0abe
Change-Id: If48c35a4dde54b4bdd44703f3df6338267b1b542
2020-05-07 08:19:10 +00:00
Mark Chien
c96fbe0abe Test tethering log dump
Bug: 145490751
Test: atest TetheringTests
Merged-In: I01fc6969041711f7a15880144ee5eac591086ecd
Change-Id: I01fc6969041711f7a15880144ee5eac591086ecd
2020-05-07 06:44:43 +00:00
Anton Hansson
b79d07bb0e Merge "Enable api lint and check_last_api for modules" into rvc-dev am: 3f34b58cee
Change-Id: Iae3492e765d2f1c88b8c587e93b268a4c8aa9907
2020-05-06 09:30:31 +00:00
Anton Hansson
3f34b58cee Merge "Enable api lint and check_last_api for modules" into rvc-dev 2020-05-06 09:28:03 +00:00
Junyu Lai
47285473fe Merge changes from topic "am-99b870448c8c43b2815c42861ac6235c-rvc-dev" into rvc-dev am: df554bb5f8
Change-Id: I80823cfcdd22ece5d59d916addcac74333f22d22
2020-05-06 02:50:23 +00:00
junyulai
f887f54a5c [SP18.5] Create offload controller poll interval to resource am: 2a5f21425a
Change-Id: I7e676c4501b2b4510dfb6566bcd5c30bee6fb154
2020-05-06 02:50:20 +00:00
junyulai
b6ab822c32 [SP18.4] Add unit test for polling network stats in OffloadController am: 14722baf0d
Change-Id: I03775f4efff78e5afc365493408611a863322027
2020-05-06 02:50:15 +00:00
junyulai
8c23b65a4f [SP18.3] Adapt TestableNetworkStatsProviderCbBinder am: b7011d2265
Change-Id: I6dc3600a16dd1379e26e6fe2155f71e841c3c90c
2020-05-06 02:50:13 +00:00
Anton Hansson
5b0be161ad Enable api lint and check_last_api for modules
This adds checking of module api compatibility to the individual module
api rules. Until now, this checking has been done via the monolithic
metalava runs which we are aiming to get rid of.

Now is a good time to do this because we can compare them to the just
finalized version 30 API, which we have no diffs with. Baseline the
existing wifi failures that metalava fails to find in the previous API.

Bug: 144149403
Test: m checkapi
Change-Id: Id222895daa3a769c265965b052a17d5a1ca18462
2020-05-05 19:17:08 +01:00
Junyu Lai
e1a04c04d7 [SP18.6] Make offload controller poll interval configurable
Test: atest TetheringTests
Bug: 149467454

Change-Id: I0b07a0b520dedb479bf863fbfe898ae85b84b0f3
Merged-In: I0b07a0b520dedb479bf863fbfe898ae85b84b0f3
(cherry picked from commit 8371fa281839d5b1a1027936f2f83e59bf5301a3)
2020-05-05 10:50:35 +00:00
junyulai
2a5f21425a [SP18.5] Create offload controller poll interval to resource
Test: atest TetheringConfigurationTest
Bug: 149467454
Change-Id: I8b4ad920a4945504914d3741a9fba5c096fbf452
Merged-In: I8b4ad920a4945504914d3741a9fba5c096fbf452
(cherry-picked from aosp/1299413)
2020-05-05 18:45:53 +08:00
junyulai
14722baf0d [SP18.4] Add unit test for polling network stats in OffloadController
Test: atest OffloadControllerTest
Bug: 149467454
Change-Id: I9b9c9c096a2366aaf383d5c2d567db6682f02dad
Merged-In: I9b9c9c096a2366aaf383d5c2d567db6682f02dad
(cherry-picked from aosp/1295347)
2020-05-05 18:45:42 +08:00
junyulai
b7011d2265 [SP18.3] Adapt TestableNetworkStatsProviderCbBinder
This is a no-op refactoring to adapt new test provider callback.
Also this patch adapts TestLooper to allow better control on
delay messages that will be verified in subsequent tests.

Test: atest OffloadControllerTest
Bug: 149467454
Change-Id: Icfd6ff289d6689ae2d5753d3fe472516c808dc7a
Merged-In: Icfd6ff289d6689ae2d5753d3fe472516c808dc7a
(cherry-picked from aosp/1295346)
2020-05-05 18:45:12 +08:00
Bill Yi
9ab332af75 [automerger skipped] Merge "Import translations. DO NOT MERGE" into rvc-dev am: 43708b4424 -s ours
am skip reason: subject contains skip directive

Change-Id: Ib1c6f5bfb858282b4e0392b7d42c0e311409b652
2020-05-02 04:01:53 +00:00
Bill Yi
43708b4424 Merge "Import translations. DO NOT MERGE" into rvc-dev 2020-05-02 03:52:08 +00:00
Anton Hansson
5dadd627be Merge "Rename module dist files" into rvc-dev am: 7e0949732f
Change-Id: I1b9fa1a580c7340df475cb150fe0373a7191869c
2020-05-01 08:38:34 +00:00
Bill Yi
b4c3fee27f Import translations. DO NOT MERGE
Auto-generated-cl: translation import
Change-Id: Ib973f0e381ec0c90f5983a266341444cf919bbea
2020-04-30 19:01:25 -07:00
Anton Hansson
03a93bff6d Merge "Fix tethering module lib stub default" into rvc-dev am: f4fe711313
Change-Id: I1d30f0a8603f6d8009e9fea146de5f9481532147
2020-04-30 19:53:34 +00:00
Anton Hansson
d7f1fabc94 Rename module dist files
This makes the filenames of the disted artifacts (api txts and stubs)
match the module name of the modules they're from. This matches the
naming scheme used by java_sdk_library, which should make the future
transition to this build rule easier.

Bug: 149293194
Test: lunch sdk_phone_armv7 && m sdk dist && find out/dist/apistubs
Change-Id: I076f30931bf2524d57703873cd7de25b3f23b457
2020-04-30 17:42:20 +01:00
Anton Hansson
dc8e0fc1a1 Fix tethering module lib stub default
It was using the systemapi stub defaults, but should be using the
module_lib default.

Bug: 144149403
Test: m
Change-Id: Iaab154d9d71900284d92d518a086fc1227c00d5c
2020-04-30 17:02:07 +01:00
Junyu Lai
50815fdafe Merge changes I38628dad,I2467b647 into rvc-dev am: 027c80d2d6
Change-Id: If79d8724b82021a7840a73b642d9f5fdb07943e2
2020-04-30 06:21:07 +00:00
Junyu Lai
f776651a4b [SP18] Poll network stats in OffloadController to support data warning am: bf6fa99b2a
Change-Id: Ib0549b36a1e5bf9a728c4187facd4caae6e6df2f
2020-04-30 06:21:05 +00:00
Remi NGUYEN VAN
d24ff42f00 Merge "Address comments on NetworkStack AIDL v6" into rvc-dev am: 675ec9d30e
Change-Id: I58b6863e5f8417368c7cd83edc487404d5156e99
2020-04-30 06:19:07 +00:00
Junyu Lai
027c80d2d6 Merge changes I38628dad,I2467b647 into rvc-dev
* changes:
  [SP18.1] add dependency object to OffloadController
  [SP18] Poll network stats in OffloadController to support data warning
2020-04-30 06:07:25 +00:00
Treehugger Robot
40092b1fa7 [SP18.1] add dependency object to OffloadController
In order to mock constant in unit test, a dependency object is
introduced with minimum code change to achieve this.

Test: atest TetheringTests
Bug: 149467454
Change-Id: I38628daddcb7be7c74846e78d36dc88f065b97d9
Merged-In: I38628daddcb7be7c74846e78d36dc88f065b97d9
(cherry picked from commit 29aee20bfa)
2020-04-30 05:03:07 +00:00
Junyu Lai
bf6fa99b2a [SP18] Poll network stats in OffloadController to support data warning
The OEM implemented tether offload does not support
data warning since the HAL only tells the hardware about data limit
but not warning. However, to add such interface in HAL needs OEM to
comply and implement in hardware.

Thus, as a short-term solution, polls network statistics from HAL
and notify upper layer when it reaches the alert quota set by
NetworkStatsService.

Note that when CPU is sleeping, the data warning of tethering offload
will not work since the polling is also suspended.

Test: manual
Test: atest OffloadControllerTest
Bug: 149467454
Change-Id: I2467b64779b74cd5fec73b42fb303584f52cb1cb
Merged-In: I2467b64779b74cd5fec73b42fb303584f52cb1cb
(cherry picked from commit 93660e382c)
2020-04-30 04:58:21 +00:00
Remi NGUYEN VAN
a530ebb62d Address comments on NetworkStack AIDL v6
Address issues found during AIDL review:
 - Rename clientAddr to singleClientAddr
 - Do not use a ParcelableBundle for notifyNetworkTested or
   notifyDataStallSuspected; instead use AIDL parcelables for stronger
   backwards compatibility guarantees.

Test: atest NetworkMonitorTest ConnectivityServiceTest
      ConnectivityServiceIntegrationTest, manual
Bug: 153500847
Merged-In: Id9b71784e5f6294d203230e57737979e063ff0f8
Change-Id: Id9b71784e5f6294d203230e57737979e063ff0f8
2020-04-28 08:09:17 +00:00
Mark Chien
ec45939bda Merge "Remove Preconditions usage to stop dependecy with non-updatble class" into rvc-dev am: 9258a08525
Change-Id: I7b13aa7a500d804d0e8ef96d9d72556f3c642124
2020-04-28 03:12:09 +00:00
Mark Chien
9258a08525 Merge "Remove Preconditions usage to stop dependecy with non-updatble class" into rvc-dev 2020-04-28 03:09:25 +00:00
TreeHugger Robot
c1d4bdd773 Merge "Import translations. DO NOT MERGE" into rvc-d1-dev 2020-04-27 15:27:39 +00:00
TreeHugger Robot
d5e76ce15a [automerger skipped] Merge "Import translations. DO NOT MERGE" into rvc-dev am: 885d4eaf1f -s ours
am skip reason: subject contains skip directive

Change-Id: I5afe5954b98be5724974e939dc1ce0bf4e4716e2
2020-04-27 14:42:24 +00:00
TreeHugger Robot
885d4eaf1f Merge "Import translations. DO NOT MERGE" into rvc-dev 2020-04-27 14:24:33 +00:00
Mark Chien
ed50636b60 Remove Preconditions usage to stop dependecy with non-updatble class
Stop depending on Preconditions that is not released on the same cadence
as the module, and is maintained as part of the framework.

Bug: 148636687
Test: atest TetheringTests NetworkStackNextTests

Merged-In: Id0dcec44f362f79bc8c046d722635687a7388aa2
Change-Id: Id0dcec44f362f79bc8c046d722635687a7388aa2
2020-04-27 12:38:07 +00:00
Mark Chien
3613937137 Merge "Unbreak tethering for no offload supported devices" into rvc-dev am: 48a2ffac38
Change-Id: Ibb783aeacc0f15b865508f7e48ed43ef35a4933d
2020-04-27 12:33:26 +00:00
Mark Chien
27cdaf679a Unbreak tethering for no offload supported devices
Catch NoSuchElementException to unbreak no offload devices.

To consistent with fetching offload config service, retry fetcheing
offload control service.
b/152430668#comment4 assert that the fetch will be retried only
if the service is installed on the device.

Bug: 155026033
Test: run TetheringCoverageTests in virtual devices(do not support
offload)

Merged-In: Ie0a32a9062c722327a27c6de13e3bb8d9588bebb
Change-Id: Ie0a32a9062c722327a27c6de13e3bb8d9588bebb
2020-04-27 09:15:25 +00:00
Bill Yi
b85287f5d0 Import translations. DO NOT MERGE
Change-Id: I1cdee455c89183fa875ac4916105db6dffd5ee2b
Auto-generated-cl: translation import
2020-04-27 01:01:45 -07:00
Bill Yi
8a35765b6f Import translations. DO NOT MERGE
Auto-generated-cl: translation import
Change-Id: I08496ebb9bad7c95a6e9df43ef57c55a9956c9d8
2020-04-27 00:04:34 -07:00
TreeHugger Robot
ac6fdb4eef Merge "Import translations. DO NOT MERGE" into rvc-d1-dev 2020-04-23 23:25:24 +00:00
Paul Hu
3183b5ff2e Merge "[TNU09] Adjust restricted notification" into rvc-dev am: 0b5d999a8c
Change-Id: Iaed5ec62fff05abed68b8eb7fcdfe727ade49952
2020-04-23 11:39:06 +00:00
Paul Hu
0439c2d204 [TNU09] Adjust restricted notification
1. Let restricted notification that can be dismissed.
2. Only put up restricted notification when any of tethering is
   activating.

Bug: 154214549
Test: atest TetheringTests
Change-Id: Ib980aca154036828abdab35e3bb11d42f85ff610
Merged-In: Ib980aca154036828abdab35e3bb11d42f85ff610
(cherry picked from commit 2eb66bdbe4, aosp/1290334)
2020-04-23 10:18:11 +00:00
Bill Yi
3fe17e291b Import translations. DO NOT MERGE
Change-Id: Ib2f7fbbb8ebd73b517aa44a4708a7040d2394823
Auto-generated-cl: translation import
2020-04-23 02:17:41 -07:00
Paul Hu
1716344e59 Merge "Add TetheredClient tests" into rvc-dev am: 34d6a00acb
Change-Id: Idda1273dc05a5acdbf4f3d8092259ebf825a293a
2020-04-23 05:54:55 +00:00
Paul Hu
6469fe0556 Merge "Add TetheringCommonTests" into rvc-dev am: 1277763ddd
Change-Id: Id3aa90e11df5c334679a590c2b6d36467dbb0769
2020-04-23 01:25:13 +00:00
Paul Hu
86152672a6 Add TetheredClient tests
Test APIs below:
getAddresses()
getMacAddress()
getTetheringType()
AddressInfo.getAddress()
AddressInfo.getHostname()
AddressInfo.writeToParcel(android.os.Parcel, int)

Bug: 153614365
Bug: 153613717
Test: atest TetheringTests
Change-Id: Ic7cbebe54a38af5b5c4639eb7641a20de6864a26
Merged-In: Ic7cbebe54a38af5b5c4639eb7641a20de6864a26
(cherry picked from commit fa882fdb96, aosp/1292438)
2020-04-23 01:10:19 +00:00
Paul Hu
1277763ddd Merge "Add TetheringCommonTests" into rvc-dev 2020-04-23 01:06:13 +00:00
Bill Yi
2fe57392e1 [automerger skipped] Merge "Import translations. DO NOT MERGE" into rvc-dev am: f76d89b395 -s ours
am skip reason: subject contains skip directive

Change-Id: I9eafd111755182368e39266adf333b8d0f92fb96
2020-04-23 00:17:29 +00:00
Bill Yi
70521ef0e8 Import translations. DO NOT MERGE
Change-Id: I4b3a8cf8d738bf6f680258f1ebd77d894dc986cd
Auto-generated-cl: translation import
2020-04-22 15:24:12 -07:00
Paul Hu
1cae88f560 Add TetheringCommonTests
Bug: 153614365
Bug: 153613717
Test: atest TetheringTests TetheringCoverageTests
Change-Id: If7c933ec0c72943312cd37bfc66918f10a5504a9
Merged-In: If7c933ec0c72943312cd37bfc66918f10a5504a9
(cherry picked from commit f340f6fd46, aosp/1290553)
2020-04-22 15:24:13 +00:00
Mark Chien
32766d1a2b Merge "Include NetworkStaticLibTestsLib into tethering coverage test" into rvc-dev am: 70e43fb856
Change-Id: I5bbf860bb590a33bb54a411ca40a7b53463c96de
2020-04-22 14:11:11 +00:00
Mark Chien
70e43fb856 Merge "Include NetworkStaticLibTestsLib into tethering coverage test" into rvc-dev 2020-04-22 13:54:33 +00:00