Re: [PATCH 1/3] bpf: respect size hint to BPF_PROG_TEST_RUN if present

2018-11-17 Thread Y Song
On Fri, Nov 16, 2018 at 12:54 PM Lorenz Bauer wrote: > > Use data_size_out as a size hint when copying test output to user space. > A program using BPF_PERF_OUTPUT can compare its own buffer length with > data_size_out after the syscall to detect whether truncation has taken > place. Callers which

[PATCH 1/3] bpf: respect size hint to BPF_PROG_TEST_RUN if present

2018-11-16 Thread Lorenz Bauer
Use data_size_out as a size hint when copying test output to user space. A program using BPF_PERF_OUTPUT can compare its own buffer length with data_size_out after the syscall to detect whether truncation has taken place. Callers which so far did not set data_size_in are not affected. Signed-off-b