Re: [PATCH v3 1/2] net/af_xdp: add af_xdp rx metadata and dynamic timestamping support
Mark Blasko <[email protected]> Fri, 31 Jul 2026 20:26:25 -0700
| Newsgroups | org.dpdk.dev |
|---|---|
| Message-ID | <CANULgn+54b0z472uvU3FjtLK7O7KxNc4HuN4SKLuRuANqyPQZQ@mail.gmail.com> |
On Sun, Jul 26, 2026 at 10:01=E2=80=AFAM Stephen Hemminger <[email protected]> wrote: > > On Tue, 21 Jul 2026 12:11:27 +0000 > Mark Blasko <[email protected]> wrote: > > > > +xdp_meta_rx_ts_offset > > +~~~~~~~~~~~~~~~~~~~~~ > > + > > +The ``xdp_meta_rx_ts_offset`` argument specifies the byte offset of th= e 64-bit RX > > +timestamp within the XDP metadata headroom area (prepended before pack= et data). > > + > > +.. code-block:: console > > + > > + --vdev net_af_xdp,iface=3Dens786f1,xdp_meta_rx_ts_offset=3D8 > > + > > +xdp_meta_valid_hint_offset > > +~~~~~~~~~~~~~~~~~~~~~~~~~~ > > + > > +The ``xdp_meta_valid_hint_offset`` argument specifies the byte offset = of the validity > > +flag byte within the XDP metadata headroom area. > > + > > +.. code-block:: console > > + > > + --vdev net_af_xdp,iface=3Dens786f1,xdp_meta_rx_ts_offset=3D8,xdp_m= eta_valid_hint_offset=3D4 > > + > > +xdp_meta_rx_ts_valid_mask > > +~~~~~~~~~~~~~~~~~~~~~~~~~ > > + > > +The ``xdp_meta_rx_ts_valid_mask`` argument specifies the bitmask (in h= ex or decimal) used > > +to verify timestamp validity at ``xdp_meta_valid_hint_offset``. > > + > > +.. code-block:: console > > + > > + --vdev net_af_xdp,iface=3Dens786f1,xdp_meta_rx_ts_offset=3D8,xdp_m= eta_valid_hint_offset=3D4,xdp_meta_rx_ts_valid_mask=3D0x1 > > + > > Awkward to have so many new metadata devargs, but I guess if XDP has no m= etadata standard there > is no better way. Maybe combine into one devarg if all are required? Not all parameters are required: `xdp_meta_rx_ts_offset` is the only devarg needed for basic Rx timestamping when timestamps are always valid. `xdp_meta_valid_hint_offset`= and `xdp_meta_rx_ts_valid_mask` are optional parameters used only when the BPF/driver layout provides a per-packet validity hint. Sent v4 with the other review comments addressed.