libbpf_android/BpfUtils - remove unused bpfProgLoad

(due to switch to bpfloader from loading via netd)

Test: build, atest
Signed-off-by: Maciej Żenczykowski <maze@google.com>
Change-Id: Ic95cdfde26b8e7b905551a7fd2b465e0cf99bbce
diff --git a/libbpf_android/BpfUtils.cpp b/libbpf_android/BpfUtils.cpp
index df8c901..32b4120 100644
--- a/libbpf_android/BpfUtils.cpp
+++ b/libbpf_android/BpfUtils.cpp
@@ -125,30 +125,6 @@
     return bpf(BPF_MAP_GET_NEXT_KEY, Slice(&attr, sizeof(attr)));
 }
 
-int bpfProgLoad(bpf_prog_type prog_type, Slice bpf_insns, const char* license,
-                uint32_t kern_version, Slice bpf_log) {
-    bpf_attr attr;
-    memset(&attr, 0, sizeof(attr));
-    attr.prog_type = prog_type;
-    attr.insns = ptr_to_u64(bpf_insns.base());
-    attr.insn_cnt = bpf_insns.size() / sizeof(struct bpf_insn);
-    attr.license = ptr_to_u64((void*)license);
-    attr.log_buf = ptr_to_u64(bpf_log.base());
-    attr.log_size = bpf_log.size();
-    attr.log_level = DEFAULT_LOG_LEVEL;
-    attr.kern_version = kern_version;
-    int ret = bpf(BPF_PROG_LOAD, Slice(&attr, sizeof(attr)));
-
-    if (ret < 0) {
-        std::string prog_log = netdutils::toString(bpf_log);
-        std::istringstream iss(prog_log);
-        for (std::string line; std::getline(iss, line);) {
-            ALOGE("%s", line.c_str());
-        }
-    }
-    return ret;
-}
-
 int bpfFdPin(const base::unique_fd& map_fd, const char* pathname) {
     bpf_attr attr;
     memset(&attr, 0, sizeof(attr));
diff --git a/libbpf_android/include/bpf/BpfUtils.h b/libbpf_android/include/bpf/BpfUtils.h
index 7afdb5b..f2b2c84 100644
--- a/libbpf_android/include/bpf/BpfUtils.h
+++ b/libbpf_android/include/bpf/BpfUtils.h
@@ -106,8 +106,6 @@
 int deleteMapEntry(const base::unique_fd& map_fd, void* key);
 int getNextMapKey(const base::unique_fd& map_fd, void* key, void* next_key);
 int getFirstMapKey(const base::unique_fd& map_fd, void* firstKey);
-int bpfProgLoad(bpf_prog_type prog_type, netdutils::Slice bpf_insns, const char* license,
-                uint32_t kern_version, netdutils::Slice bpf_log);
 int bpfFdPin(const base::unique_fd& map_fd, const char* pathname);
 int bpfFdGet(const char* pathname, uint32_t flags);
 int attachProgram(bpf_attach_type type, uint32_t prog_fd, uint32_t cg_fd);