ACK: [SRU][F:linux-bluefield][PATCH v1 0/4] Completely support vxlan and erspan for flower

Tim Gardner tim.gardner at canonical.com
Tue Apr 18 13:16:51 UTC 2023


On 4/17/23 8:44 PM, Tony Duan wrote:
> BugLink: https://bugs.launchpad.net/bugs/2016829
> 
> SRU Justification:
> 
> [Impact]
> 
> * This patch is adding vxlan and erspan support to act_tunnel_key and fixes the bugs in erspan for the sake of completeness.
> 
> [Fix]
> 
> * cherry-pick c96adff95619178e2118925578343ad54857c80c c96adff95619 cls_flower: call nla_ok() before nla_next()
>    cherry-pick 8e1b3ac4786680c2d2b5a24e38a2d714c3bcd1ef 8e1b3ac47866 net: sched: initialize with 0 before setting erspan md->u
>    cherry-pick e20d4ff2acd7db2ffce64a6ddbdaeec43a8eec19 e20d4ff2acd7 net: sched: add erspan option support to act_tunnel_key
>    cherry-pick fca3f91cc38ad866c995fb099d961b31cd687849 fca3f91cc38a net: sched: add vxlan option support to act_tunnel_key
> 
> [Test Plan]
> 
> * For vxlan support:
> 	It is to allow setting vxlan options using the
>      act_tunnel_key action. Different from geneve options,
>      only one option can be set. And also, geneve options
>      and vxlan options can't be set at the same time.
>      gbp is the only param for vxlan options:
> 
>        # ip link add name vxlan0 type vxlan dstport 0 external
>        # tc qdisc add dev eth0 ingress
>        # tc filter add dev eth0 protocol ip parent ffff: \
>                 flower indev eth0 \
>                    ip_proto udp \
>                    action tunnel_key \
>                        set src_ip 10.0.99.192 \
>                        dst_ip 10.0.99.193 \
>                        dst_port 6081 \
>                        id 11 \
>                        vxlan_opts 01020304 \
>                 action mirred egress redirect dev vxlan0
> 
> For erspan support:
> 	It is to allow setting erspan options using the
>      act_tunnel_key action. Different from geneve options,
>      only one option can be set. And also, geneve options,
>      vxlan options or erspan options can't be set at the
>      same time.
> 
>      Options are expressed as ver:index:dir:hwid, when ver
>      is set to 1, index will be applied while dir and hwid
>      will be ignored, and when ver is set to 2, dir and
>      hwid will be used while index will be ignored.
> 
>        # ip link add name erspan1 type erspan external
>        # tc qdisc add dev eth0 ingress
>        # tc filter add dev eth0 protocol ip parent ffff: \
>                 flower indev eth0 \
>                    ip_proto udp \
>                    action tunnel_key \
>                        set src_ip 10.0.99.192 \
>                        dst_ip 10.0.99.193 \
>                        dst_port 6081 \
>                        id 11 \
>                      erspan_opts 1:2:0:0 \
>                 action mirred egress redirect dev erspan1
> 			
>    Check the action is correcttly filtered
> 
> [Where problems could occur]
> 
> * Without this patch, it does not support vxlan / erspan with act_tunnel_key
> 
> [Other Info]
> 
> * nothing
> 
> Cong Wang (1):
>    cls_flower: call nla_ok() before nla_next()
> 
> Xin Long (3):
>    net: sched: add vxlan option support to act_tunnel_key
>    net: sched: add erspan option support to act_tunnel_key
>    net: sched: initialize with 0 before setting erspan md->u
> 
>   include/uapi/linux/tc_act/tc_tunnel_key.h |  29 ++++
>   net/sched/act_tunnel_key.c                | 203 +++++++++++++++++++++-
>   net/sched/cls_flower.c                    |  23 ++-
>   3 files changed, 245 insertions(+), 10 deletions(-)
> 
Acked-by: Tim Gardner <tim.gardner at canonical.com>
-- 
-----------
Tim Gardner
Canonical, Inc




More information about the kernel-team mailing list