public inbox for netdev@vger.kernel.org
 help / color / mirror / Atom feed
From: Martin KaFai Lau <martin.lau@linux.dev>
To: nhudson@akamai.com
Cc: bot+bpf-ci@kernel.org, bpf@vger.kernel.org,
	netdev@vger.kernel.org,  willemb@google.com, ast@kernel.org,
	daniel@iogearbox.net, andrii@kernel.org,  eddyz87@gmail.com,
	memxor@gmail.com, shuah@kernel.org,
	 linux-kselftest@vger.kernel.org, linux-kernel@vger.kernel.org,
	martin.lau@kernel.org,  yonghong.song@linux.dev, clm@meta.com,
	ihor.solodrai@linux.dev
Subject: Re: [PATCH v5 6/6] selftests/bpf: tc_tunnel validate decap GSO state
Date: Mon, 27 Apr 2026 15:36:03 -0700	[thread overview]
Message-ID: <2026427222011._PrH.martin.lau@linux.dev> (raw)
In-Reply-To: <2ea5cc41fd138e94dc34b1d4073833118b93ae48d802aabe480e355e27417b62@mail.kernel.org>

On Mon, Apr 20, 2026 at 11:19:30AM +0000, bot+bpf-ci@kernel.org wrote:
> > +	if (!shinfo->gso_size)
> > +		return TC_ACT_OK;
> > +
> > +	if ((flags & BPF_F_ADJ_ROOM_DECAP_L4_UDP) &&
> > +	    (shinfo->gso_type & SKB_GSO_UDP_TUNNEL_MASK))
> > +		return TC_ACT_SHOT;
> > +
> > +	if ((flags & BPF_F_ADJ_ROOM_DECAP_L4_GRE) &&
> > +	    (shinfo->gso_type & (SKB_GSO_GRE | SKB_GSO_GRE_CSUM)))
> > +		return TC_ACT_SHOT;
> > +
> > +	if ((flags & BPF_F_ADJ_ROOM_DECAP_IPXIP4) &&
> > +	    (shinfo->gso_type & SKB_GSO_IPXIP4))
> > +		return TC_ACT_SHOT;
> > +
> > +	if ((flags & BPF_F_ADJ_ROOM_DECAP_IPXIP6) &&
> > +	    (shinfo->gso_type & SKB_GSO_IPXIP6))
> > +		return TC_ACT_SHOT;
> 
> Are these IPXIP4 and IPXIP6 checks reachable?
> 
> Looking earlier in decap_internal(), for IPPROTO_IPIP and IPPROTO_IPV6
> cases, the function only sets BPF_F_ADJ_ROOM_DECAP_L3_IPV4 and
> BPF_F_ADJ_ROOM_DECAP_L3_IPV6 on the flags variable (around the protocol
> switch statement).
> 
> Because BPF_F_ADJ_ROOM_DECAP_IPXIP4 and BPF_F_ADJ_ROOM_DECAP_IPXIP6 are
> never added to flags, wouldn't these validation checks always be skipped?
> 
> Ref: https://lore.kernel.org/bpf/20260416124324.B0CE6C2BCAF@smtp.kernel.org/

This comment has been mentioned again. It seems legit. Please don't ignore
the review comment. Otherwise, it will be assumed that the solutions are
being worked on and patchwork will eventually archive the patches after
some time.

Also, there is a 'SYS(fail_close_ns_client, "ethtool -K veth1 tso off");'
in prog_tests/test_tc_tunnel.c. Is the shinfo->gso_type ever set?
What will break if tso is kept on?

      reply	other threads:[~2026-04-27 22:36 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-04-20 10:40 [PATCH bpf-next v5 0/6] bpf: decap flags and GSO state updates Nick Hudson
2026-04-20 10:40 ` [PATCH v5 1/6] bpf: name the enum for BPF_FUNC_skb_adjust_room flags Nick Hudson
2026-04-20 10:40 ` [PATCH v5 2/6] bpf: refactor masks for ADJ_ROOM flags and encap validation Nick Hudson
2026-04-20 19:42   ` Willem de Bruijn
2026-04-27 22:40   ` Martin KaFai Lau
2026-04-20 10:40 ` [PATCH v5 3/6] bpf: add BPF_F_ADJ_ROOM_DECAP_* flags for tunnel decapsulation Nick Hudson
2026-04-20 19:44   ` Willem de Bruijn
2026-04-20 10:40 ` [PATCH v5 4/6] bpf: allow new DECAP flags and add guard rails Nick Hudson
2026-04-20 19:45   ` Willem de Bruijn
2026-04-20 10:40 ` [PATCH v5 5/6] bpf: clear decap tunnel GSO state in skb_adjust_room Nick Hudson
2026-04-20 11:19   ` bot+bpf-ci
2026-04-27 22:19     ` Martin KaFai Lau
2026-04-20 19:46   ` Willem de Bruijn
2026-04-20 10:40 ` [PATCH v5 6/6] selftests/bpf: tc_tunnel validate decap GSO state Nick Hudson
2026-04-20 11:19   ` bot+bpf-ci
2026-04-27 22:36     ` Martin KaFai Lau [this message]

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=2026427222011._PrH.martin.lau@linux.dev \
    --to=martin.lau@linux.dev \
    --cc=andrii@kernel.org \
    --cc=ast@kernel.org \
    --cc=bot+bpf-ci@kernel.org \
    --cc=bpf@vger.kernel.org \
    --cc=clm@meta.com \
    --cc=daniel@iogearbox.net \
    --cc=eddyz87@gmail.com \
    --cc=ihor.solodrai@linux.dev \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-kselftest@vger.kernel.org \
    --cc=martin.lau@kernel.org \
    --cc=memxor@gmail.com \
    --cc=netdev@vger.kernel.org \
    --cc=nhudson@akamai.com \
    --cc=shuah@kernel.org \
    --cc=willemb@google.com \
    --cc=yonghong.song@linux.dev \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
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