Re: [PATCH bpf] bpf: preallocate a perf_sample_data per event fd
From: Steven Rostedt
Date: Sat Jun 08 2019 - 16:44:11 EST
On Fri, 31 May 2019 05:26:30 +0000
Song Liu <songliubraving@xxxxxx> wrote:
> We can also do something like
>
> ee = kzalloc(sizeof(struct bpf_event_entry) + sizeof(struct perf_sample_data));
> ee->sd = (void *)ee + sizeof(struct bpf_event_entry);
Or perhaps:
ee->sd = (struct perf_sample_data *)(ee + 1);
-- Steve