BPF List
 help / color / mirror / Atom feed
From: Yonghong Song <yhs@meta.com>
To: Eric Dumazet <edumazet@google.com>,
	"David S . Miller" <davem@davemloft.net>,
	Jakub Kicinski <kuba@kernel.org>, Paolo Abeni <pabeni@redhat.com>,
	Daniel Borkmann <daniel@iogearbox.net>,
	Alexei Starovoitov <ast@kernel.org>,
	Andrii Nakryiko <andrii@kernel.org>
Cc: netdev@vger.kernel.org, bpf@vger.kernel.org, eric.dumazet@gmail.com
Subject: Re: [PATCH net-next 1/2] net: remove skb->vlan_present
Date: Wed, 9 Nov 2022 08:36:37 -0800	[thread overview]
Message-ID: <f536564b-973a-797c-7b8e-adaaa567de7b@meta.com> (raw)
In-Reply-To: <20221109095759.1874969-2-edumazet@google.com>



On 11/9/22 1:57 AM, Eric Dumazet wrote:
> skb->vlan_present seems redundant.
> 
> We can instead derive it from this boolean expression:
> 
> vlan_present = skb->vlan_proto != 0 || skb->vlan_tci != 0
> 
> Add a new union, to access both fields in a single load/store
> when possible.
> 
> 	union {
> 		u32	vlan_all;
> 		struct {
> 		__be16	vlan_proto;
> 		__u16	vlan_tci;
> 		};
> 	};
> 
> This allows following patch to remove a conditional test in GRO stack.
> 
> Note:
>    We move remcsum_offload to keep TC_AT_INGRESS_MASK
>    and SKB_MONO_DELIVERY_TIME_MASK unchanged.
> 
> Signed-off-by: Eric Dumazet <edumazet@google.com>

Ack except the sparc jit part:

Acked-by: Yonghong Song <yhs@fb.com>

  reply	other threads:[~2022-11-09 16:38 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-11-09  9:57 [PATCH net-next 0/2] net: vlan: claim one bit from sk_buff Eric Dumazet
2022-11-09  9:57 ` [PATCH net-next 1/2] net: remove skb->vlan_present Eric Dumazet
2022-11-09 16:36   ` Yonghong Song [this message]
2022-11-09  9:57 ` [PATCH net-next 2/2] net: gro: no longer use skb_vlan_tag_present() Eric Dumazet
2022-11-10  6:13 ` [PATCH net-next 0/2] net: vlan: claim one bit from sk_buff Martin KaFai Lau
2022-11-12  4:50 ` patchwork-bot+netdevbpf

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=f536564b-973a-797c-7b8e-adaaa567de7b@meta.com \
    --to=yhs@meta.com \
    --cc=andrii@kernel.org \
    --cc=ast@kernel.org \
    --cc=bpf@vger.kernel.org \
    --cc=daniel@iogearbox.net \
    --cc=davem@davemloft.net \
    --cc=edumazet@google.com \
    --cc=eric.dumazet@gmail.com \
    --cc=kuba@kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=pabeni@redhat.com \
    /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