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

2020-05-05 Thread Andrii Nakryiko
On Tue, May 5, 2020 at 1:30 PM Yonghong Song wrote: > > > > On 5/5/20 1:25 PM, Andrii Nakryiko wrote: > > On Sun, May 3, 2020 at 11:28 PM Yonghong Song wrote: > >> > >> Macro DEFINE_BPF_ITER_FUNC is implemented so target > >> can define an init function to capture the BTF type > >> which represen

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

2020-05-05 Thread Yonghong Song
On 5/5/20 1:25 PM, Andrii Nakryiko wrote: On Sun, May 3, 2020 at 11:28 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 v2 08/20] bpf: implement common macros/helpers for target iterators

2020-05-05 Thread Andrii Nakryiko
On Sun, May 3, 2020 at 11:28 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 v2 08/20] bpf: implement common macros/helpers for target iterators

2020-05-03 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/after bpf_seq_read() sho