blob: 38b4db8be7a2b920bdf6bd7c85246a40b14bd796 [file] [log] [blame]
Jesper Dangaard Brouer4712c1b2018-05-14 15:42:12 +02001=================
Tobin C. Harding6919bcc2018-07-26 15:03:05 +10002BPF Documentation
Jesper Dangaard Brouer4712c1b2018-05-14 15:42:12 +02003=================
4
5This directory contains documentation for the BPF (Berkeley Packet
6Filter) facility, with a focus on the extended BPF version (eBPF).
7
8This kernel side documentation is still work in progress. The main
9textual documentation is (for historical reasons) described in
Mauro Carvalho Chehabcb3f0d52020-04-28 00:01:36 +020010`Documentation/networking/filter.rst`_, which describe both classical
Jesper Dangaard Brouer4712c1b2018-05-14 15:42:12 +020011and extended BPF instruction-set.
12The Cilium project also maintains a `BPF and XDP Reference Guide`_
13that goes into great technical depth about the BPF Architecture.
14
15The primary info for the bpf syscall is available in the `man-pages`_
16for `bpf(2)`_.
17
Yonghong Songffcf7ce2019-01-18 13:56:49 -080018BPF Type Format (BTF)
19=====================
20
21.. toctree::
22 :maxdepth: 1
23
24 btf
Jesper Dangaard Brouer4712c1b2018-05-14 15:42:12 +020025
26
27Frequently asked questions (FAQ)
28================================
29
30Two sets of Questions and Answers (Q&A) are maintained.
31
Tobin C. Hardingb3d40f62018-07-26 15:03:03 +100032.. toctree::
33 :maxdepth: 1
Jesper Dangaard Brouer4712c1b2018-05-14 15:42:12 +020034
Tobin C. Hardingb3d40f62018-07-26 15:03:03 +100035 bpf_design_QA
36 bpf_devel_QA
Jesper Dangaard Brouer4712c1b2018-05-14 15:42:12 +020037
38
Andrey Ignatovda703142019-04-17 22:28:57 -070039Program types
40=============
41
42.. toctree::
43 :maxdepth: 1
44
Stanislav Fomichev0c51b362019-06-27 13:38:54 -070045 prog_cgroup_sockopt
Andrey Ignatovda703142019-04-17 22:28:57 -070046 prog_cgroup_sysctl
Stanislav Fomichev80695942019-04-18 16:47:52 -070047 prog_flow_dissector
KP Singh4dece7f2020-03-29 01:43:56 +010048 bpf_lsm
Andrey Ignatovda703142019-04-17 22:28:57 -070049
50
Andrey Ignatov8c061862020-03-24 11:51:35 -070051Testing and debugging BPF
52=========================
Ilya Leoshkevich7e07e7a2019-10-29 18:29:16 +010053
54.. toctree::
55 :maxdepth: 1
56
Andrey Ignatov8c061862020-03-24 11:51:35 -070057 drgn
Ilya Leoshkevich7e07e7a2019-10-29 18:29:16 +010058 s390
59
60
Jesper Dangaard Brouer4712c1b2018-05-14 15:42:12 +020061.. Links:
Mauro Carvalho Chehabcb3f0d52020-04-28 00:01:36 +020062.. _Documentation/networking/filter.rst: ../networking/filter.txt
Jesper Dangaard Brouer4712c1b2018-05-14 15:42:12 +020063.. _man-pages: https://www.kernel.org/doc/man-pages/
64.. _bpf(2): http://man7.org/linux/man-pages/man2/bpf.2.html
65.. _BPF and XDP Reference Guide: http://cilium.readthedocs.io/en/latest/bpf/