Hi David, The following pull-request contains BPF updates for your *net-next* tree.
The main changes are: 1) Add cgroup local storage for BPF programs, which provides a fast accessible memory for storing various per-cgroup data like number of transmitted packets, etc, from Roman. 2) Support bpf_get_socket_cookie() BPF helper in several more program types that have a full socket available, from Andrey. 3) Significantly improve the performance of perf events which are reported from BPF offload. Also convert a couple of BPF AF_XDP samples overto use libbpf, both from Jakub. 4) seg6local LWT provides the End.DT6 action, which allows to decapsulate an outer IPv6 header containing a Segment Routing Header. Adds this action now to the seg6local BPF interface, from Mathieu. 5) Do not mark dst register as unbounded in MOV64 instruction when both src and dst register are the same, from Arthur. 6) Define u_smp_rmb() and u_smp_wmb() to their respective barrier instructions on arm64 for the AF_XDP sample code, from Brian. 7) Convert the tcp_client.py and tcp_server.py BPF selftest scripts over from Python 2 to Python 3, from Jeremy. 8) Enable BTF build flags to the BPF sample code Makefile, from Taeung. 9) Remove an unnecessary rcu_read_lock() in run_lwt_bpf(), from Taehee. 10) Several improvements to the README.rst from the BPF documentation to make it more consistent with RST format, from Tobin. 11) Replace all occurrences of strerror() by calls to strerror_r() in libbpf and fix a FORTIFY_SOURCE build error along with it, from Thomas. 12) Fix a bug in bpftool's get_btf() function to correctly propagate an error via PTR_ERR(), from Yue. Please consider pulling these changes from: git://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf-next.git Thanks a lot! ---------------------------------------------------------------- The following changes since commit aea5f654e6b78a0c976f7a25950155932c77a53f: net/sched: add skbprio scheduler (2018-07-24 14:44:00 -0700) are available in the git repository at: git://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf-next.git for you to fetch changes up to 85fc4b16aaf05fc8978d242c556a1711dce15cf8: bpf: introduce update_effective_progs() (2018-08-07 14:29:55 +0200) ---------------------------------------------------------------- Andrey Ignatov (4): bpf: Support bpf_get_socket_cookie in more prog types bpf: Sync bpf.h to tools/ selftests/bpf: Add bpf_get_socket_cookie to bpf_helpers.h selftests/bpf: Test for get_socket_cookie Arthur Fabre (1): bpf: verifier: MOV64 don't mark dst reg unbounded Brian Brooks (1): samples/bpf: xdpsock: order memory on AArch64 Daniel Borkmann (4): Merge branch 'bpf-nfp-perf-event-improvements' Merge branch 'bpf-convert-more-samples' Merge branch 'bpf-docs-rst-improvements' Merge branch 'bpf-cgroup-local-storage' Jakub Kicinski (12): nfp: move repr handling on RX path nfp: allow control message reception on data queues nfp: bpf: pass raw data buffer to nfp_bpf_event_output() nfp: bpf: allow receiving perf events on data queues nfp: bpf: remember maps by ID nfp: bpf: improve map offload info messages tools: libbpf: handle NULL program gracefully in bpf_program__nth_fd() tools: libbpf: add bpf_object__find_program_by_title() samples: bpf: convert xdp_fwd_user.c to libbpf samples: bpf: convert xdpsock_user.c to libbpf nfp: fix variable dereferenced before check in nfp_app_ctrl_rx_raw() nfp: bpf: xdp_adjust_tail support Jeremy Cline (1): bpf: Add Python 3 support to selftests scripts for bpf Mathieu Xhonneux (1): bpf: add End.DT6 action to bpf_lwt_seg6_action helper Roman Gushchin (16): bpf: add ability to charge bpf maps memory dynamically bpf: introduce cgroup storage maps bpf: pass a pointer to a cgroup storage using pcpu variable bpf: allocate cgroup storage entries on attaching bpf programs bpf: extend bpf_prog_array to store pointers to the cgroup storage bpf/verifier: introduce BPF_PTR_TO_MAP_VALUE bpf: don't allow create maps of cgroup local storages bpf: introduce the bpf_get_local_storage() helper function bpf: sync bpf.h to tools/ bpftool: add support for CGROUP_STORAGE maps bpf/test_run: support cgroup local storage selftests/bpf: add verifier cgroup storage tests selftests/bpf: add a cgroup storage test samples/bpf: extend test_cgrp2_attach2 test to use cgroup storage selftests/bpf: fix a typo in map in map test bpf: introduce update_effective_progs() Taehee Yoo (1): lwt_bpf: remove unnecessary rcu_read_lock in run_lwt_bpf Taeung Song (2): tools/bpftool: ignore build products samples/bpf: Add BTF build flags to Makefile Thomas Richter (1): bpf: fix build error in libbpf with EXTRA_CFLAGS="-Wp, -D_FORTIFY_SOURCE=2 -O2" Tobin C. Harding (4): docs: bpf: Rename README.rst to index.rst docs: bpf: Add toctree to index docs: Add bpf/index to top level index docs: bpf: Capitalise document heading YueHaibing (1): bpf: btf: fix inconsistent IS_ERR and PTR_ERR Documentation/bpf/{README.rst => index.rst} | 10 +- Documentation/index.rst | 1 + drivers/media/rc/bpf-lirc.c | 10 +- drivers/net/ethernet/netronome/nfp/bpf/cmsg.c | 25 +- drivers/net/ethernet/netronome/nfp/bpf/fw.h | 1 + drivers/net/ethernet/netronome/nfp/bpf/jit.c | 59 +++- drivers/net/ethernet/netronome/nfp/bpf/main.c | 18 +- drivers/net/ethernet/netronome/nfp/bpf/main.h | 11 +- drivers/net/ethernet/netronome/nfp/bpf/offload.c | 63 ++-- drivers/net/ethernet/netronome/nfp/bpf/verifier.c | 7 + drivers/net/ethernet/netronome/nfp/nfp_app.c | 2 + drivers/net/ethernet/netronome/nfp/nfp_app.h | 18 + drivers/net/ethernet/netronome/nfp/nfp_asm.h | 1 + .../net/ethernet/netronome/nfp/nfp_net_common.c | 40 ++- drivers/net/ethernet/netronome/nfp/nfp_net_ctrl.h | 1 + include/linux/bpf-cgroup.h | 54 +++ include/linux/bpf.h | 25 +- include/linux/bpf_types.h | 3 + include/net/seg6_local.h | 4 +- include/uapi/linux/bpf.h | 41 ++- kernel/bpf/Makefile | 1 + kernel/bpf/cgroup.c | 157 +++++---- kernel/bpf/core.c | 77 +++-- kernel/bpf/helpers.c | 20 ++ kernel/bpf/local_storage.c | 378 +++++++++++++++++++++ kernel/bpf/map_in_map.c | 3 +- kernel/bpf/syscall.c | 61 +++- kernel/bpf/verifier.c | 44 ++- net/bpf/test_run.c | 13 +- net/core/filter.c | 139 ++++++-- net/core/lwt_bpf.c | 2 - net/ipv6/seg6_local.c | 50 ++- samples/bpf/Makefile | 21 +- samples/bpf/test_cgrp2_attach2.c | 21 +- samples/bpf/xdp_fwd_user.c | 34 +- samples/bpf/xdpsock_user.c | 43 ++- tools/bpf/.gitignore | 5 + tools/bpf/bpftool/.gitignore | 2 + tools/bpf/bpftool/map.c | 3 +- tools/include/uapi/linux/bpf.h | 41 ++- tools/lib/bpf/libbpf.c | 57 +++- tools/lib/bpf/libbpf.h | 3 + tools/testing/selftests/bpf/Makefile | 7 +- tools/testing/selftests/bpf/bpf_helpers.h | 4 + tools/testing/selftests/bpf/socket_cookie_prog.c | 60 ++++ tools/testing/selftests/bpf/tcp_client.py | 12 +- tools/testing/selftests/bpf/tcp_server.py | 16 +- tools/testing/selftests/bpf/test_cgroup_storage.c | 130 +++++++ tools/testing/selftests/bpf/test_socket_cookie.c | 225 ++++++++++++ tools/testing/selftests/bpf/test_verifier.c | 172 +++++++++- 50 files changed, 1894 insertions(+), 301 deletions(-) rename Documentation/bpf/{README.rst => index.rst} (82%) create mode 100644 kernel/bpf/local_storage.c create mode 100644 tools/bpf/.gitignore create mode 100644 tools/testing/selftests/bpf/socket_cookie_prog.c create mode 100644 tools/testing/selftests/bpf/test_cgroup_storage.c create mode 100644 tools/testing/selftests/bpf/test_socket_cookie.c