dedup kernelversion.h
Test: TreeHugger
Signed-off-by: Maciej Żenczykowski <maze@google.com>
Change-Id: Ie7a4dd46122e86bf808d0a3ac566075e1c3a2cd4
diff --git a/staticlibs/native/tcutils/tests/tcutils_test.cpp b/staticlibs/native/tcutils/tests/tcutils_test.cpp
index 3a89696..53835d7 100644
--- a/staticlibs/native/tcutils/tests/tcutils_test.cpp
+++ b/staticlibs/native/tcutils/tests/tcutils_test.cpp
@@ -18,7 +18,7 @@
#include <gtest/gtest.h>
-#include "kernelversion.h"
+#include "bpf/KernelVersion.h"
#include <tcutils/tcutils.h>
#include <BpfSyscallWrappers.h>
@@ -82,7 +82,7 @@
// TODO: this should likely be in the tethering module, where using netd.h would be ok
static constexpr char bpfProgPath[] =
"/sys/fs/bpf/tethering/prog_offload_schedcls_tether_downstream6_ether";
- const int errNOENT = isAtLeastKernelVersion(4, 19, 0) ? ENOENT : EINVAL;
+ const int errNOENT = bpf::isAtLeastKernelVersion(4, 19, 0) ? ENOENT : EINVAL;
// static test values
static constexpr bool ingress = true;
@@ -118,7 +118,7 @@
ASSERT_LE(3, fd);
close(fd);
- const int errNOENT = isAtLeastKernelVersion(4, 19, 0) ? ENOENT : EINVAL;
+ const int errNOENT = bpf::isAtLeastKernelVersion(4, 19, 0) ? ENOENT : EINVAL;
// static test values
static constexpr unsigned rateInBytesPerSec =