| /external/libbpf/ |
| D | README.md | 1 This is a mirror of [bpf-next Linux source 2 tree](https://kernel.googlesource.com/pub/scm/linux/kernel/git/bpf/bpf-next)'s 3 `tools/lib/bpf` directory plus its supporting header files. 5 All the gory details of syncing can be found in `scripts/sync-kernel.sh` 10 [bpf-next](https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf-next.git/)'s 11 `tools/include/linux/*.h` to make compilation successful. 13 BPF/libbpf usage and questions 16 Please check out [libbpf-bootstrap](https://github.com/libbpf/libbpf-bootstrap) 17 and [the companion blog post](https://nakryiko.com/posts/libbpf-bootstrap/) for 18 the examples of building BPF applications with libbpf. [all …]
|
| D | Android.bp | 7 // http://www.apache.org/licenses/LICENSE-2.0 19 // See: http://go/android-license-faq 24 "SPDX-license-identifier-BSD-2-Clause", 25 "SPDX-license-identifier-Linux-syscall-note", 28 "LICENSE.BSD-2-Clause", 37 cmd: "mkdir -p $(genDir)/bpf && cp $(in) $(genDir)/bpf/", 48 "bpf/libbpf.h", 58 name: "libbpf", 73 "-DCOMPAT_NEED_REALLOCARRAY", 74 "-include android/android.h", [all …]
|
| /external/bcc/debian/ |
| D | changelog | 1 bcc (0.24.0-1) unstable; urgency=low 4 * bcc tools: update for trace.py, sslsniff.py, tcptop.py, hardirqs.py, etc. 5 * new libbpf tools: bashreadline 8 * remove all deprecated libbpf function usage 11 * doc update, bug fixes and other tools improvement 13 -- Yonghong Song <ys114321@gmail.com> Wed, 14 Jan 2022 17:00:00 +0000 15 bcc (0.23.0-1) unstable; urgency=low 18 * bcc tools: update for kvmexit.py, tcpv4connect.py, cachetop.py, cachestat.py, etc. 19 * libbpf tools: update for update for mountsnoop, ksnoop, gethostlatency, etc. 20 * fix renaming of task_struct->state [all …]
|
| /external/libbpf/scripts/ |
| D | sync-kernel.sh | 4 echo "USAGE: ./sync-kernel.sh <libbpf-repo> <kernel-repo> <bpf-branch>" 6 …echo "Set BPF_NEXT_BASELINE to override bpf-next tree commit, otherwise read from <libbpf-repo>/CH… 7 …BPF_BASELINE to override bpf tree commit, otherwise read from <libbpf-repo>/BPF-CHECKPOINT-COMMIT." 8 echo "Set MANUAL_MODE to 1 to manually control every cherry-picked commits." 12 set -eu 14 LIBBPF_REPO=${1-""} 15 LINUX_REPO=${2-""} 16 BPF_BRANCH=${3-""} 17 BASELINE_COMMIT=${BPF_NEXT_BASELINE:-$(cat ${LIBBPF_REPO}/CHECKPOINT-COMMIT)} 18 BPF_BASELINE_COMMIT=${BPF_BASELINE:-$(cat ${LIBBPF_REPO}/BPF-CHECKPOINT-COMMIT)} [all …]
|
| /external/bcc/libbpf-tools/ |
| D | README.md | 2 ------------ 4 - [BPF Portability and CO-RE](https://facebookmicrosites.github.io/bpf/blog/2020/02/19/bpf-portabil… 5 - [HOWTO: BCC to libbpf conversion](https://facebookmicrosites.github.io/bpf/blog/2020/02/20/bcc-to… 6 - [Tips & tricks for writing libbpf-tools](https://en.pingcap.com/blog/tips-and-tricks-for-writing-… 9 ------- 11 To build libbpf-based tools, simply run `make`. This will build all the listed 12 tools/applications. All the build artifacts, by default, go into .output 18 Given that the libbpf package might not be available across wide variety of 19 distributions, all libbpf-based tools are linked statically against a version 20 of libbpf that BCC links against (from submodule under src/cc/libbpf). This [all …]
|
| D | Makefile | 1 # SPDX-License-Identifier: (LGPL-2.1 OR BSD-2-Clause) 4 LLVM_STRIP ?= llvm-strip 6 LIBBPF_SRC := $(abspath ../src/cc/libbpf/src) 7 LIBBPF_OBJ := $(abspath $(OUTPUT)/libbpf.a) 8 INCLUDES := -I$(OUTPUT) -I../src/cc/libbpf/include/uapi 9 CFLAGS := -g -O2 -Wall 10 BPFCFLAGS := -g -O2 -Wall 13 ARCH := $(shell uname -m | sed 's/x86_64/x86/' | sed 's/aarch64/arm64/' | sed 's/ppc64le/powerpc/' … 83 msg = @printf ' %-8s %s%s\n' "$(1)" "$(notdir $(2))" "$(if $(3), $(3))"; 84 MAKEFLAGS += --no-print-directory [all …]
|
| D | numamove.c | 1 // SPDX-License-Identifier: (LGPL-2.1 OR BSD-2-Clause) 4 // Based on numamove(8) from BPF-Perf-Tools-Book by Brendan Gregg. 5 // 8-Jun-2020 Wenbo Zhang Created this. 11 #include <bpf/libbpf.h> 24 "https://github.com/iovisor/bcc/tree/master/libbpf-tools"; 28 "USAGE: numamove [--help]\n" 92 if (!obj->bss) { in main() 93 …fprintf(stderr, "Memory-mapping BPF maps is supported starting from Linux 5.7, please upgrade.\n"); in main() 105 printf("%-10s %18s %18s\n", "TIME", "NUMA_migrations", "NUMA_migrations_ms"); in main() 111 printf("%-10s %18lld %18lld\n", ts, in main() [all …]
|
| D | readahead.c | 1 // SPDX-License-Identifier: (LGPL-2.1 OR BSD-2-Clause) 4 // Based on readahead(8) from BPF-Perf-Tools-Book by Brendan Gregg. 5 // 8-Jun-2020 Wenbo Zhang Created this. 10 #include <bpf/libbpf.h> 20 .duration = -1 27 "https://github.com/iovisor/bcc/tree/master/libbpf-tools"; 29 "Show fs automatic read-ahead usage.\n" 31 "USAGE: readahead [--help] [-d DURATION]\n" 34 " readahead # summarize on-CPU time as a histogram" 35 " readahead -d 10 # trace for 10 seconds only\n"; [all …]
|
| D | biostacks.c | 1 // SPDX-License-Identifier: (LGPL-2.1 OR BSD-2-Clause) 4 // Based on biostacks(8) from BPF-Perf-Tools-Book by Brendan Gregg. 5 // 10-Aug-2020 Wenbo Zhang Created this. 10 #include <bpf/libbpf.h> 22 .duration = -1, 27 "https://github.com/iovisor/bcc/tree/master/libbpf-tools"; 31 "USAGE: biostacks [--help] [-d DISK] [-m] [duration]\n" 36 " biostacks -d sdc # trace sdc only\n"; 114 printf("%-14.14s %-6d %-7s\n", in print_map() 116 partition ? partition->name : "Unknown"); in print_map() [all …]
|
| D | biopattern.c | 1 // SPDX-License-Identifier: (LGPL-2.1 OR BSD-2-Clause) 4 // Based on biopattern(8) from BPF-Perf-Tools-Book by Brendan Gregg. 5 // 17-Jun-2020 Wenbo Zhang Created this. 11 #include <bpf/libbpf.h> 32 "https://github.com/iovisor/bcc/tree/master/libbpf-tools"; 36 "USAGE: biopattern [--help] [-T] [-d DISK] [interval] [count]\n" 41 " biopattern -T 1 # 1s summaries with timestamps\n" 42 " biopattern -d sdc # trace sdc only\n"; 114 __u32 total, lookup_key = -1, next_key; in print_map() 126 return -1; in print_map() [all …]
|
| D | cpufreq.c | 1 // SPDX-License-Identifier: (LGPL-2.1 OR BSD-2-Clause) 4 // Based on cpufreq(8) from BPF-Perf-Tools-Book by Brendan Gregg. 5 // 10-OCT-2020 Wenbo Zhang Created this. 14 #include <bpf/libbpf.h> 25 .duration = -1, 31 "https://github.com/iovisor/bcc/tree/master/libbpf-tools"; 33 "Sampling CPU freq system-wide & by process. Ctrl-C to end.\n" 35 "USAGE: cpufreq [--help] [-d DURATION] [-f FREQUENCY]\n" 39 " cpufreq -d 5 # sample for 5 seconds only\n" 40 " cpufreq -f 199 # sample CPU freq at 199HZ\n"; [all …]
|
| D | oomkill.c | 1 // SPDX-License-Identifier: (LGPL-2.1 OR BSD-2-Clause) 5 // 13-Jan-2022 Jingxiang Zeng Created this. 16 #include <bpf/libbpf.h> 29 "https://github.com/iovisor/bcc/tree/master/libbpf-tools"; 33 "USAGE: oomkill [-h]\n" 81 ts, e->fpid, e->fcomm, e->tpid, e->tcomm, e->pages, buf); in handle_event() 84 ts, e->fpid, e->fcomm, e->tpid, e->tcomm, e->pages); in handle_event() 134 pb = perf_buffer__new(bpf_map__fd(obj->maps.events), 64, in main() 137 err = -errno; in main() 148 printf("Tracing OOM kills... Ctrl-C to stop.\n"); in main() [all …]
|
| /external/bpftool/scripts/ |
| D | sync-kernel.sh | 4 echo "USAGE: ./sync-kernel.sh <bpftool-repo> <kernel-repo>" 8 …echo " - Update the libbpf submodule, commit, and use its new checkpoints as target commits for b… 9 echo " - Cherry-pick commits from the bpf-next branch, up to the bpf-next target commit." 10 echo " - Cherry-pick commits from the bpf branch, up to the bpf target commit." 11 echo " - Update bpftool's version number based on bpf-next's kernel version and target commit." 12 echo " - Create a new commit with the updated version and checkpoints." 13 echo " - Check consistency." 15 …echo "Set BPF_NEXT_BASELINE to override bpf-next tree commit, otherwise read from <bpftool-repo>/C… 16 …PF_BASELINE to override bpf tree commit, otherwise read from <bpftool-repo>/BPF-CHECKPOINT-COMMIT." 17 …_TIP_COMMIT to override bpf-next tree target commit, otherwise read from <bpftool-repo>/libbpf/CHE… [all …]
|
| /external/bpftool/ |
| D | README.md | 4 This is a mirror of [bpf-next Linux source tree's 5 `tools/bpf/bpftool`](https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf-next.git/tree/tools/bp… 9 All the gory details of syncing can be found in `scripts/sync-kernel.sh` 14 [bpf-next](https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf-next.git/)'s 15 `tools/include/linux/*.h` to make compilation successful. 18 ------------------------------- 22 post](https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf-next.git/tree/tools/bpf/bpftool). 26 it [here](http://vger.kernel.org/vger-lists.html#bpf) and search its archive 37 ------------ 41 - libelf [all …]
|
| /external/bcc/src/cc/ |
| D | README | 1 The libbpf directory is a git submodule for repository 2 https://github.com/libbpf/libbpf 4 If you have any change in libbpf directory, please upstream to linux 5 first as libbpf repo is a mirror of linux/tools/lib/bpf directory. 7 If any top-commit update of libbpf submodule contains a uapi header 10 1. sync compat/linux/virtual_bpf.h with libbpf/include/uapi/linux/bpf.h 14 in bcc:src/cc/libbpf.c.
|
| /external/bcc/ |
| D | CMakeLists.txt | 20 # populate submodules (libbpf) 22 if(NOT EXISTS ${CMAKE_CURRENT_SOURCE_DIR}/src/cc/libbpf/src) 23 execute_process(COMMAND git submodule update --init --recursive 27 message(WARNING "Failed to update submodule libbpf") 30 execute_process(COMMAND git diff --shortstat ${CMAKE_CURRENT_SOURCE_DIR}/src/cc/libbpf/ 33 execute_process(COMMAND git submodule update --init --recursive 37 message(WARNING "Failed to update submodule libbpf") 40 message(WARNING "submodule libbpf dirty, so no sync") 47 # $ cd <kernel-dir> 49 # $ cd <bcc-dir> [all …]
|
| D | INSTALL.md | 3 * [Kernel Configuration](#kernel-configuration) 5 - [Debian](#debian---binary) 6 - [Ubuntu](#ubuntu---binary) 7 - [Fedora](#fedora---binary) 8 - [Arch](#arch---binary) 9 - [Gentoo](#gentoo---portage) 10 - [openSUSE](#opensuse---binary) 11 - [RHEL](#rhel---binary) 12 - [Amazon Linux 1](#amazon-linux-1---binary) 13 - [Amazon Linux 2](#amazon-linux-2---binary) [all …]
|
| /external/bpftool/src/ |
| D | Makefile | 1 # SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) 14 BPF_DIR = $(srctree)/libbpf/src 23 LIBBPF_OUTPUT := $(_OUTPUT)/libbpf/ 27 LIBBPF := $(LIBBPF_OUTPUT)libbpf.a macro 29 LIBBPF_BOOTSTRAP_OUTPUT := $(BOOTSTRAP_OUTPUT)libbpf/ 33 LIBBPF_BOOTSTRAP := $(LIBBPF_BOOTSTRAP_OUTPUT)libbpf.a 36 # libbpf, but still required by bpftool. 45 $(QUIET_MKDIR)mkdir -p $@ 47 $(LIBBPF): $(wildcard $(BPF_DIR)/*.[ch] $(BPF_DIR)/Makefile) | $(LIBBPF_OUTPUT) 48 $(Q)$(MAKE) -C $(BPF_DIR) OBJDIR=$(patsubst %/,%,$(LIBBPF_OUTPUT)) \ [all …]
|
| /external/linux-kselftest/tools/testing/selftests/bpf/ |
| D | vmtest.sh | 2 # SPDX-License-Identifier: GPL-2.0 4 set -u 5 set -e 10 ARCH="$(uname -m)" 13 QEMU_BINARY=qemu-system-s390x 15 QEMU_FLAGS=(-smp 2) 19 QEMU_BINARY=qemu-system-x86_64 21 QEMU_FLAGS=(-cpu host -smp 8) 33 KCONFIG_URL="https://raw.githubusercontent.com/libbpf/libbpf/master/travis-ci/vmtest/configs/config… 34 KCONFIG_API_URL="https://api.github.com/repos/libbpf/libbpf/contents/travis-ci/vmtest/configs/confi… [all …]
|
| D | README.rst | 7 __ /Documentation/bpf/bpf_devel_QA.rst#q-how-to-run-bpf-selftests 13 It's now possible to run the selftests using ``tools/testing/selftests/bpf/vmtest.sh``. 15 would be run post-submit in the CI used by the Maintainers. 19 bpf selftests, runs them (by default ``tools/testing/selftests/bpf/test_progs``) and 23 - clang (preferably built from sources, https://github.com/llvm/llvm-project); 24 - pahole (preferably built from sources, https://git.kernel.org/pub/scm/devel/pahole/pahole.git/); 25 - qemu; 26 - docutils (for ``rst2man``); 27 - libcap-devel. 31 .. code-block:: console [all …]
|
| D | Makefile | 1 # SPDX-License-Identifier: GPL-2.0 19 GENFLAGS := -DHAVE_GENHDR 22 BPF_GCC ?= $(shell command -v bpf-gcc;) 24 CFLAGS += -g -O0 -rdynamic -Wall $(GENFLAGS) $(SAN_CFLAGS) \ 25 -I$(CURDIR) -I$(INCLUDE_DIR) -I$(GENDIR) -I$(LIBDIR) \ 26 -I$(TOOLSINCDIR) -I$(APIDIR) -I$(OUTPUT) 28 LDLIBS += -lcap -lelf -lz -lrt -lpthread 32 CFLAGS += -Wno-unused-command-line-argument 41 test_progs-no_alu32 43 # Also test bpf-gcc, if present [all …]
|
| D | .gitignore | 1 # SPDX-License-Identifier: GPL-2.0-only 2 bpf-helpers* 3 bpf-syscall* 9 FEATURE-DUMP.libbpf 13 /test_progs-no_alu32 14 /test_progs-bpf_gcc 37 /tools
|
| /external/elfutils/ |
| D | Android.bp | 7 // http://www.apache.org/licenses/LICENSE-2.0 16 // CONSULT THE OWNERS AND opensource-licensing@google.com BEFORE 22 // http://go/android-license-faq 27 "SPDX-license-identifier-Apache-2.0", 28 "SPDX-license-identifier-BSD", 29 "SPDX-license-identifier-GFDL", // by exception only 30 "SPDX-license-identifier-GPL-2.0-or-later", 31 "SPDX-license-identifier-GPL-3.0-or-later", 32 "SPDX-license-identifier-LGPL-3.0-or-later", 36 "COPYING-GPLV2", [all …]
|
| /external/libbpf/src/ |
| D | libbpf_internal.h | 1 /* SPDX-License-Identifier: (LGPL-2.1 OR BSD-2-Clause) */ 4 * Internal libbpf helpers. 21 /* make sure libbpf doesn't use kernel-only integer typedefs */ 24 /* prevent accidental re-addition of reallocarray() */ 27 #include "libbpf.h" 93 (offsetof(TYPE, FIELD) + sizeof(((TYPE *)0)->FIELD)) 104 (strncmp(str, pfx, __builtin_constant_p(pfx) ? sizeof(pfx) - 1 : strlen(pfx)) == 0) 141 libbpf_print(level, "libbpf: " fmt, ##__VA_ARGS__); \ 152 * Re-implement glibc's reallocarray() for libbpf internal-only use. 155 * <tools/libc_compat.h> and COMPAT_NEED_REALLOCARRAY. All this complicates [all …]
|
| /external/bcc/.github/workflows/ |
| D | bcc-test.yml | 6 - master 11 runs-on: ubuntu-20.04 16 - TYPE: Debug 19 - TYPE: Debug 22 - TYPE: Release 26 - uses: actions/checkout@v2 27 - name: System info 29 uname -a 31 - name: Build docker container with all deps 34 --build-arg UBUNTU_VERSION=${{ matrix.os.version }} \ [all …]
|