netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH net-next 0/3] bpf_perf_event_output helper
@ 2015-10-21  3:02 Alexei Starovoitov
  2015-10-21  3:02 ` [PATCH net-next 1/3] perf: pad raw data samples automatically Alexei Starovoitov
                   ` (3 more replies)
  0 siblings, 4 replies; 19+ messages in thread
From: Alexei Starovoitov @ 2015-10-21  3:02 UTC (permalink / raw)
  To: David S. Miller
  Cc: Ingo Molnar, Peter Zijlstra, Wang Nan, He Kuang,
	Arnaldo Carvalho de Melo, Daniel Borkmann, netdev, linux-kernel

Over the last year there were multiple attempts to let eBPF programs
output data into perf events by He Kuang and Wangnan.
The last one was:
https://lkml.org/lkml/2015/7/20/736
It was almost perfect with exception that all bpf programs would sent
data into one global perf_event.
This patch set takes different approach by letting user space
open independent PERF_COUNT_SW_BPF_OUTPUT events, so that program
output won't collide.

Wangnan is working on corresponding perf patches.

Alexei Starovoitov (3):
  perf: pad raw data samples automatically
  bpf: introduce bpf_perf_event_output() helper
  samples: bpf: add bpf_perf_event_output example

 include/uapi/linux/bpf.h        |   11 +++
 include/uapi/linux/perf_event.h |    1 +
 kernel/bpf/arraymap.c           |    2 +
 kernel/bpf/verifier.c           |    3 +-
 kernel/events/core.c            |   15 ++-
 kernel/trace/bpf_trace.c        |   46 +++++++++
 samples/bpf/Makefile            |    7 ++
 samples/bpf/bpf_helpers.h       |    2 +
 samples/bpf/trace_output_kern.c |   31 +++++++
 samples/bpf/trace_output_user.c |  196 +++++++++++++++++++++++++++++++++++++++
 10 files changed, 308 insertions(+), 6 deletions(-)
 create mode 100644 samples/bpf/trace_output_kern.c
 create mode 100644 samples/bpf/trace_output_user.c

-- 
1.7.9.5

^ permalink raw reply	[flat|nested] 19+ messages in thread

end of thread, other threads:[~2015-10-26 10:27 UTC | newest]

Thread overview: 19+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-10-21  3:02 [PATCH net-next 0/3] bpf_perf_event_output helper Alexei Starovoitov
2015-10-21  3:02 ` [PATCH net-next 1/3] perf: pad raw data samples automatically Alexei Starovoitov
2015-10-21  3:02 ` [PATCH net-next 2/3] bpf: introduce bpf_perf_event_output() helper Alexei Starovoitov
2015-10-21 10:01   ` He Kuang
2015-10-21 11:05     ` Wangnan (F)
2015-10-21 20:04       ` Alexei Starovoitov
2015-10-21 12:06   ` Peter Zijlstra
2015-10-21 17:26     ` Alexei Starovoitov
2015-10-21 19:33       ` Peter Zijlstra
2015-10-22 13:59   ` Peter Zijlstra
2015-10-22 15:38     ` Alexei Starovoitov
2015-10-23 14:39   ` Peter Zijlstra
2015-10-23 15:02     ` Alexei Starovoitov
2015-10-23 16:42       ` Peter Zijlstra
2015-10-23 17:25         ` Alexei Starovoitov
2015-10-26  1:46           ` Wangnan (F)
2015-10-26 10:27             ` Alexei Starovoitov
2015-10-21  3:02 ` [PATCH net-next 3/3] samples: bpf: add bpf_perf_event_output example Alexei Starovoitov
2015-10-22 13:42 ` [PATCH net-next 0/3] bpf_perf_event_output helper David Miller

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).