[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <67be0b60a6b36_25ccfc294f5@willemb.c.googlers.com.notmuch>
Date: Tue, 25 Feb 2025 13:26:40 -0500
From: Willem de Bruijn <willemdebruijn.kernel@...il.com>
To: Marcus Wichelmann <marcus.wichelmann@...zner-cloud.de>,
netdev@...r.kernel.org,
linux-kernel@...r.kernel.org,
bpf@...r.kernel.org,
linux-kselftest@...r.kernel.org
Cc: willemdebruijn.kernel@...il.com,
jasowang@...hat.com,
andrew+netdev@...n.ch,
davem@...emloft.net,
edumazet@...gle.com,
kuba@...nel.org,
pabeni@...hat.com,
andrii@...nel.org,
eddyz87@...il.com,
mykolal@...com,
ast@...nel.org,
daniel@...earbox.net,
martin.lau@...ux.dev,
song@...nel.org,
yonghong.song@...ux.dev,
john.fastabend@...il.com,
kpsingh@...nel.org,
sdf@...ichev.me,
haoluo@...gle.com,
jolsa@...nel.org,
shuah@...nel.org,
hawk@...nel.org,
marcus.wichelmann@...zner-cloud.de
Subject: Re: [PATCH bpf-next v3 2/6] net: tun: enable transfer of XDP metadata
to skb
Marcus Wichelmann wrote:
> When the XDP metadata area was used, it is expected that the same
> metadata can also be accessed from TC, as can be read in the description
> of the bpf_xdp_adjust_meta helper function. In the tun driver, this was
> not yet implemented.
>
> To make this work, the skb that is being built on XDP_PASS should know
> of the current size of the metadata area. This is ensured by adding
> calls to skb_metadata_set. For the tun_xdp_one code path, an additional
> check is necessary to handle the case where the externally initialized
> xdp_buff has no metadata support (xdp->data_meta == xdp->data + 1).
>
> More information about this feature can be found in the commit message
> of commit de8f3a83b0a0 ("bpf: add meta pointer for direct access").
>
> Signed-off-by: Marcus Wichelmann <marcus.wichelmann@...zner-cloud.de>
Reviewed-by: Willem de Bruijn <willemb@...gle.com>
Powered by blists - more mailing lists