On 26 Mar 2021, at 7:20, Martin Varghese wrote:
From: Martin Varghese <martin.vargh...@nokia.com>
The existing PUSH MPLS & POP MPLS actions inserts & removes MPLS
header
between ethernet header and the IP header. Though this behaviour is
fine
for L3 VPN where an IP packet is encapsulated inside a MPLS tunnel, it
does not suffice the L2 VPN requirements. In L2 VPN the ethernet
packets
must be encapsulated inside MPLS tunnel
In this change the encap & decap actions are extended to support MPLS
packet type. The encap & decap adds and removes MPLS header at the
start
of packet as depicted below.
Encapsulation:
Actions - encap(mpls(ether_type=0x8847)),encap(ethernet)
Incoming packet -> | ETH | IP | Payload |
1 Actions - encap(mpls(ether_type=0x8847)) [Datapath action -
ADD_MPLS:0x8847]
Outgoing packet -> | MPLS | ETH | Payload|
2 Actions - encap(ethernet) [ Datapath action - push_eth ]
Outgoing packet -> | ETH | MPLS | ETH | Payload|
Decapsulation:
Incoming packet -> | ETH | MPLS | ETH | IP | Payload |
Actions - decap(),decap(packet_type(ns=0,type=0)
1 Actions - decap() [Datapath action - pop_eth)
Outgoing packet -> | MPLS | ETH | IP | Payload|
2 Actions - decap(packet_type(ns=0,type=0) [Datapath action -
POP_MPLS:0x6558]
Outgoing packet -> | ETH | IP | Payload|
I started off by running the self-tests with an older kernel, and this
is failing:
$ make -j $(nproc) check-kernel TESTSUITEFLAGS='-k mpls'
...
## ------------------------------- ##
## openvswitch 2.15.90 test suite. ##
## ------------------------------- ##
datapath-sanity
26: datapath - mpls actions ok
27: datapath - multiple mpls label pop FAILED
(system-traffic.at:1026)
28: datapath - ptap mpls actions ok
layer3-tunnels
137: layer3 - ping over MPLS Bareudp skipped
(system-layer3-tunnels.at:157)
I would assume 28 would fail or be skipped as the feature is missing.
27 should pass as your change should be backward compatible. Can you
check?
Also, it would be nice, if you sent out a new version to keep some
history, so we have an idea of what has changed.
Cheers,
Eelco
_______________________________________________
dev mailing list
d...@openvswitch.org
https://mail.openvswitch.org/mailman/listinfo/ovs-dev