Re: num_args branch

dave seddon <[email protected]> Wed, 18 Feb 2026 10:02:36 -0800
Newsgroups dev.linux.lists.xdp2
Message-ID <CANypexS1cqrr590L8PN3uyt-hxBHixDsLbZkNodQ3g3wHAV9mw@mail.gmail.com>
G'day,

I hope you are doing well.

I have a basic virtual machine based test that:
1. Spins up the VM
2. Verifies boot
3. VM itself attaches the ebpf code to an interface.  This obviously
causes the ebpf verifier to run.
4. Script then verifies the attachment to the interface
5. Shuts down

Hopefully this is enough for the initial implementation.  Obviously,
it would be nice to actually send some packets to see that the ebpf
code <does the thing>, but that can come later.

I've done this for x86, because this was the quickest thing to get
working.  I'll now start on adding more architectures.  I assume you
what riscv 32 and 64.

How long will it take?  "Prediction is very difficult =E2=80=94 especially
about the future".  Maybe a few more days?  I could be very wrong.

Thanks,
Dave

On Mon, Feb 16, 2026 at 5:03=E2=80=AFPM dave seddon <[email protected]=
om> wrote:
>
> G'day,
>
> I just got all the samples working with the 5 args.  Awesome!
>
> Changing common_parser.template.c was required to get parser_tmpl -O work=
ing
>
> --------------------
> [das@l:~/Downloads/xdp2]$ git diff src/templates/xdp2/common_parser.templ=
ate.c
> diff --git a/src/templates/xdp2/common_parser.template.c
> b/src/templates/xdp2/common_parser.template.c
> index 82792e6..91f5bb3 100644
> --- a/src/templates/xdp2/common_parser.template.c
> +++ b/src/templates/xdp2/common_parser.template.c
> @@ -50,7 +50,7 @@ static inline __unused() int
>         <!--(end)-->
>
>         ret =3D __@!parser_name!@_@!root_name!@_xdp2_parse(
> -                       parser, hdr, len, metadata, frame, 0, ctrl, flags=
);
> +                       parser, hdr, len, metadata, &frame, 0, ctrl, flag=
s);
>
>         ctrl->var.ret_code =3D ret;
>
>
> [das@l:~/Downloads/xdp2]$
> --------------------
>
> Starting to work on the samples/xdp/ next
>
> Thanks!
> Dave
>
> On Sun, Feb 15, 2026 at 8:14=E2=80=AFPM dave seddon <dave.seddon.ca@gmail=
.com> wrote:
> >
> > Awesome.  Thanks for the update.  I'll try to take a look tomorrow.
> >
> >
> > On Sun, Feb 15, 2026 at 5:21=E2=80=AFPM Tom Herbert <[email protected]=
m> wrote:
> > >
> > > HI,
> > >
> > > I added a num_args branch in xdp2-dev/xdp2 that has the proposed fix =
for the handlers and metadata extraction functions exceeding the five argum=
ent limit of eBPF. Haven't tested much yet. Please give it a try if you can=
.
> > >
> > > Tom
> > >
> >
> >
> > --
> > Regards,
> > Dave Seddon
> > +1 415 857 5102
>
>
>
> --
> Regards,
> Dave Seddon
> +1 415 857 5102



--=20
Regards,
Dave Seddon
+1 415 857 5102