HomeSort by relevance Sort by last modified time
    Searched defs:bpf (Results 1 - 12 of 12) sorted by null

  /build/soong/bpf/
bpf.go 15 package bpf package
29 android.RegisterModuleType("bpf", bpfFactory)
34 pctx = android.NewPackageContext("android/soong/bpf")
40 Command: "$ccCmd --target=bpf -c $cFlags -MD -MF ${out}.d -o $out $in",
52 type bpf struct { type
60 func (bpf *bpf) GenerateAndroidBuildActions(ctx android.ModuleContext) {
72 for _, dir := range android.PathsForSource(ctx, bpf.properties.Include_dirs) {
76 cflags = append(cflags, bpf.properties.Cflags...)
78 srcs := ctx.ExpandSources(bpf.properties.Srcs, nil
    [all...]
  /system/netd/tests/
bpf_base_test.cpp 36 #include "bpf/BpfMap.h"
37 #include "bpf/BpfUtils.h"
39 using namespace android::bpf;
46 namespace bpf { namespace in namespace:android
  /system/netd/libbpf/
BpfNetworkStats.cpp 28 #include "bpf/BpfMap.h"
29 #include "bpf/BpfNetworkStats.h"
38 namespace bpf { namespace in namespace:android
255 } // namespace bpf
BpfMapTest.cpp 37 #include "bpf/BpfMap.h"
38 #include "bpf/BpfNetworkStats.h"
39 #include "bpf/BpfUtils.h"
49 namespace bpf { namespace in namespace:android
57 constexpr const char PINNED_MAP_PATH[] = "/sys/fs/bpf/testMap";
289 } // namespace bpf
BpfUtils.cpp 17 #include <linux/bpf.h>
34 #include "bpf/BpfUtils.h"
47 namespace bpf { namespace in namespace:android
51 * is. The bpf kernel code will performs a much stricter check to ensure all unused field is 0. So
68 int bpf(int cmd, Slice bpfAttr) { function in namespace:android::bpf
82 return bpf(BPF_MAP_CREATE, Slice(&attr, sizeof(attr)));
93 return bpf(BPF_MAP_UPDATE_ELEM, Slice(&attr, sizeof(attr)));
103 return bpf(BPF_MAP_LOOKUP_ELEM, Slice(&attr, sizeof(attr)));
112 return bpf(BPF_MAP_DELETE_ELEM, Slice(&attr, sizeof(attr)));
122 return bpf(BPF_MAP_GET_NEXT_KEY, Slice(&attr, sizeof(attr)))
    [all...]
BpfNetworkStatsTest.cpp 37 #include "bpf/BpfMap.h"
38 #include "bpf/BpfNetworkStats.h"
39 #include "bpf/BpfUtils.h"
41 using namespace android::bpf;
51 namespace bpf { namespace in namespace:android
155 // TEST to verify the behavior of bpf map when cocurrent deletion happens when
443 } // namespace bpf
  /system/netd/libbpf/include/bpf/
BpfNetworkStats.h 17 #include <bpf/BpfMap.h>
20 namespace bpf { namespace in namespace:android
111 } // namespace bpf
BpfMap.h 20 #include <linux/bpf.h>
25 #include "bpf/BpfUtils.h"
30 namespace bpf { namespace in namespace:android
324 } // namespace bpf
BpfUtils.h 20 #include <linux/bpf.h>
37 namespace bpf { namespace in namespace:android
75 #define BPF_PATH "/sys/fs/bpf"
160 } // namespace bpf
  /frameworks/base/tests/net/jni/
apf_jni.cpp 100 // Compile "filter" to a BPF program
101 bpf_program bpf; local
102 if (pcap_compile(pcap.get(), &bpf, filter.c_str(), 0, PCAP_NETMASK_UNKNOWN)) {
107 // Translate BPF program to human-readable format
108 const struct bpf_insn* insn = bpf.bf_insns;
109 for (uint32_t i = 0; i < bpf.bf_len; i++) {
124 // Open pcap file for BPF filtering
141 // Compile "filter" to a BPF program
142 bpf_program bpf; local
143 if (pcap_compile(bpf_pcap.get(), &bpf, filter.c_str(), 0, PCAP_NETMASK_UNKNOWN))
    [all...]
  /system/netd/bpfloader/
BpfLoader.cpp 26 #include <linux/bpf.h>
47 #include "bpf/BpfUtils.h"
48 #include "bpf/bpf_shared.h"
54 #define BPF_PROG_PATH "/system/etc/bpf"
64 // The BPF instruction bytes that we need to replace. x is a placeholder (e.g., COOKIE_TAG_MAP).
75 // for bpf map fd loading. The original 0x01 is only a normal load command.
85 unique_fd _mapFd(android::bpf::mapRetrieve((_mapPath), 0)); \
94 namespace bpf { namespace in namespace:android
149 if (elfHeader.size() < sizeof(Elf64_Ehdr)) FAIL("bpf buffer does not have complete elf header");
264 } // namespace bpf
    [all...]
  /external/iproute2/lib/
bpf.c 2 * bpf.c BPF common code
132 static int bpf(int cmd, union bpf_attr *attr, unsigned int size) function
137 fprintf(stderr, "No bpf syscall, kernel headers too old?\n");
153 return bpf(BPF_MAP_UPDATE_ELEM, &attr, sizeof(attr));
162 return bpf(BPF_PROG_GET_FD_BY_ID, &attr, sizeof(attr));
176 ret = bpf(BPF_OBJ_GET_INFO_BY_FD, &attr, sizeof(attr));
485 if (mount("bpf", target, "bpf", 0, "mode=0700")) {
486 fprintf(stderr, "mount -t bpf bpf %s failed: %s\n"
    [all...]

Completed in 280 milliseconds