anakryiko / bpf-ringbuf-examples Goto Github PK
View Code? Open in Web Editor NEWExamples of using BPF ring buffer APIs
License: BSD 3-Clause "New" or "Revised" License
Examples of using BPF ring buffer APIs
License: BSD 3-Clause "New" or "Revised" License
BPF .output/ringbuf-output.bpf.o
ringbuf-output.bpf.c:11:15: error: use of undeclared identifier 'BPF_MAP_TYPE_RINGBUF'; did you mean 'BPF_MAP_TYPE_UNSPEC'?
__uint(type, BPF_MAP_TYPE_RINGBUF);
^~~~~~~~~~~~~~~~~~~~
BPF_MAP_TYPE_UNSPEC
.output/bpf/bpf_helpers.h:13:39: note: expanded from macro '__uint'
#define __uint(name, val) int (*name)[val]
^
/usr/include/linux/bpf.h:100:2: note: 'BPF_MAP_TYPE_UNSPEC' declared here
BPF_MAP_TYPE_UNSPEC,
^
1 error generated.
Makefile:57: recipe for target '.output/ringbuf-output.
Hey, nowadays libbpf provides several APIs about ring-buffer like (ring_buffer__new
/...). Maybe update the examples with these APIs would be easier for beginners to understand, what do you think~
MKDIR .output
MKDIR .output/libbpf
LIB libbpf.a
MKDIR staticobjs
CC bpf.o
CC btf.o
CC libbpf.o
CC libbpf_errno.o
CC netlink.o
CC nlattr.o
CC str_error.o
CC libbpf_probes.o
CC bpf_prog_linfo.o
CC xsk.o
CC btf_dump.o
CC hashmap.o
CC ringbuf.o
AR libbpf.a
INSTALL bpf.h libbpf.h btf.h xsk.h libbpf_util.h bpf_helpers.h bpf_helper_defs.h bpf_tracing.h bpf_endian.h bpf_core_read.h libbpf_common.h
INSTALL libbpf.pc
INSTALL libbpf.a
BPF .output/perfbuf-output.bpf.o
make: clang: No such file or directory
make: *** [Makefile:58: .output/perfbuf-output.bpf.o] Error 127
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.