]> git.baikalelectronics.ru Git - kernel.git/commit
openvswitch: allow output of MPLS packets on tunnel vports
authorSimon Horman <simon.horman@netronome.com>
Tue, 15 Mar 2016 03:00:35 +0000 (12:00 +0900)
committerDavid S. Miller <davem@davemloft.net>
Fri, 18 Mar 2016 22:26:38 +0000 (18:26 -0400)
commitf12ad537318cd21881cf861228dce39f3d7a7e6d
tree83663c724442db55c92cca8f8686ddf2f8307840
parent13bd65b9298acf76d2915d6c007ce84e7c4595ce
openvswitch: allow output of MPLS packets on tunnel vports

Currently output of MPLS packets on tunnel vports is not allowed by Open
vSwitch. This is because historically encapsulation was done in such a way
that the inner_protocol field of the skb needed to hold the inner protocol
for both MPLS and tunnel encapsulation in order for GSO segmentation to be
performed correctly.

Since 973c028dc0dd ("openvswitch: Use regular GRE net_device instead of
vport") Open vSwitch makes use of lwt to output to tunnel netdevs which
perform encapsulation. As no drivers expose support for MPLS offloads this
means that GSO packets are segmented in software by validate_xmit_skb(),
which is called from __dev_queue_xmit(), before tunnel encapsulation occurs.
This means that the inner protocol of MPLS is no longer needed by the time
encapsulation occurs and the contention on the inner_protocol field of the
skb no longer occurs.

Thus it is now safe to output MPLS to tunnel vports.

Signed-off-by: Simon Horman <simon.horman@netronome.com>
Reviewed-by: Jesse Gross <jesse@kernel.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/openvswitch/flow_netlink.c