span version II support")
> Cc: u9012...@gmail.com
> Cc: Stephen Hemminger
> Reported-by: Christian Poessinger
> Signed-off-by: Christian Poessinger
> ---
LGTM, thanks
Acked-by: William Tu
com
> Reported-by: Christian Pössinger
> Signed-off-by: Stephen Hemminger
> ---
LGTM, Thanks.
Acked-by: William Tu
.")
> Signed-off-by: Hangbin Liu
> ---
LGTM, thanks.
Acked-by: William Tu
nel option, there is no need to drop the packet and
> break all geneve rx traffic. Just set opt_class to 0 in this test and
> keep returning TC_ACT_OK.
>
> Signed-off-by: Hangbin Liu
> ---
LGTM.
Acked-by: William Tu
e bash instead.
>
> Also remove the 'set -e' since the script actually relies on that the
> return value can be used to determine pass/fail of the test.
>
> Fixes: 996139e801fd ("selftests: bpf: add a test for XDP redirect")
> Signed-off-by: Björn Töpel
> ---
LGTM, thanks.
Acked-by: William Tu
./test_xdp_redirect.sh
> > selftests: test_xdp_redirect xdpgeneric [PASS]
> > selftests: test_xdp_redirect xdpdrv [PASS]
> >
> > Signed-off-by: Hangbin Liu
>
> Acked-by: Song Liu
LGTM.
Acked-by: William Tu
Add a check to make sure the IFLA_GRE_ERSPAN_VER is provided by users.
Fixes: f989d546a2d5 ("erspan: Add type I version 0 support.")
Cc: Eric Dumazet
Signed-off-by: William Tu
---
net/ipv4/ip_gre.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/net/ipv4/ip_g
On Wed, May 6, 2020 at 7:42 PM Eric Dumazet wrote:
>
>
>
> On 5/5/20 9:05 AM, William Tu wrote:
> > The Type I ERSPAN frame format is based on the barebones
> > IP + GRE(4-byte) encapsulation on top of the raw mirrored frame.
> > Both type I and II use 0x88BE as
erspan11 type erspan \
local 172.16.1.100 remote 172.16.1.200 \
erspan_ver 0
Signed-off-by: William Tu
---
v2:
remove the inline keyword, let compiler decide.
v1:
I didn't notice there is Type I when I did first erspan implementation
because it is not in the ietf dra
On Wed, Apr 29, 2020 at 2:52 PM David Ahern wrote:
>
> On 4/26/20 9:04 AM, William Tu wrote:
> > The Type I ERSPAN frame format is based on the barebones
> > IP + GRE(4-byte) encapsulation on top of the raw mirrored frame.
> > Both type I and II use 0x88BE as protocol type
The patch enables XDP_SOCKETS and XDP_SOCKETS_DIAG used by AF_XDP,
and its dependency on BPF_SYSCALL.
Signed-off-by: William Tu
---
init/Kconfig| 2 +-
net/xdp/Kconfig | 4 ++--
2 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/init/Kconfig b/init/Kconfig
index b4daad2bac23
On Mon, Oct 21, 2019 at 6:16 PM Tonghao Zhang wrote:
>
> On Tue, Oct 22, 2019 at 1:14 AM William Tu wrote:
> >
> > On Wed, Oct 16, 2019 at 5:50 AM wrote:
> > >
> > > From: Tonghao Zhang
> > >
> > > This series patch optimi
> > Hi Tonghao,
> >
> > Does this improve performance? After all, the original code simply
> > check whether the mask is NULL, then goto next mask.
> I tested the performance, but I disable the mask cache, and use the
> dpdk-pktgen to generate packets:
> The test ovs flow:
> ovs-dpctl add-dp system
On Wed, Oct 16, 2019 at 5:50 AM wrote:
>
> From: Tonghao Zhang
>
> This series patch optimize openvswitch for performance or simplify
> codes.
>
> Patch 1, 2, 4: Port Pravin B Shelar patches to
> linux upstream with little changes.
btw, should we keep Pravin as the author of the above three patc
> Tested-by: Greg Rose
> ---
LGTM
Acked-by: William Tu
On the other hand, maybe we should have an upper limit on the
mask cash size?
Regards,
William`
> net/openvswitch/flow_table.c | 33 +++--
> 1 file changed, 23 insertions(+), 10 deletions(-)
>
> d
g
> Tested-by: Greg Rose
> ---
LGTM
Acked-by: William Tu
masks can
> | affect packet processing performance.
>
> Link:
> https://github.com/openvswitch/ovs/commit/5604935e4e1cbc16611d2d97f50b717aa31e8ec5
> Signed-off-by: Tonghao Zhang
> Tested-by: Greg Rose
> ---
LGTM
Acked-by: William Tu
On Wed, Oct 16, 2019 at 5:56 AM wrote:
>
> From: Tonghao Zhang
>
> use the specified functions to init resource.
>
> Signed-off-by: Tonghao Zhang
> Tested-by: Greg Rose
> ---
Looks like this is simply moving code around.
I don't have any opinion.
> net/openvswitch/datapath.c | 60
>
t OvS recirc_id from tc chain index")
> Cc: Paul Blakey
> Signed-off-by: Tonghao Zhang
> Tested-by: Greg Rose
> ---
LGTM
Acked-by: William Tu
> net/openvswitch/datapath.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/net/openvswit
On Wed, Oct 16, 2019 at 5:55 AM wrote:
>
> From: Tonghao Zhang
>
> The most case *index < ma->max, and flow-mask is not NULL.
> We add un/likely for performance.
>
> Signed-off-by: Tonghao Zhang
> Tested-by: Greg Rose
> ---
LGTM
Acked-by: William Tu
&g
On Wed, Oct 16, 2019 at 5:54 AM wrote:
>
> From: Tonghao Zhang
>
> The full looking up on flow table traverses all mask array.
> If mask-array is too large, the number of invalid flow-mask
> increase, performance will be drop.
>
> One bad case, for example: M means flow-mask is valid and NULL
> o
On Wed, Oct 16, 2019 at 5:54 AM wrote:
>
> From: Tonghao Zhang
>
> Simplify the code and remove the unnecessary BUILD_BUG_ON.
>
> Signed-off-by: Tonghao Zhang
> Tested-by: Greg Rose
> ---
LGTM
Acked-by: William Tu
> net/openvswitch/flow_table.c | 8 ++--
>
Hi Tonghao,
Thanks for the patch.
> On 29 Sep 2019, at 19:09, xiangxia.m@gmail.com wrote:
>
> > From: Tonghao Zhang
> >
> > This series patch optimize openvswitch.
> >
> > Patch 1, 2, 4: Port Pravin B Shelar patches to
> > linux upstream with little changes.
> >
I thought the idea of adding
lo to become free. Usage count = 1
>
> Fixes: ef7baf5e083c ("ip6_gre: add ip6 erspan collect_md mode")
> Signed-off-by: Xin Long
> ---
LGTM, thanks for the fix!
Acked-by: William Tu
> net/ipv6/ip6_gre.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
On Thu, Aug 22, 2019 at 11:10 PM Björn Töpel wrote:
>
> On 2019-08-22 19:32, William Tu wrote:
> > On Thu, Aug 22, 2019 at 10:21 AM Alexander Duyck
> > wrote:
> >>
> >> On Thu, Aug 22, 2019 at 10:12 AM Ilya Maximets
> >> wrote:
> >>>
On Tue, Aug 13, 2019 at 5:07 AM Toshiaki Makita
wrote:
>
> This is a rough PoC for an idea to offload TC flower to XDP.
>
>
> * Motivation
>
> The purpose is to speed up software TC flower by using XDP.
>
> I chose TC flower because my current interest is in OVS. OVS uses TC to
> offload flow tabl
; broader perspective and find the most low hanging fruit.
>
> Thanks Ilya for this fix.
>
> Acked-by: Magnus Karlsson
>
> > Fixes: c497176cb2e4 ("xsk: add Rx receive functions and poll support")
> > Signed-off-by: Ilya Maximets
> > ---
Tested on my machine and works ok.
Tested-by: William Tu
Please ignore this patch and allow me to investigate more.
On Thu, May 30, 2019 at 10:23 AM Gregory Rose wrote:
>
>
> On 5/30/2019 9:59 AM, William Tu wrote:
> > When increases the headroom, skb's data pointer might get re-allocated.
> > As a result, the skb->data be
w_head before accessing the skb->data pointer.
Fixes: 01b8d064d58b4 ("net: ip6_gre: Request headroom in __gre6_xmit()")
Reported-by: Haichao Ma
Signed-off-by: William Tu
---
v1-v2: add more details in commit message.
---
net/ipv6/ip6_gre.c | 6 +++---
1 file changed, 3 insertions(+), 3 d
; RAX: ffda RBX: 0004 RCX: 20011000
> > > > RDX: RSI: RDI: 20008000
> > > > RBP: 001c R08: R09:
> > > > R10: R11: 0
When increases the headroom, skb's pointer might get re-allocated.
Fix it by moving skb_cow_head before accessing the skb->data pointer.
Fixes: 01b8d064d58b4 ("net: ip6_gre: Request headroom in __gre6_xmit()")
Reported-by: Haichao Ma
Signed-off-by: William Tu
---
net/
On Thu, May 2, 2019 at 1:18 PM Y Song wrote:
>
> On Thu, May 2, 2019 at 11:34 AM William Tu wrote:
> >
> > The libbpf_util.h is used by xsk.h, so add it to
> > the install headers.
>
> Can we try to change code a little bit to avoid exposing libbpf_util.h?
The libbpf_util.h is used by xsk.h, so add it to
the install headers.
Reported-by: Ben Pfaff
Signed-off-by: William Tu
---
tools/lib/bpf/Makefile | 1 +
1 file changed, 1 insertion(+)
diff --git a/tools/lib/bpf/Makefile b/tools/lib/bpf/Makefile
index c6c06bc6683c..f91639bf5650 100644
--- a
passed
> to munmap.
>
> When the userspace application tried to tear down an AF_XDP socket,
> the operation failed and the application would still have a reference
> to socket it wished to get rid of.
>
> Reported-by: William Tu
> Fixes: 1cad07884239 ("libbpf: add sup
KMAP. Instead, the
> bpf_map_delete_elem() function should be used for that.
>
> This patch also simplifies the code by breaking up
> xsk_update_bpf_maps() into three smaller functions.
>
> Reported-by: William Tu
> Fixes: 1cad07884239 ("libbpf: add support for using AF_XDP sockets"
The total_packets count at ixgbe_clean_xdp_tx_irq is
always zero when testing with xdpsock -t -N. Set the gso_segs
to 1 to make the tx packet count correct.
Signed-off-by: William Tu
---
drivers/net/ethernet/intel/ixgbe/ixgbe_xsk.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/net
The tx bytecount is done twice. When running
'./xdpsock -t -N -i eth3' and 'ip -s link show dev eth3'
The avg packet size is 120 instead of 60. So remove the
extra one.
Signed-off-by: William Tu
---
drivers/net/ethernet/intel/ixgbe/ixgbe_xsk.c | 1 -
1 file changed, 1 delet
Hi Jonathan,
Sorry I don't have good suggestions but I have a couple of questions.
On Fri, Mar 29, 2019 at 9:17 AM Jonathan Lemon wrote:
>
> Background:
>
> With AF_XDP, packets are placed on queues which are serviced directly from
> an application running in user space, which promises greatly i
On Fri, Mar 29, 2019 at 1:16 AM Maxim Mikityanskiy wrote:
>
> > -Original Message-
> > From: Björn Töpel
> > Sent: 28 March, 2019 14:35
> > To: Maxim Mikityanskiy
> > Cc: Magnus Karlsson ; Magnus Karlsson
> > ; Björn Töpel ; Jonathan
> > Lemon ; netdev@vger.kernel.org; Daniel Borkmann
>
Hi Toshiaki,
Thanks a lot for the feedback.
On Tue, Jan 1, 2019 at 5:44 AM Toshiaki Makita
wrote:
>
> Hi, William. Nice work.
> I have some feedback and questions.
>
> > + while (peer_rq->xsk_umem && budget--) {
> > + unsigned int inner_xdp_xmit = 0;
> > + unsigned in
ckets. The performance increases from
1.1Mpps to 1.4Mpps, when running zero copy xdpsock as sender and
XDP_DROP at the receiver side.
Signed-off-by: William Tu
---
drivers/net/veth.c | 41 ++---
1 file changed, 18 insertions(+), 23 deletions(-)
diff --git a/dr
Add MEM_TYPE_ZERO_COPY_VDEV for supporting the veth AF_XDP.
For zero-copy veth, the memory comes from userspace and does
not need to be freed at kernel. Thus, when xdp returns the
frame, detecting this type and doing nothing.
Signed-off-by: William Tu
---
include/net/xdp.h | 1 +
net/core
Add example use cases for AF_XDP socket on two namespaces.
The script runs sender at the root namespace, and receiver
at the at_ns0 namespace with different XDP actions.
Signed-off-by: William Tu
---
samples/bpf/test_veth_afxdp.sh | 82 ++
1 file changed
psock -i p1 -t -N -z
The performance increases from 1.4Mpps to 2.3Mpps.
Signed-off-by: William Tu
---
drivers/net/veth.c | 17 +
1 file changed, 17 insertions(+)
diff --git a/drivers/net/veth.c b/drivers/net/veth.c
index 551444195398..8aac67554880 100644
--- a/drivers/net/veth.c
link set dev p1 up
ip netns exec at_ns0 ip link set dev p0 up
# receiver
ip netns exec at_ns0 xdp_rxq_info --dev p0 --action XDP_DROP
# sender
xdpsock -i p1 -t -N -z
or
xdpsock -i p1 -t -S
Signed-off-by: William Tu
---
drivers/net/veth.c | 200
Currently the xsk_umem_consume_tx expects only the physical NICs so
the api returns a dma address. This patch introduce the new function
to return the virtual address, when XSK is used by a virtual device.
Signed-off-by: William Tu
---
include/net/xdp_sock.h | 7 +++
net/xdp/xdp_umem.c
and its peer's rx napi,
suggested by Björn Töpel
- add AF_XDP zero copy TX
- add AF_XDP RX
v1->v2:
- refactor the xsk_umem_consume_tx_virtual
- use the umems provided by netdev
- fix bug from locating peer side rq with qid
William Tu (6):
xsk: add xsk_umem_consume_tx_virtual.
veth: s
On Fri, Dec 21, 2018 at 12:38 AM Björn Töpel wrote:
>
> Den ons 19 dec. 2018 kl 01:55 skrev William Tu :
> >
> > The patch adds support for AF_XDP async xmit. Users can use
> > AF_XDP on both side of the veth and get better performance, with
> > the cost of
On Thu, Dec 20, 2018 at 11:48 AM Björn Töpel wrote:
>
> Den ons 19 dec. 2018 kl 01:55 skrev William Tu :
> >
> > Currently the xsk_umem_consume_tx expects only the physical NICs so
> > the api returns a dma address. This patch introduce the new function
> > to re
exec at_ns0 ip link set dev p0 up
# receiver
ip netns exec at_ns0 xdp_rxq_info --dev p0 --action XDP_DROP
# sender
xdpsock -i p1 -t -N -z
or
xdpsock -i p1 -t -S
Signed-off-by: William Tu
---
drivers/net/veth.c | 199 -
1 file
Add example use cases for AF_XDP socket on two namespaces.
The script runs sender at the root namespace, and receiver
at the at_ns0 namespace with different XDP actions.
Signed-off-by: William Tu
---
samples/bpf/test_veth_afxdp.sh | 67 ++
1 file changed
Currently the xsk_umem_consume_tx expects only the physical NICs so
the api returns a dma address. This patch introduce the new function
to return the virtual address, when XSK is used by a virtual device.
Signed-off-by: William Tu
---
include/net/xdp_sock.h | 7 +++
net/xdp/xdp_umem.c
(with ksoftirqd 100% cpu)
RXQ stats RXQ:CPU pps issue-pps
rx_queue_index0:3 1188181 0
rx_queue_index0:sum 1188181
v1->v2:
- refactor the xsk_umem_consume_tx_virtual
- use the umems provided by netdev
- fix bug from locating peer side rq with qid
Willi
On Tue, Dec 18, 2018 at 6:45 AM Björn Töpel wrote:
>
> Den mån 17 dec. 2018 kl 20:40 skrev William Tu :
> >
> > The patch adds support for AF_XDP async xmit. Users can use
> > AF_XDP on both side of the veth and get better performance, with
> > the cost of
On Tue, Dec 18, 2018 at 6:34 AM Björn Töpel wrote:
>
> Den mån 17 dec. 2018 kl 20:40 skrev William Tu :
> >
> > Currently the xsk_umem_consume_tx expects only the physical NICs so
> > the api returns a dma address. This patch introduce the new function
> > to return
Thanks for the feedback.
On Tue, Dec 18, 2018 at 6:14 AM Björn Töpel wrote:
>
> Den mån 17 dec. 2018 kl 20:40 skrev William Tu :
> >
> > The patch series adds AF_XDP async xmit support for veth device.
> > First patch add a new API for supporting non-physical NIC de
Currently the xsk_umem_consume_tx expects only the physical NICs so
the api returns a dma address. This patch introduce the new function
to return the virtual address, when XSK is used by a virtual device.
Signed-off-by: William Tu
---
include/net/xdp_sock.h | 7 +++
net/xdp/xsk.c
exec at_ns0 ip link set dev p0 up
# receiver
ip netns exec at_ns0 xdp_rxq_info --dev p0 --action XDP_DROP
# sender
xdpsock -i p1 -t -N -z
or
xdpsock -i p1 -t -S
Signed-off-by: William Tu
---
drivers/net/veth.c | 247 -
1 file
(with ksoftirqd 100% cpu)
RXQ stats RXQ:CPU pps issue-pps
rx_queue_index0:3 1188181 0
rx_queue_index0:sum 1188181
William Tu (3):
xsk: add xsk_umem_consume_tx_virtual.
veth: support AF_XDP.
samples: bpf: add veth AF_XDP example.
drivers/net/v
Add example use cases for AF_XDP socket on two namespaces.
The script runs sender at the root namespace, and receiver
at the at_ns0 namespace with different XDP actions.
Signed-off-by: William Tu
---
samples/bpf/test_veth_afxdp.sh | 67 ++
1 file changed
On Tue, Oct 2, 2018 at 11:39 AM Björn Töpel wrote:
>
> On 2018-10-02 20:23, William Tu wrote:
> > On Tue, Oct 2, 2018 at 1:01 AM Björn Töpel wrote:
> >>
> >> From: Björn Töpel
> >>
> >> Jeff: Please remove the v1 patches from your dev-queue!
>
On Tue, Oct 2, 2018 at 1:01 AM Björn Töpel wrote:
>
> From: Björn Töpel
>
> This patch prepares for the upcoming zero-copy Tx functionality by
> moving common functions used both by the regular path and zero-copy
> path.
>
> Signed-off-by: Björn Töpel
> ---
Thanks!
Tested-by: William Tu
l
> ---
Thanks!
Tested-by: William Tu
API context and using
> the same ring, it will also be protected from XDP_REDIRECT actions
> with the exact same mechanism.
>
> As with AF_XDP Rx, all AF_XDP Tx specific functions are added to
> ixgbe_xsk.c.
>
> Signed-off-by: Björn Töpel
> ---
Thanks!
Tested-by: William Tu
off-by: Björn Töpel
> ---
Thanks!
Tested-by: William Tu
> drivers/net/ethernet/intel/ixgbe/Makefile | 3 +-
> drivers/net/ethernet/intel/ixgbe/ixgbe.h | 27 +-
> drivers/net/ethernet/intel/ixgbe/ixgbe_lib.c | 17 +-
> drivers/net/ethernet/intel/ixgbe/ixgbe_main.c | 7
y AF_XDP support
> is introduced.
>
> Signed-off-by: Björn Töpel
Thanks!
Tested-by: William Tu
On Tue, Oct 2, 2018 at 1:01 AM Björn Töpel wrote:
>
> From: Björn Töpel
>
> Jeff: Please remove the v1 patches from your dev-queue!
>
> This patch set introduces zero-copy AF_XDP support for Intel's ixgbe
> driver.
>
> The ixgbe zero-copy code is located in its own file ixgbe_xsk.[ch],
> analogou
> Thanks for working on this, LGTM! Are you also planning to get ixgbe
> out after that?
>
I currently don't have i40e nic to test, so
I'm also looking forward to the ixgbe patch!
Thank you
William
On Sun, Aug 12, 2018 at 6:09 PM Pravin Shelar wrote:
>
> On Fri, Aug 10, 2018 at 10:19 AM, Yi-Hung Wei wrote:
> > Currently, OVS only parses the IP protocol number for the first
> > IPv6 fragment, but sets the IP protocol number for the later fragments
> > to be NEXTHDF_FRAGMENT. This patch trie
port")
> Signed-off-by: Prashant Bhole
> ---
Thanks for the fix.
Acked-by: William Tu
On Thu, Jun 14, 2018 at 10:24 PM, Eyal Birger wrote:
>
>
>> On 14 Jun 2018, at 15:01, William Tu wrote:
>>
>> Make the printting of bpf xfrm tunnel better and
>> cleanup xfrm state and policy when xfrm test finishes.
>
> Yeah the ‘tee’ was useful when deve
Make the printting of bpf xfrm tunnel better and
cleanup xfrm state and policy when xfrm test finishes.
Signed-off-by: William Tu
---
tools/testing/selftests/bpf/test_tunnel.sh | 24 +---
1 file changed, 13 insertions(+), 11 deletions(-)
diff --git a/tools/testing/selftests
Hi Petr,
I tried to test this patch on latest net-next but encounter a couple issues.
On Wed, May 23, 2018 at 9:41 AM, Petr Machata wrote:
> Commit 5691484df961 ("net: ip6_gre: Fix headroom request in
> ip6erspan_tunnel_xmit()") and commit 01b8d064d58b ("net: ip6_gre:
> Request headroom in __gre
Frame
Based the short/oversized definitions in RFC1757, the patch sets
the bso bit based on the mirrored packet's size.
Reported-by: Xiaoyan Jin
Signed-off-by: William Tu
---
v1->v2
Improve code comments, make enum erspan_bso clearer
---
include/net/erspan.h | 28
t;ip6_gre: add ip6 erspan collect_md mode")
Signed-off-by: William Tu
---
net/ipv6/ip6_gre.c | 101 +
1 file changed, 79 insertions(+), 22 deletions(-)
diff --git a/net/ipv6/ip6_gre.c b/net/ipv6/ip6_gre.c
index 5162ecc45c20..458de353f5d9 1
extra 8 bytes are thus available. However correct it is not.
>
> So replace the newlink and changelink callbacks with an ERSPAN-specific
> ones, reusing the newly-introduced _common() functions.
>
> Signed-off-by: Petr Machata
> ---
Acked-by: William Tu
Thanks, using ERSPAN-spec
extract the whole tail to the
> caller, ip6gre_newlink(). Thus enable an ERSPAN-specific _newlink()
> function without a lot of duplicity.
>
> Signed-off-by: Petr Machata
> ---
LGTM.
Acked-by: William Tu
> net/ipv6/ip6_gre.c | 24 ++--
> 1 file chang
chata
> ---
LGTM.
Acked-by: William Tu
> net/ipv6/ip6_gre.c | 33 -
> 1 file changed, 24 insertions(+), 9 deletions(-)
>
> diff --git a/net/ipv6/ip6_gre.c b/net/ipv6/ip6_gre.c
> index 4dfa21d..c17e38b 100644
> --- a/net/ipv6/ip6_gre.c
> +++ b
er length as an argument. This split will allow
> the patches down the line to sneak in a custom header length computation
> for the ERSPAN tunnel.
>
> Signed-off-by: Petr Machata
> ---
LGTM.
Acked-by: William Tu
> net/ipv6/ip6_gre.c | 38 ++
; ---
LGTM.
Acked-by: William Tu
> net/ipv6/ip6_gre.c | 10 --
> 1 file changed, 8 insertions(+), 2 deletions(-)
>
> diff --git a/net/ipv6/ip6_gre.c b/net/ipv6/ip6_gre.c
> index 78ba6b9..307ac6d 100644
> --- a/net/ipv6/ip6_gre.c
> +++ b/net/ipv6/ip6_gr
28 dev h1
>
> ip link add dev vh3 type vrf table 20
> ip link set dev h3 master vh3
> ip link set dev vh3 up
> ip link set dev h3 up
>
> ip link set dev swp3 up
> ip address add dev swp3 2001:db8:2::1/64
>
> i
:db8:2::1/64
>
> ip link set dev swp1 up
> tc qdisc add dev swp1 clsact
>
> ip link add name gt6 type ip6gretap \
> local 2001:db8:2::1 remote 2001:db8:2::2
> ip link set dev gt6 up
>
> sleep 1
>
> tc filte
On Wed, May 16, 2018 at 3:24 PM, Tobin C. Harding wrote:
> On Wed, May 16, 2018 at 07:05:34AM -0700, William Tu wrote:
>> On Mon, May 14, 2018 at 10:33 PM, Tobin C. Harding
>> wrote:
>> > On Mon, May 14, 2018 at 04:54:36PM -0700, William Tu wrote:
>> >> Befor
Signed-off-by: William Tu
---
net/ipv4/ip_gre.c | 4 +++-
net/ipv6/ip6_gre.c | 5 -
2 files changed, 7 insertions(+), 2 deletions(-)
diff --git a/net/ipv4/ip_gre.c b/net/ipv4/ip_gre.c
index 2409e648454d..2d8efeecf619 100644
--- a/net/ipv4/ip_gre.c
+++ b/net/ipv4/ip_gre.c
@@ -734,10 +734,12
On Mon, May 14, 2018 at 10:33 PM, Tobin C. Harding wrote:
> On Mon, May 14, 2018 at 04:54:36PM -0700, William Tu wrote:
>> Before the patch, the erspan BSO bit (Bad/Short/Oversized) is not
>> handled. BSO has 4 possible values:
>> 00 --> Good frame with no error, or u
Frame
Based the short/oversized definitions in RFC1757, the patch sets
the bso bit based on the mirrored packet's size.
Reported-by: Xiaoyan Jin
Signed-off-by: William Tu
---
include/net/erspan.h | 25 +
1 file changed, 25 insertions(+)
diff --git a/include/net/e
gt;len.
Reported-by: Xiaoyan Jin
Signed-off-by: William Tu
---
net/ipv4/ip_gre.c | 6 ++
net/ipv6/ip6_gre.c | 6 ++
2 files changed, 12 insertions(+)
diff --git a/net/ipv4/ip_gre.c b/net/ipv4/ip_gre.c
index dfe5b22f6ed4..2409e648454d 100644
--- a/net/ipv4/ip_gre.c
+++ b/net/ipv4/ip
On Wed, May 2, 2018 at 1:29 AM, Daniel Borkmann wrote:
> On 05/02/2018 06:52 AM, Alexei Starovoitov wrote:
>> On Tue, May 01, 2018 at 09:35:29PM -0700, William Tu wrote:
>>>
>>>> How did you test this patch?
>>>>
>>> Without the patch, the tes
On Tue, May 1, 2018 at 4:16 PM, Alexei Starovoitov
wrote:
> On Mon, Apr 30, 2018 at 10:15:05AM -0700, William Tu wrote:
>> Existing verifier does not allow 'ctx + const + const'. However, due to
>> compiler optimization, there is a case where BPF compilerit generates
Yonghong Song
Signed-off-by: Yifeng Sun
Signed-off-by: William Tu
---
kernel/bpf/verifier.c | 2 +-
tools/testing/selftests/bpf/test_verifier.c | 13 +
2 files changed, 14 insertions(+), 1 deletion(-)
diff --git a/kernel/bpf/verifier.c b/kernel/bpf/verifier.c
index
On Mon, Apr 30, 2018 at 2:05 AM, Daniel Borkmann wrote:
> On 04/30/2018 09:02 AM, Y Song wrote:
>> Hi, William,
>>
>> When compiled the selftests/bpf in my centos 7 based system, I have
>> the following failures,
>>
>> clang -I. -I./include/uapi -I../../../include/uapi
>> -Wno-compare-distinct-poi
Bring the erspan uapi header file so BPF tunnel helpers can use it.
Fixes: 933a741e3b82 ("selftests/bpf: bpf tunnel test.")
Reported-by: Yonghong Song
Signed-off-by: William Tu
---
tools/include/uapi/linux/erspan.h | 52 +++
1 file changed, 52
If true, this indicated that the
mirrored packet is truncated and set the erspan truncate bit.
I tested the patch using bpf_skb_change_tail helper function to
shrink the packet size and send to erspan tunnel.
Reported-by: Xiaoyan Jin
Signed-off-by: William Tu
---
net/ipv4/ip_gre.c | 6 ++
t_tunnel, ipip_get_tunnel
IP6IP:ipip6_set_tunnel, ipip6_get_tunnel,
ip6ip6_set_tunnel, ip6ip6_get_tunnel
XFRM: xfrm_get_state
William Tu (2):
selftests/bpf: bpf tunnel test.
samples/bpf: remove the bpf tunnel testsuite.
samples/bpf/Makefile
Move the testsuite to
selftests/bpf/{test_tunnel_kern.c, test_tunnel.sh}
Signed-off-by: William Tu
---
samples/bpf/Makefile | 1 -
samples/bpf/tcbpf2_kern.c | 612 -
samples/bpf/test_tunnel_bpf.sh | 390 --
3 files
get_tunnel,
ip6ip6_set_tunnel, ip6ip6_get_tunnel
XFRM: xfrm_get_state
Signed-off-by: William Tu
---
tools/testing/selftests/bpf/Makefile | 5 +-
tools/testing/selftests/bpf/test_tunnel.sh | 729 +
tools/testing/selftests/bpf/test_tunnel_ke
On Wed, Apr 25, 2018 at 8:01 AM, William Tu wrote:
> The patch migrates the original tests at samples/bpf/tcbpf2_kern.c
> and samples/bpf/test_tunnel_bpf.sh to selftests. There are a couple
> changes from the original:
> 1) add ipv6 vxlan, ipv6 geneve, ipv6 ipip tests
>
On Wed, Apr 25, 2018 at 12:54 AM, Daniel Borkmann wrote:
> On 04/25/2018 08:46 AM, William Tu wrote:
>> The percpu metadata_dst might carry the stale ip_tunnel_info
>> and cause incorrect behavior. When mixing tests using ipv4/ipv6
>> bpf vxlan and geneve tunnel, the ipv6 tu
get_tunnel,
ip6ip6_set_tunnel, ip6ip6_get_tunnel
Signed-off-by: William Tu
---
samples/bpf/Makefile | 1 -
samples/bpf/tcbpf2_kern.c | 612 --
samples/bpf/test_tunnel_bpf.sh | 390 --
too
The patch zeros the fields in
ip_tunnel_info.
Signed-off-by: William Tu
Reported-by: Yifeng Sun
---
net/core/filter.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/net/core/filter.c b/net/core/filter.c
index 8e45c6c7ab08..d3781daa26ab 100644
--- a/net/core/filter.c
+++ b/net/core/fil
1 - 100 of 317 matches
Mail list logo