[ovs-dev] [PATCH v4 0/3] Add support for TSO with DPDK

William Tu u9012063 at gmail.com
Tue Jan 21 18:39:14 UTC 2020


On Thu, Jan 16, 2020 at 9:01 AM Flavio Leitner <fbl at sysclose.org> wrote:
>
> Abbreviated as TSO, TCP Segmentation Offload is a feature which enables
> the network stack to delegate the TCP segmentation to the NIC reducing
> the per packet CPU overhead.
>
> A guest using vhost-user interface with TSO enabled can send TCP packets
> much bigger than the MTU, which saves CPU cycles normally used to break
> the packets down to MTU size and to calculate checksums.
>
> It also saves CPU cycles used to parse multiple packets/headers during
> the packet processing inside virtual switch.
>
> If the destination of the packet is another guest in the same host, then
> the same big packet can be sent through a vhost-user interface skipping
> the segmentation completely. However, if the destination is not local,
> the NIC hardware is instructed to do the TCP segmentation and checksum
> calculation.
>
> The first 2 patches are not really part of TSO support, but they are
> required to make sure everything works.
>
> There are good improvements sending to or receiving from veth pairs or
> tap devices as well. See the iperf3 results below:
>
> [*] veth with ethtool tx off.
>

Hi Flavio,

I want to test performance of namespace to namespace using veth, hoping to
see TSO packets. Using below setup:
  iperf -c (ns0) -> veth peer -> OVS -> veth peer -> iperf -s (ns1)

With current master I'm not able to see large packet size being sent.
I compile ovs with --with-dpdk and,
$ ovs-vsctl set Open_vSwitch . other_config:userspace-tso-enable=true

At ns0 and ns1, enable tso by ethtool sg and tso on
The veth driver shows
# ip netns exec at_ns0 ethtool -k p0
Features for p0:
Cannot get device udp-fragmentation-offload settings: Operation not supported
rx-checksumming: on
tx-checksumming: off
    tx-checksum-ipv4: off [fixed]
    tx-checksum-ip-generic: off
    tx-checksum-ipv6: off [fixed]
    tx-checksum-fcoe-crc: off [fixed]
    tx-checksum-sctp: off
scatter-gather: on
    tx-scatter-gather: on
    tx-scatter-gather-fraglist: on
tcp-segmentation-offload: off
    tx-tcp-segmentation: off [requested on]
    tx-tcp-ecn-segmentation: off [requested on]
    tx-tcp-mangleid-segmentation: off [requested on]
   tx-tcp6-segmentation: off [requested on]

But I'm still seeing 1500 packet size, and about 1.3Gbps performance.
Is there anything I'm missing?

Thanks
William


More information about the dev mailing list