Re: [PATCH] bpf: in bpf_skb_adjust_room correct inner protocol for vxlan

2021-02-09 Thread Willem de Bruijn
On Tue, Feb 9, 2021 at 5:41 AM 黄学森 wrote: > > Appreciate for your reply Willem! > > The original intention of this commit is that when we use bpf_skb_adjust_room > to encapsulate > Vxlan packets, we find some powerful device features disabled. > > Setting the inner_protocol directly as skb->prot

Re: [PATCH] bpf: in bpf_skb_adjust_room correct inner protocol for vxlan

2021-02-09 Thread 黄学森
Appreciate for your reply Willem! The original intention of this commit is that when we use bpf_skb_adjust_room to encapsulate Vxlan packets, we find some powerful device features disabled. Setting the inner_protocol directly as skb->protocol is the root cause. I understand that it’s not eas

Re: [PATCH] bpf: in bpf_skb_adjust_room correct inner protocol for vxlan

2021-02-08 Thread Willem de Bruijn
On Mon, Feb 8, 2021 at 7:16 AM huangxuesen wrote: > > From: huangxuesen > > When pushing vxlan tunnel header, set inner protocol as ETH_P_TEB in skb > to avoid HW device disabling udp tunnel segmentation offload, just like > vxlan_build_skb does. > > Drivers for NIC may invoke vxlan_features_chec

[PATCH] bpf: in bpf_skb_adjust_room correct inner protocol for vxlan

2021-02-08 Thread huangxuesen
From: huangxuesen When pushing vxlan tunnel header, set inner protocol as ETH_P_TEB in skb to avoid HW device disabling udp tunnel segmentation offload, just like vxlan_build_skb does. Drivers for NIC may invoke vxlan_features_check to check the inner_protocol in skb for vxlan packets to decide