]> git.baikalelectronics.ru Git - kernel.git/commit
bpf, trace: add BPF_F_CURRENT_CPU flag for bpf_perf_event_read
authorDaniel Borkmann <daniel@iogearbox.net>
Tue, 28 Jun 2016 10:18:25 +0000 (12:18 +0200)
committerDavid S. Miller <davem@davemloft.net>
Thu, 30 Jun 2016 09:54:40 +0000 (05:54 -0400)
commit30e2979e6c331efb160d0386067650581be1013a
tree99a35abec2ab665d9cd72ae8f143b544d5eef923
parent31798bab91f7ca4f2d8857910d3c80cb5773536f
bpf, trace: add BPF_F_CURRENT_CPU flag for bpf_perf_event_read

Follow-up commit to 4e26aebc99cf ("bpf, trace: add BPF_F_CURRENT_CPU
flag for bpf_perf_event_output") to add the same functionality into
bpf_perf_event_read() helper. The split of index into flags and index
component is also safe here, since such large maps are rejected during
map allocation time.

Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
Acked-by: Alexei Starovoitov <ast@kernel.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
include/uapi/linux/bpf.h
kernel/trace/bpf_trace.c