Re: [PATCH bpf-next v2 6/6] bpf: selftests: Add defrag selftests

From: Alexei Starovoitov
Date: Thu Jul 06 2023 - 20:31:33 EST


On Thu, Jul 06, 2023 at 05:25:53PM -0600, Daniel Xu wrote:
> +static int attach(struct ip_check_defrag *skel, bool ipv6)
> +{
> + LIBBPF_OPTS(bpf_netfilter_opts, opts,
> + .pf = ipv6 ? NFPROTO_IPV6 : NFPROTO_IPV4,
> + .priority = 42,
> + .flags = BPF_F_NETFILTER_IP_DEFRAG);

imo the end results is pretty neat. The users would just add this flag and
netfilter bpf prog will see reassembled packets.

The patches look good to me.

Florian,
could you please review/ack, so we can pull them in?