Commit | Line | Data |
---|---|---|
4712c1b2 | 1 | ================= |
6919bcc8 | 2 | BPF Documentation |
4712c1b2 JDB |
3 | ================= |
4 | ||
5 | This directory contains documentation for the BPF (Berkeley Packet | |
6 | Filter) facility, with a focus on the extended BPF version (eBPF). | |
7 | ||
ffba964e | 8 | This kernel side documentation is still work in progress. The main |
4712c1b2 | 9 | textual documentation is (for historical reasons) described in |
ffba964e TY |
10 | :ref:`networking-filter`, which describe both classical and extended |
11 | BPF instruction-set. | |
4712c1b2 JDB |
12 | The Cilium project also maintains a `BPF and XDP Reference Guide`_ |
13 | that goes into great technical depth about the BPF Architecture. | |
14 | ||
f42cfb46 GS |
15 | libbpf |
16 | ====== | |
17 | ||
18 | Libbpf is a userspace library for loading and interacting with bpf programs. | |
19 | ||
20 | .. toctree:: | |
21 | :maxdepth: 1 | |
22 | ||
23 | libbpf/libbpf | |
24 | libbpf/libbpf_api | |
25 | libbpf/libbpf_build | |
26 | libbpf/libbpf_naming_convention | |
27 | ||
ffcf7ce9 YS |
28 | BPF Type Format (BTF) |
29 | ===================== | |
30 | ||
31 | .. toctree:: | |
32 | :maxdepth: 1 | |
33 | ||
34 | btf | |
4712c1b2 JDB |
35 | |
36 | ||
37 | Frequently asked questions (FAQ) | |
38 | ================================ | |
39 | ||
40 | Two sets of Questions and Answers (Q&A) are maintained. | |
41 | ||
b3d40f63 TH |
42 | .. toctree:: |
43 | :maxdepth: 1 | |
4712c1b2 | 44 | |
b3d40f63 TH |
45 | bpf_design_QA |
46 | bpf_devel_QA | |
4712c1b2 | 47 | |
6197e5b7 JS |
48 | Syscall API |
49 | =========== | |
50 | ||
51 | The primary info for the bpf syscall is available in the `man-pages`_ | |
52 | for `bpf(2)`_. For more information about the userspace API, see | |
53 | Documentation/userspace-api/ebpf/index.rst. | |
4712c1b2 | 54 | |
a62f68c1 JS |
55 | Helper functions |
56 | ================ | |
57 | ||
58 | * `bpf-helpers(7)`_ maintains a list of helpers available to eBPF programs. | |
59 | ||
60 | ||
da703149 AI |
61 | Program types |
62 | ============= | |
63 | ||
64 | .. toctree:: | |
65 | :maxdepth: 1 | |
66 | ||
0c51b369 | 67 | prog_cgroup_sockopt |
da703149 | 68 | prog_cgroup_sysctl |
80695946 | 69 | prog_flow_dissector |
4dece7f3 | 70 | bpf_lsm |
07ff4f01 | 71 | prog_sk_lookup |
da703149 AI |
72 | |
73 | ||
4e15f460 YZ |
74 | Map types |
75 | ========= | |
76 | ||
77 | .. toctree:: | |
78 | :maxdepth: 1 | |
79 | ||
80 | map_cgroup_storage | |
81 | ||
82 | ||
8c061865 AI |
83 | Testing and debugging BPF |
84 | ========================= | |
7e07e7ae IL |
85 | |
86 | .. toctree:: | |
87 | :maxdepth: 1 | |
88 | ||
8c061865 | 89 | drgn |
7e07e7ae IL |
90 | s390 |
91 | ||
92 | ||
5fe52b38 DA |
93 | Other |
94 | ===== | |
95 | ||
96 | .. toctree:: | |
97 | :maxdepth: 1 | |
98 | ||
99 | ringbuf | |
fc8c262e | 100 | llvm_reloc |
5fe52b38 | 101 | |
4712c1b2 | 102 | .. Links: |
ffba964e | 103 | .. _networking-filter: ../networking/filter.rst |
4712c1b2 | 104 | .. _man-pages: https://www.kernel.org/doc/man-pages/ |
ffba964e | 105 | .. _bpf(2): https://man7.org/linux/man-pages/man2/bpf.2.html |
a62f68c1 | 106 | .. _bpf-helpers(7): https://man7.org/linux/man-pages/man7/bpf-helpers.7.html |
ffba964e | 107 | .. _BPF and XDP Reference Guide: https://docs.cilium.io/en/latest/bpf/ |