Re: pull-request: bpf-next 2018-03-21

2018-03-21 Thread David Miller
From: Daniel Borkmann 
Date: Wed, 21 Mar 2018 02:29:14 +0100

> The following pull-request contains BPF updates for your *net-next* tree.

Pulled, thanks Daniel.


pull-request: bpf-next 2018-03-21

2018-03-20 Thread Daniel Borkmann
Hi David,

The following pull-request contains BPF updates for your *net-next* tree.

The main changes are:

1) Add a BPF hook for sendmsg and sendfile by reusing the ULP infrastructure
   and sockmap. Three helpers are added along with this, bpf_msg_apply_bytes(),
   bpf_msg_cork_bytes(), and bpf_msg_pull_data(). The first is used to tell
   for how many bytes the verdict should be applied to, the second to tell
   that x bytes need to be queued first to retrigger the BPF program for a
   verdict, and the third helper is mainly for the sendfile case to pull in
   data for making it private for reading and/or writing, from John.

2) Improve address to symbol resolution of user stack traces in BPF stackmap.
   Currently, the latter stores the address for each entry in the call trace,
   however to map these addresses to user space files, it is necessary to
   maintain the mapping from these virtual addresses to symbols in the binary
   which is not practical for system-wide profiling. Instead, this option for
   the stackmap rather stores the ELF build id and offset for the call trace
   entries, from Song.

3) Add support that allows BPF programs attached to perf events to read the
   address values recorded with the perf events. They are requested through
   PERF_SAMPLE_ADDR via perf_event_open(). Main motivation behind it is to
   support building memory or lock access profiling and tracing tools with
   the help of BPF, from Teng.

4) Several improvements to the tools/bpf/ Makefiles. The 'make bpf' in the
   tools directory does not provide the standard quiet output except for
   bpftool and it also does not respect specifying a build output directory.
   'make bpf_install' command neither respects specified destination nor
   prefix, all from Jiri. In addition, Jakub fixes several other minor issues
   in the Makefiles on top of that, e.g. fixing dependency paths, phony
   targets and more.

5) Various doc updates e.g. add a comment for BPF fs about reserved names
   to make the dentry lookup from there a bit more obvious, and a comment
   to the bpf_devel_QA file in order to explain the diff between native
   and bpf target clang usage with regards to pointer size, from Quentin
   and Daniel.

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 a366e300ae9fc466d333e6d8f2bc5d58ed248041:

  ip6mr: remove synchronize_rcu() in favor of SOCK_RCU_FREE (2018-03-07 
18:13:41 -0500)

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 78262f4575c29f185947fe58952cd1beabc74f82:

  bpf, doc: add description wrt native/bpf clang target and pointer size 
(2018-03-20 15:47:45 -0700)


Daniel Borkmann (6):
  Merge branch 'bpf-perf-sample-addr'
  Merge branch 'bpf-tools-makefile-improvements'
  Merge branch 'bpf-stackmap-build-id'
  Merge branch 'bpf-tools-build-improvements'
  Merge branch 'bpf-sockmap-ulp'
  bpf, doc: add description wrt native/bpf clang target and pointer size

Jakub Kicinski (4):
  tools: bpftool: fix dependency file path
  tools: bpftool: fix potential format truncation
  tools: bpf: cleanup PHONY target
  tools: bpf: remove feature detection output

Jiri Benc (7):
  tools: bpftool: silence 'missing initializer' warnings
  tools: bpf: respect output directory during build
  tools: bpf: consistent make bpf_install
  tools: bpf: make install should build first
  tools: bpf: call descend in Makefile
  tools: bpf: respect quiet/verbose build
  tools: bpf: silence make by not deleting intermediate file

John Fastabend (18):
  sock: make static tls function alloc_sg generic sock helper
  sockmap: convert refcnt to an atomic refcnt
  net: do_tcp_sendpages flag to avoid SKBTX_SHARED_FRAG
  net: generalize sk_alloc_sg to work with scatterlist rings
  bpf: create tcp_bpf_ulp allowing BPF to monitor socket TX/RX data
  bpf: sockmap, add bpf_msg_apply_bytes() helper
  bpf: sockmap, add msg_cork_bytes() helper
  bpf: sk_msg program helper bpf_sk_msg_pull_data
  bpf: add map tests for BPF_PROG_TYPE_SK_MSG
  bpf: add verifier tests for BPF_PROG_TYPE_SK_MSG
  bpf: sockmap sample, add option to attach SK_MSG program
  bpf: sockmap sample, add sendfile test
  bpf: sockmap sample, add data verification option
  bpf: sockmap, add sample option to test apply_bytes helper
  bpf: sockmap sample support for bpf_msg_cork_bytes()
  bpf: sockmap add SK_DROP tests
  bpf: sockmap sample test for bpf_msg_pull_data
  bpf: sockmap test script

Quentin Monnet (1):
  bpf: comment why dots in filenames under BPF virtual FS are not allowed

Song Liu (2):
  bpf: