Re: [PATCH bpf-next v3 08/21] bpf: implement common macros/helpers for target iterators

2020-05-11 Thread Andrii Nakryiko
On Fri, May 8, 2020 at 8:18 PM Yonghong Song wrote: > > > > On 5/8/20 12:07 PM, Andrii Nakryiko wrote: > > On Wed, May 6, 2020 at 10:40 PM Yonghong Song wrote: > >> > >> Macro DEFINE_BPF_ITER_FUNC is implemented so target > >> can define an init function to capture the BTF type > >> which represe

Re: [PATCH bpf-next v3 08/21] bpf: implement common macros/helpers for target iterators

2020-05-08 Thread Yonghong Song
On 5/8/20 12:07 PM, Andrii Nakryiko wrote: On Wed, May 6, 2020 at 10:40 PM Yonghong Song wrote: Macro DEFINE_BPF_ITER_FUNC is implemented so target can define an init function to capture the BTF type which represents the target. The bpf_iter_meta is a structure holding meta data, common to

Re: [PATCH bpf-next v3 08/21] bpf: implement common macros/helpers for target iterators

2020-05-08 Thread Andrii Nakryiko
On Wed, May 6, 2020 at 10:40 PM Yonghong Song wrote: > > Macro DEFINE_BPF_ITER_FUNC is implemented so target > can define an init function to capture the BTF type > which represents the target. > > The bpf_iter_meta is a structure holding meta data, common > to all targets in the bpf program. > >

[PATCH bpf-next v3 08/21] bpf: implement common macros/helpers for target iterators

2020-05-06 Thread Yonghong Song
Macro DEFINE_BPF_ITER_FUNC is implemented so target can define an init function to capture the BTF type which represents the target. The bpf_iter_meta is a structure holding meta data, common to all targets in the bpf program. Additional marker functions are called before or after bpf_seq_read()