Re: Allow bpf_perf_event_output to access packet data

2018-09-11 Thread Lorenz Bauer
On 10 September 2018 at 09:26, Jakub Kicinski wrote: > The 0x20ULL will mean use the index in the map for current CPU > (0x), and output 32 bytes of the context (0x20 << 32). For > networking programs context means the packet (slightly confusingly). > > These are the relevant defi

Re: Allow bpf_perf_event_output to access packet data

2018-09-10 Thread Jakub Kicinski
On Fri, 7 Sep 2018 15:56:15 +0100, Lorenz Bauer wrote: > Hello list, > > I'm attempting to use bpf_perf_event_output to do packet sampling from XDP. > > The code basically runs before our other XDP code, does a > perf_event_output with the full packet (for now) and then tail calls > into DDoS mit

Allow bpf_perf_event_output to access packet data

2018-09-07 Thread Lorenz Bauer
Re-sent due to HTML e-mail mess up, apologies. -- Forwarded message -- From: Lorenz Bauer Date: 7 September 2018 at 15:53 Subject: Allow bpf_perf_event_output to access packet data To: netdev@vger.kernel.org, Alexei Starovoitov , Daniel Borkmann Hello list, I'm attempti