simplify: BpfLevel -> BpfEnabled where appropriate
bpf::BpfLevel getBpfLevel() --> bool getBpfEnabled()
bpf::BpfLevel mBpfLevel --> bool mBpfEnabled
Test: build, atest
Signed-off-by: Maciej Żenczykowski <maze@google.com>
Change-Id: Idb5f9ed10e123a5653047b9d31c7245b9cb8a46e
diff --git a/server/TrafficController.h b/server/TrafficController.h
index 741ceb7..a2539a9 100644
--- a/server/TrafficController.h
+++ b/server/TrafficController.h
@@ -81,7 +81,7 @@
* Check if the current device have the bpf traffic stats accounting service
* running.
*/
- bpf::BpfLevel getBpfLevel();
+ bool getBpfEnabled();
/*
* Swap the stats map config from current active stats map to the idle one.
@@ -209,7 +209,7 @@
netdutils::Status addRule(BpfMap<uint32_t, UidOwnerValue>& map, uint32_t uid,
UidOwnerMatchType match, uint32_t iif = 0) REQUIRES(mMutex);
- bpf::BpfLevel mBpfLevel;
+ bool mBpfEnabled;
// mMutex guards all accesses to mConfigurationMap, mUidOwnerMap, mUidPermissionMap,
// mStatsMapA, mStatsMapB and mPrivilegedUser. It is designed to solve the following