summaryrefslogtreecommitdiff
path: root/Tethering/src/com/android/networkstack/tethering/OffloadController.java
Commit message (Collapse)AuthorAgeFilesLines
* Import net-utils-device-common-netlink instead of netlink-client.Xiao Ma2021-07-211-3/+3
| | | | | | | | | | | | | After moving all netlink-client stuff to frameworks/libs/net/common and build it as an individual library, deprecate the netlink-client lib and use net-utils-device-common-netlink instead. Due to that the package name of netlink lib has changed, also update the package name used in Tethering and ConnectivityService module. Bug: 192535368 Test: atest TetheringTests TetheringIntegrationTests Change-Id: Ic2078caf67a640836d98c5a2e4ca89939adcb896
* [SP35] Pass data warning to tethering offloadjunyulai2021-06-241-2/+31
| | | | | | | | | | | | | | | | This is supported by: 1. Utilize the new API from both NetworkStatsProvider and IOffloadControl to send data warning quota to hardware. And pass the warning reached notification back to NPMS. 2. Disable software solution introduced in R release for V1.1+ hardware, since now we can fully offload data warning and limit notification to hardware. Test: atest TetheringTests Fix: 149467454 Merged-In: Ie49461694d77ab7f25a549433b01b5b0167bd489 Change-Id: Ie49461694d77ab7f25a549433b01b5b0167bd489 (cherry-picked from ag/13981692)
* [SP34] Adapt onSetWarningAndLimitjunyulai2021-06-241-16/+56
| | | | | | | | | | | | | This is a no-op change that just adapt new API from NetworkStatsProvider to get warning and limit bytes at the same time. This change also stores them locally for subsequent patches to set warning bytes to hardware. Test: Will be included in the subsequent patch. Bug: 149467454 Merged-In: Iec01cb01fd1ce481ce0bd736762baddde1e38084 Change-Id: Iec01cb01fd1ce481ce0bd736762baddde1e38084 (cherry-picked from ag/13981691)
* [SP32] Try to get 1.1 OffloadControl hardware if availablejunyulai2021-04-291-4/+8
| | | | | | | | | | | | | This is a no-op change that try to use 1.1 HAL if available. Otherwise, fallback to 1.0 HAL. The change also provides version information for subsequent patches to determine what to do for specific version. Test: atest TetheringTests Bug: 149467454 Merged-In: I6a3ce877cdff2496087b97b191a9bfd5b0792827 Change-Id: I6a3ce877cdff2496087b97b191a9bfd5b0792827 (cherry-picked from ag/13973146)
* [SP18.6] Make offload controller poll interval configurablejunyulai2020-05-051-9/+11
| | | | | | | Test: atest TetheringTests Bug: 149467454 Change-Id: I0b07a0b520dedb479bf863fbfe898ae85b84b0f3
* [SP18.4] Add unit test for polling network stats in OffloadControllerjunyulai2020-05-041-1/+2
| | | | | | Test: atest OffloadControllerTest Bug: 149467454 Change-Id: I9b9c9c096a2366aaf383d5c2d567db6682f02dad
* [SP18.1] add dependency object to OffloadControllerjunyulai2020-04-281-2/+15
| | | | | | | | | 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
* [SP18] Poll network stats in OffloadController to support data warningjunyulai2020-04-281-0/+74
| | | | | | | | | | | | | | | | | | | 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
* Change tethering file structure to respect its package namemarkchien2020-04-141-0/+721
Bug: 145099347 Test: atest TetheringTests atest CtsTetheringTest Change-Id: I7401c550fbafd17a5ed2d925b5d0e17e358af467