From: Jesper Dangaard Brouer <brouer@redhat•com>
To: Kurt Kanzenbach <kurt@linutronix•de>
Cc: brouer@redhat•com, Jesse Brandeburg <jesse.brandeburg@intel•com>,
Tony Nguyen <anthony.l.nguyen@intel•com>,
"David S. Miller" <davem@davemloft•net>,
Jakub Kicinski <kuba@kernel•org>,
Alexei Starovoitov <ast@kernel•org>,
Daniel Borkmann <daniel@iogearbox•net>,
Jesper Dangaard Brouer <hawk@kernel•org>,
John Fastabend <john.fastabend@gmail•com>,
Sven Auhagen <sven.auhagen@voleatech•de>,
intel-wired-lan@lists•osuosl.org, netdev@vger•kernel.org,
bpf@vger•kernel.org,
Ilias Apalodimas <ilias.apalodimas@linaro•org>,
Lorenzo Bianconi <lorenzo@kernel•org>,
Sebastian Andrzej Siewior <bigeasy@linutronix•de>,
Richard Cochran <richardcochran@gmail•com>,
Alexander Duyck <alexander.duyck@gmail•com>,
Tyler S <tylerjstachecki@gmail•com>,
Maciej Fijalkowski <maciej.fijalkowski@intel•com>
Subject: Re: [PATCH net v4] igb: Fix XDP with PTP enabled
Date: Tue, 4 May 2021 10:28:27 +0200 [thread overview]
Message-ID: <20210504102827.342f6302@carbon> (raw)
In-Reply-To: <20210503072800.79936-1-kurt@linutronix.de>
On Mon, 3 May 2021 09:28:00 +0200
Kurt Kanzenbach <kurt@linutronix•de> wrote:
> When using native XDP with the igb driver, the XDP frame data doesn't point to
> the beginning of the packet. It's off by 16 bytes. Everything works as expected
> with XDP skb mode.
>
> Actually these 16 bytes are used to store the packet timestamps. Therefore, pull
> the timestamp before executing any XDP operations and adjust all other code
> accordingly. The igc driver does it like that as well.
>
> Tested with Intel i210 card and AF_XDP sockets.
>
> Fixes: 9cbc948b5a20 ("igb: add XDP support")
> Signed-off-by: Kurt Kanzenbach <kurt@linutronix•de>
Thanks for fixing this!
Acked-by: Jesper Dangaard Brouer <brouer@redhat•com>
I expect that we/I will (soon) play with getting this area that is
stored in front of the packet (the XDP data_meta area) described via
BTF. This way both xdp_frame and AF_XDP can get structured access (e.g.
to the PTP timestamp in this case).
I'll be adding my notes on this project here:
https://github.com/xdp-project/xdp-project/blob/master/areas/tsn/
Looking forward to collaborate on this with you :-)
--
Best regards,
Jesper Dangaard Brouer
MSc.CS, Principal Kernel Engineer at Red Hat
LinkedIn: http://www.linkedin.com/in/brouer
next prev parent reply other threads:[~2021-05-04 8:28 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-05-03 7:28 [PATCH net v4] igb: Fix XDP with PTP enabled Kurt Kanzenbach
2021-05-04 8:28 ` Jesper Dangaard Brouer [this message]
2021-05-19 13:34 ` Jesper Dangaard Brouer
2021-05-19 18:46 ` Nguyen, Anthony L
2021-05-20 6:20 ` Kurt Kanzenbach
2021-06-03 11:30 ` Penigalapati, Sandeep
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20210504102827.342f6302@carbon \
--to=brouer@redhat$(echo .)com \
--cc=alexander.duyck@gmail$(echo .)com \
--cc=anthony.l.nguyen@intel$(echo .)com \
--cc=ast@kernel$(echo .)org \
--cc=bigeasy@linutronix$(echo .)de \
--cc=bpf@vger$(echo .)kernel.org \
--cc=daniel@iogearbox$(echo .)net \
--cc=davem@davemloft$(echo .)net \
--cc=hawk@kernel$(echo .)org \
--cc=ilias.apalodimas@linaro$(echo .)org \
--cc=intel-wired-lan@lists$(echo .)osuosl.org \
--cc=jesse.brandeburg@intel$(echo .)com \
--cc=john.fastabend@gmail$(echo .)com \
--cc=kuba@kernel$(echo .)org \
--cc=kurt@linutronix$(echo .)de \
--cc=lorenzo@kernel$(echo .)org \
--cc=maciej.fijalkowski@intel$(echo .)com \
--cc=netdev@vger$(echo .)kernel.org \
--cc=richardcochran@gmail$(echo .)com \
--cc=sven.auhagen@voleatech$(echo .)de \
--cc=tylerjstachecki@gmail$(echo .)com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox