summaryrefslogtreecommitdiff
path: root/service-t/native/libs/libnetworkstats
Commit message (Collapse)AuthorAgeFilesLines
* Support more than 8 firewall chains / match types.Lorenzo Colitti2022-06-011-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | In the BPF code, per-UID network access (e.g., for doze mode, standby, etc.) is stored in UidOwnerValue structures. Each of these stores that UID's rules in a 32-bit bitmask of UidOwnerMatchType values, so the code can support ~31 match types. However, which match types are enabled is stored in configuration_map at index UID_RULES_CONFIGURATION_KEY, and configuration_map only stores 8-bit values. So it's not possible to define more than 7 match types. Widen configuration_map to from 8 to 32 bits to match the width of UidOwnerValue.rule. This doesn't impact memory because configuration_map only has 2 entries. Bug: 208371987 Test: TreeHugger Signed-off-by: Maciej Żenczykowski <maze@google.com> Change-Id: I7e1eee2daedd66d27965a2dd4ce6b4c3667892f7 (cherry picked from commit 60cbed385dcf3c640674c48b7cd4d60967047cf0) Merged-In: I7e1eee2daedd66d27965a2dd4ce6b4c3667892f7
* Merge changes from topic "ms52-movenetstats"Remi NGUYEN VAN2022-02-071-1/+0
|\ | | | | | | | | | | | | | | | | | | * changes: Update API files to unhide MATCH_PROXY. Update tests for NetworkStats code move. Add setPollForce to module API Add JNI stats libraries to connectivity [MS62.2] Add NetworkStatsService into service initializer [MS54.3] Move NetworkStats to updatable sources
| * Add JNI stats libraries to connectivityRemi NGUYEN VAN2022-02-071-1/+0
| | | | | | | | | | | | | | | | | | | | Add new symbols to libservice-connectivity loaded on T only, and the framework libraries to apex and tests. Ignore-AOSP-First: Avoiding conflicts; cherry-pick will follow Bug: 197717846 Test: atest FrameworksNetTests Change-Id: Iae44344701a3267110e5cbf271120201134d59e5
* | Fix libnetworkstats_test.Lorenzo Colitti2022-02-071-3/+4
|/ | | | | | | | | | | | | | | | | | | | | | If libraries are moved from the platform to a module, the test will fail with: CANNOT LINK EXECUTABLE "/data/local/tmp/libnetworkstats_test/arm64/libnetworkstats_test": library "libnetworkstats.so" not found: needed by main executable This may be because it can't find libnetworkstats.so because that is in platform. In any case, since this is the test for libnetworkstats, dynamically linking libnetworkstats is incorrect, because it means if the same CL modifies both libnetworkstats and its test, that CL will run the modified test against the unmodified libnetworkstats.so on the device, when running updating tests without reflashing the device. Also remove libutils because it does not seem to be needed. Test: atest libnetworkstats_test passes with libraries moved Change-Id: Id49641c0a919129e2c54531c3995ec7421161002
* Correct typos in libnetworkstatsKen Chen2022-01-242-4/+4
| | | | | | | | Fix Typo-Lints in I23aad26d487b4d99e24ffecf79eeef3f8eea664b Bug: N/A Test: m Change-Id: Id9df0a279e7aad048f2c0d7be66dec40e5a8ae8a
* Rename libnetdbpf to libnetworkstatsKen Chen2022-01-244-0/+1116
Two reason for renaming: 1. Avoid module name collision in sc-mainline-prod branch. 2. The libnetdbpf was misnamed before. Bug: 202086915 Test: atest libnetworkstats_test FrameworksNetTests ConnectivityCoverageTests FrameworksNetSmokeTests CtsAppOpsTestCases Change-Id: I87fcf4b1a9d58780a45743a9aa91b9b936e54266